git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@365768
91177308-0d34-0410-b5e6-
96231b3b80d8
Loop *CurLoop) {
Value *Addr = LI->getOperand(0);
const DataLayout &DL = LI->getModule()->getDataLayout();
- const uint32_t LocSizeInBits = DL.getTypeSizeInBits(
- cast<PointerType>(Addr->getType())->getElementType());
+ const uint32_t LocSizeInBits = DL.getTypeSizeInBits(LI->getType());
// if the type is i8 addrspace(x)*, we know this is the type of
// llvm.invariant.start operand