[llvm] [LV] Stengthen loop-invariance checks in isPredicatedInst (PR #140744)
Florian Hahn via llvm-commits
llvm-commits at lists.llvm.org
Tue May 20 23:52:12 PDT 2025
================
@@ -2806,8 +2806,8 @@ LoopAccessInfo::recordAnalysis(StringRef RemarkName, const Instruction *I) {
bool LoopAccessInfo::isInvariant(Value *V) const {
auto *SE = PSE->getSE();
- // TODO: Is this really what we want? Even without FP SCEV, we may want some
- // trivially loop-invariant FP values to be considered invariant.
+ if (TheLoop->isLoopInvariant(V))
+ return true;
----------------
fhahn wrote:
Missing test coverage?
https://github.com/llvm/llvm-project/pull/140744
More information about the llvm-commits
mailing list