[PATCH] D57059: [SLP] Initial support for the vectorization of the non-power-of-2 vectors.

Simon Pilgrim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 9 11:14:27 PST 2020


RKSimon added inline comments.


================
Comment at: llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp:3172-3174
+          !(VL0->getOperand(0)->getType()->isIntegerTy() ||
+            VL0->getOperand(0)->getType()->isFloatingPointTy() ||
+            VL0->getOperand(0)->getType()->isPointerTy())) {
----------------
ABataev wrote:
> spatel wrote:
> > Use isValidElementType() or check for undef directly?
> > I still can't tell from the debug statement exactly what we are guarding against. Should the type check already be here even without this patch?
> I was just trying to protect the code and try to support it only for simple types at first. There are some doubts that the cost for masked loads/stores is completed and I protected it to make it work only for simple types. I can remove this check if the cost model for masked ops is good enough.
masked load/store costs for constant masks should be good enough now (getScalarizationOverhead should now provide us with a reasonable fallback)


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D57059



More information about the llvm-commits mailing list