[llvm] [RISCV] Add Tune to DontSinkSplatOperands (PR #79199)
Wang Pengcheng via llvm-commits
llvm-commits at lists.llvm.org
Tue Jan 23 19:47:54 PST 2024
================
@@ -2000,6 +2000,14 @@ bool RISCVTargetLowering::shouldSinkOperands(
if (!I->getType()->isVectorTy() || !Subtarget.hasVInstructions())
return false;
+ // Don't sink splat operands if the target prefers it. Some targets requires
+ // S2V transfer buffers and we can run out of them copying the same value
+ // repeatedly.
+ // FIXME: It could still be worth doing if it would improve vector register
+ // pressure and prevent a vector spill.
+ if (Subtarget.dontSinkSplatOperands())
----------------
wangpc-pp wrote:
Is this the only place to control the generation of sinked V instructions?
https://github.com/llvm/llvm-project/pull/79199
More information about the llvm-commits
mailing list