[llvm] 84a2e48 - GVN: Pass through AssumptionCache to queries
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 19 16:25:33 PDT 2022
Author: Matt Arsenault
Date: 2022-09-19T19:25:22-04:00
New Revision: 84a2e48ce620afc724c59387e7831b867c7c0aa4
URL: https://github.com/llvm/llvm-project/commit/84a2e48ce620afc724c59387e7831b867c7c0aa4
DIFF: https://github.com/llvm/llvm-project/commit/84a2e48ce620afc724c59387e7831b867c7c0aa4.diff
LOG: GVN: Pass through AssumptionCache to queries
Added:
Modified:
llvm/lib/Transforms/Scalar/GVN.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Transforms/Scalar/GVN.cpp b/llvm/lib/Transforms/Scalar/GVN.cpp
index a8d298476abe..c62aaae8206e 100644
--- a/llvm/lib/Transforms/Scalar/GVN.cpp
+++ b/llvm/lib/Transforms/Scalar/GVN.cpp
@@ -1533,12 +1533,11 @@ bool GVNPass::PerformLoadPRE(LoadInst *Load, AvailValInBlkVect &ValuesPerBlock,
// to speculatively execute the load at that points.
if (MustEnsureSafetyOfSpeculativeExecution) {
if (CriticalEdgePred.size())
- if (!isSafeToSpeculativelyExecute(Load, LoadBB->getFirstNonPHI(), nullptr,
- DT))
+ if (!isSafeToSpeculativelyExecute(Load, LoadBB->getFirstNonPHI(), AC, DT))
return false;
for (auto &PL : PredLoads)
- if (!isSafeToSpeculativelyExecute(Load, PL.first->getTerminator(),
- nullptr, DT))
+ if (!isSafeToSpeculativelyExecute(Load, PL.first->getTerminator(), AC,
+ DT))
return false;
}
More information about the llvm-commits
mailing list