[PATCH] D150028: [VPlan] Clear reduction flags directly as VPlanTransform.

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Jul 9 13:13:05 PDT 2023


fhahn marked 2 inline comments as done.
fhahn added inline comments.


================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:8846
                              RecipeBuilder, Range.Start);
+  VPlanTransforms::clearReductionWrapFlags(*Plan);
 
----------------
Ayal wrote:
> nit: should it be part of adjustRecipesForReductions() - which adjusts not only inloop reductions contrary to comment?
Adjusted in the committed version, thanks!


================
Comment at: llvm/lib/Transforms/Vectorize/VPlanTransforms.cpp:770
+    SmallVector<VPValue *, 8> Worklist;
+    SmallPtrSet<VPValue *, 8> Visited;
+    Worklist.push_back(PhiR);
----------------
Ayal wrote:
> nit (independent of this patch): use a single SmallSetVector Worklist?
Adjusted in the committed version, thanks!


================
Comment at: llvm/lib/Transforms/Vectorize/VPlanTransforms.cpp:776-779
+      if (auto *OpWithFlags =
+              dyn_cast<VPRecipeWithIRFlags>(Cur->getDefiningRecipe())) {
+        OpWithFlags->dropPoisonGeneratingFlags();
+      }
----------------
Ayal wrote:
> 
Adjusted in the committed version, thanks!


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D150028/new/

https://reviews.llvm.org/D150028



More information about the llvm-commits mailing list