[llvm] AMDGPU: VALU data fast-forwarding needs no s_delay (PR #205481)
Jay Foad via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 8 03:15:15 PDT 2026
================
@@ -400,6 +452,16 @@ class AMDGPUInsertDelayAlu {
// ignore this operand.
if (MI.getOpcode() == AMDGPU::V_WRITELANE_B32 && Op.isTied())
continue;
+ // Suppress the delay for VCC operands when both the
+ // producer and consumer are in the hardware fast-forward set.
+ Register Reg = Op.getReg();
+ if (Reg == VccReg && isFastForwardConsumer(MI) &&
----------------
jayfoad wrote:
Really I think you need to do this by detecting specific operands of the producer/consumer instruction, not just checking that the register is VCC. For example VCC could be used for a normal data operand, which should not fast-forward, or VOP3 encoded instructions could use some other SGPR for a mask operand, which should fast-forward.
https://github.com/llvm/llvm-project/pull/205481
More information about the llvm-commits
mailing list