[llvm] [RISCV] Sink vp.splat operands of VP intrinsic. (PR #133245)
via llvm-commits
llvm-commits at lists.llvm.org
Mon Apr 14 03:27:21 PDT 2025
================
@@ -2823,41 +2823,55 @@ bool RISCVTTIImpl::isProfitableToSinkOperands(
if (!ST->sinkSplatOperands())
return false;
- for (auto OpIdx : enumerate(I->operands())) {
- if (!canSplatOperand(I, OpIdx.index()))
- continue;
+ // Capture EVL value.
+ Value *EVL = nullptr;
+ if (auto *VPI = dyn_cast<VPIntrinsic>(I))
+ EVL = VPI->getVectorLengthParam();
----------------
NexMing wrote:
Similarly, can we also ignore the lanes that are masked off?
https://github.com/llvm/llvm-project/pull/133245
More information about the llvm-commits
mailing list