[llvm] [polly] [SCEV] Move NoWrapFlags definition outside SCEV scope, use for SCEVUse. (PR #190199)
Florian Hahn via llvm-commits
llvm-commits at lists.llvm.org
Fri Apr 3 05:51:42 PDT 2026
================
@@ -302,9 +302,9 @@ Value *SCEVExpander::InsertBinop(Instruction::BinaryOps Opcode,
auto canGenerateIncompatiblePoison = [&Flags](Instruction *I) {
// Ensure that no-wrap flags match.
if (isa<OverflowingBinaryOperator>(I)) {
- if (I->hasNoSignedWrap() != (Flags & SCEV::FlagNSW))
+ if (I->hasNoSignedWrap() != any(Flags & SCEV::FlagNSW))
----------------
fhahn wrote:
This change causes the functional changes in both Polly and the added C++ unit test (added because I could not easily construct and IR based test, as this requires re-use across different expansions).
Previously the bool would get converted to an int and the compare would never match.
https://github.com/llvm/llvm-project/pull/190199
More information about the llvm-commits
mailing list