[llvm] [SLP] More accurately cost RISCV scalar splats (PR #213104)
Ryan Buchner via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 4 12:05:03 PDT 2026
================
@@ -22858,6 +22669,9 @@ ResTy BoUpSLP::processBuildVector(const TreeEntry *E, Type *ScalarTy,
// Gather unique scalars and all constants.
SmallVector<int> ReuseMask(GatheredScalars.size(), PoisonMaskElem);
TryPackScalars(GatheredScalars, ReuseMask, /*IsRootPoison=*/true);
+ if constexpr (std::is_same_v<BVTy, ShuffleCostEstimator>)
+ ShuffleBuilder.checkForFoldingSplat(E, ReuseMask);
----------------
bababuck wrote:
Thanks for the clarification, this helps lots, working on the updates!
https://github.com/llvm/llvm-project/pull/213104
More information about the llvm-commits
mailing list