[PATCH] D132022: [SCEVExpander] Drop poison-generating flags on hoisting. PR57187
Florian Hahn via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Aug 17 07:33:18 PDT 2022
fhahn added inline comments.
================
Comment at: llvm/lib/Transforms/Utils/ScalarEvolutionExpander.cpp:1056
+ // Drop flags that are potentially inferred from old context.
+ I->dropPoisonGeneratingFlags();
}
----------------
This seems too pessimistic and unnecessarily drops flags that are not inferred based on the context instruction, e.g. because the original IV already had `nuw/nsw`.
Would it be possible to preserve the flags valid at entry of the loop when hoisting?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D132022/new/
https://reviews.llvm.org/D132022
More information about the llvm-commits
mailing list