[llvm] [SLP] Initial vectorization of non-power-of-2 ops. (PR #77790)

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 31 08:23:07 PST 2024


================
@@ -3904,6 +3915,9 @@ static LoadsState canVectorizeLoads(ArrayRef<Value *> VL, const Value *VL0,
   Order.clear();
   // Check the order of pointer operands or that all pointers are the same.
   bool IsSorted = sortPtrAccesses(PointerOps, ScalarTy, DL, SE, Order);
+  if (!Order.empty() && !isPowerOf2_32(VL.size()))
----------------
fhahn wrote:

Added FIXME and added `assert(VectorizeNonPowerOf2)`, thanks!

https://github.com/llvm/llvm-project/pull/77790


More information about the llvm-commits mailing list