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

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 8 08:11:25 PST 2024


================
@@ -5748,7 +5775,8 @@ BoUpSLP::TreeEntry::EntryState BoUpSLP::getScalarsVectorizationState(
   case Instruction::ExtractValue:
   case Instruction::ExtractElement: {
     bool Reuse = canReuseExtract(VL, VL0, CurrentOrder);
-    if (Reuse || !CurrentOrder.empty())
+    // FIXME: Vectorizing is not supported yet for non-power-of-2 ops.
+    if (isPowerOf2_32(VL.size()) && (Reuse || !CurrentOrder.empty()))
----------------
fhahn wrote:

Adjusted, thanks!

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


More information about the llvm-commits mailing list