[llvm] [SCEV] Preserve nuw on scaled recurrence start values. (PR #227458)

Nikita Popov via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 30 00:51:59 PDT 2026


================
@@ -10228,7 +10236,7 @@ SCEVUse ScalarEvolution::computeSCEVAtScope(const SCEV *V, const Loop *L) {
     // expression has no loop-variant portions.
     for (unsigned i = 0, e = AddRec->getNumOperands(); i != e; ++i) {
       SCEVUse OpAtScope = getSCEVAtScope(AddRec->getOperand(i), L);
-      if (OpAtScope == AddRec->getOperand(i))
+      if (OpAtScope == AddRec->getOperand(i).getPointer())
----------------
nikic wrote:

Why is this change needed?

https://github.com/llvm/llvm-project/pull/227458


More information about the llvm-commits mailing list