[PATCH] D150027: [VPlan] Use VPOpWithIRFlags for VPReplicateRecipe, retire poison map.

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon May 15 03:50:45 PDT 2023


fhahn added inline comments.


================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:1074
       // either drop them directly if the recipe already models the flags or
       // collect them in a set.
       // TODO: Migrate all relevant recipes to hold their own flags.
----------------
Ayal wrote:
> Update above comment and remove TODO below?
Done in the committed version, thanks!


================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:1076-1078
+      if (auto *OpWithFlags = dyn_cast<VPRecipeWithIRFlags>(CurRec)) {
+        OpWithFlags->dropPoisonGeneratingFlags();
+      } else {
----------------
Ayal wrote:
> 
Done in the committed version, thanks!


================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:2849
   // load/store.
-  if (State.MayGeneratePoisonRecipes.contains(RepRecipe))
-    Cloned->dropPoisonGeneratingFlags();
+  Cloned->dropPoisonGeneratingFlags();
+	RepRecipe->setFlags(Cloned);
----------------
Ayal wrote:
> Above is redundant and should be dropped?
Dropped together wit the comment which is stale now.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D150027



More information about the llvm-commits mailing list