[PATCH] D111846: [LV] Drop NUW/NSW flags from instructions that need predication
Sanjay Patel via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Oct 20 07:45:04 PDT 2021
spatel added inline comments.
================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:3045
+// linearizing the control flow as a result of vectorization.
+static void clearUnsafeFlagsAfterLinearizingCF(Instruction *NewInst) {
+ if (isa<OverflowingBinaryOperator>(NewInst)) {
----------------
This could be Instruction::dropPoisonGeneratingFlags() instead of new code? That also handles GEP's `inbounds` flag. If `inbounds` is also a concern with this transform, can we add a test for it?
Note that `dropPoisonGeneratingFlags` has a TODO comment for FMF.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D111846/new/
https://reviews.llvm.org/D111846
More information about the llvm-commits
mailing list