[llvm] [LV] Check Addr in getAddressAccessSCEV in terms of SCEV expressions. (PR #171204)
David Sherwood via llvm-commits
llvm-commits at lists.llvm.org
Thu Dec 11 09:08:09 PST 2025
================
@@ -150,6 +152,23 @@ const SCEV *vputils::getSCEVExprForVPValue(const VPValue *V,
.Default([&SE](const VPRecipeBase *) { return SE.getCouldNotCompute(); });
}
+bool vputils::isAddressSCEVForCost(const SCEV *Addr, ScalarEvolution &SE,
+ const Loop *L) {
+ // If address is an SCEVAddExpr, all operands must be either be invariant or a
----------------
david-arm wrote:
Should this be:
```
// If the address is an SCEVAddExpr, we require that all operands must be either be invariant or ...
```
Currently it sounds like if it's a SCEVAddExpr, then by definition all operands are guaranteed to be invariant.
https://github.com/llvm/llvm-project/pull/171204
More information about the llvm-commits
mailing list