[llvm] [AMDGPU] Tweak sched model latencies for VALU fast-forward cases (PR #198475)

Jay Foad via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 11 03:17:18 PDT 2026


================
@@ -830,6 +830,22 @@ void GCNSubtarget::adjustSchedDependency(
     Dep.setLatency(InstrInfo.getSchedModel().computeOperandLatency(
         DefI, DefOpIdx, UseI, UseOpIdx));
   }
+
+  // Handle "fast-forward" cases for VALU dependencies via a lanemask-like SGPR:
+  //   V_CMP* -> V_CNDMASK_B32
+  //   V_ADD/SUB with carryout -> V_ADD/SUB with carryin (on GFX10+)
+  switch (UseI->getOpcode()) {
+  case AMDGPU::V_ADDC_U32_e64:
----------------
jayfoad wrote:

Good point. Done. This makes the patch > 2x more disruptive.

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


More information about the llvm-commits mailing list