[PATCH] D76373: [LV] Replace stored value with a VPValue (NFCI)

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 24 02:39:53 PDT 2020


fhahn added inline comments.


================
Comment at: llvm/lib/Transforms/Vectorize/VPlan.h:1066
 /// provided.
 class VPWidenMemoryInstructionRecipe : public VPRecipeBase {
 private:
----------------
I think it might be good to document what operands `User` has for loads & stores with and w/o masking.


================
Comment at: llvm/lib/Transforms/Vectorize/VPlan.h:1106
+    // Mask is optional and therefore the last operand.
+    return IsMasked ? User.getOperand(User.getNumOperands() - 1) : nullptr;
+  }
----------------
Do we need the extra `IsMasked` operand?  Would it be sufficient to check the number of operands and use Load with 2 ops => has as mask, Store with 3 ops => has a mask?


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

https://reviews.llvm.org/D76373





More information about the llvm-commits mailing list