diff options
| author | Chandler Carruth <chandlerc@gmail.com> | 2012-12-15 09:26:06 +0000 |
|---|---|---|
| committer | Chandler Carruth <chandlerc@gmail.com> | 2012-12-15 09:26:06 +0000 |
| commit | 067edd342f2dbf10d7d8c36a543daa3411ef3679 (patch) | |
| tree | 79af8c2ca376584a458b97fbf0fa89aaff07a6e6 /llvm/lib | |
| parent | 7a28f95419a04eb9bc2ab07584485fd979d4eb4d (diff) | |
| download | bcm5719-llvm-067edd342f2dbf10d7d8c36a543daa3411ef3679.tar.gz bcm5719-llvm-067edd342f2dbf10d7d8c36a543daa3411ef3679.zip | |
Relax an overly aggressive assert to fix PR14572.
The alloca width is based on the alloc size, not the type size.
llvm-svn: 170270
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/Transforms/Scalar/SROA.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Transforms/Scalar/SROA.cpp b/llvm/lib/Transforms/Scalar/SROA.cpp index 1c220ca0f6e..c65ac5a647a 100644 --- a/llvm/lib/Transforms/Scalar/SROA.cpp +++ b/llvm/lib/Transforms/Scalar/SROA.cpp @@ -2607,7 +2607,7 @@ private: TD.getTypeStoreSizeInBits(V->getType()) && "Non-byte-multiple bit width"); assert(V->getType()->getIntegerBitWidth() == - TD.getTypeSizeInBits(OldAI.getAllocatedType()) && + TD.getTypeAllocSizeInBits(OldAI.getAllocatedType()) && "Only alloca-wide stores can be split and recomposed"); IntegerType *NarrowTy = Type::getIntNTy(SI.getContext(), Size * 8); V = extractInteger(TD, IRB, V, NarrowTy, BeginOffset, |

