diff options
Diffstat (limited to 'lib/Analysis/Loads.cpp')
-rw-r--r-- | lib/Analysis/Loads.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/Analysis/Loads.cpp b/lib/Analysis/Loads.cpp index d319d4c249d3..8129795bc0c1 100644 --- a/lib/Analysis/Loads.cpp +++ b/lib/Analysis/Loads.cpp @@ -107,8 +107,8 @@ static bool isDereferenceableAndAlignedPointer( return isDereferenceableAndAlignedPointer(ASC->getOperand(0), Align, Size, DL, CtxI, DT, Visited); - if (auto CS = ImmutableCallSite(V)) - if (auto *RP = getArgumentAliasingToReturnedPointer(CS)) + if (const auto *Call = dyn_cast<CallBase>(V)) + if (auto *RP = getArgumentAliasingToReturnedPointer(Call)) return isDereferenceableAndAlignedPointer(RP, Align, Size, DL, CtxI, DT, Visited); @@ -345,7 +345,7 @@ Value *llvm::FindAvailablePtrLoadStore(Value *Ptr, Type *AccessTy, const DataLayout &DL = ScanBB->getModule()->getDataLayout(); // Try to get the store size for the type. - uint64_t AccessSize = DL.getTypeStoreSize(AccessTy); + auto AccessSize = LocationSize::precise(DL.getTypeStoreSize(AccessTy)); Value *StrippedPtr = Ptr->stripPointerCasts(); |