[llvm] fd37ab6 - InstCombine: Pass AssumptionCache through isDereferenceablePointer
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 19 16:11:03 PDT 2022
Author: Matt Arsenault
Date: 2022-09-19T19:10:51-04:00
New Revision: fd37ab6cf697b25a2d903671d4263664da00eeee
URL: https://github.com/llvm/llvm-project/commit/fd37ab6cf697b25a2d903671d4263664da00eeee
DIFF: https://github.com/llvm/llvm-project/commit/fd37ab6cf697b25a2d903671d4263664da00eeee.diff
LOG: InstCombine: Pass AssumptionCache through isDereferenceablePointer
Added:
Modified:
llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp b/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp
index 801eee0e7cf3a..a6dd83cb199fe 100644
--- a/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp
+++ b/llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp
@@ -328,7 +328,7 @@ Value *InstCombinerImpl::simplifyMaskedLoad(IntrinsicInst &II) {
// If we can unconditionally load from this address, replace with a
// load/select idiom. TODO: use DT for context sensitive query
if (isDereferenceablePointer(LoadPtr, II.getType(),
- II.getModule()->getDataLayout(), &II, nullptr)) {
+ II.getModule()->getDataLayout(), &II, &AC)) {
LoadInst *LI = Builder.CreateAlignedLoad(II.getType(), LoadPtr, Alignment,
"unmaskedload");
LI->copyMetadata(II);
More information about the llvm-commits
mailing list