[all-commits] [llvm/llvm-project] 156419: [AMDGPU] Examine instructions in pending queues du...

Austin Kerbow via All-commits all-commits at lists.llvm.org
Sat Sep 6 22:09:07 PDT 2025


  Branch: refs/heads/users/kerbowa/reserved-resource-hazard
  Home:   https://github.com/llvm/llvm-project
  Commit: 156419d29190b2d104aa4f0d93620c2ec8c0e49a
      https://github.com/llvm/llvm-project/commit/156419d29190b2d104aa4f0d93620c2ec8c0e49a
  Author: Austin Kerbow <Austin.Kerbow at amd.com>
  Date:   2025-09-05 (Fri, 05 Sep 2025)

  Changed paths:
    M llvm/lib/Target/AMDGPU/GCNSchedStrategy.cpp
    M llvm/lib/Target/AMDGPU/GCNSchedStrategy.h
    M llvm/test/CodeGen/AMDGPU/llvm.amdgcn.iglp.opt.exp.large.mir
    M llvm/test/CodeGen/AMDGPU/llvm.amdgcn.iglp.opt.ll
    M llvm/test/CodeGen/AMDGPU/llvm.amdgcn.sched.group.barrier.ll
    M llvm/test/CodeGen/AMDGPU/rewrite-vgpr-mfma-to-agpr.ll

  Log Message:
  -----------
  [AMDGPU] Examine instructions in pending queues during scheduling

Examine instructions in the pending queue when scheduling. This makes
instructions visible to scheduling heuristics even when they aren't
immediately issuable due to hardware resource constraints.

The scheduler has two hardware resource modeling modes: an in-order mode
where instructions must be ready to issue before scheduling, and
out-of-order models where instructions are always visible to heuristics.
Special handling exists for unbuffered processor resources in
out-of-order models. These resources can cause pipeline stalls when used
back-to-back, so they're typically avoided. However, for AMDGPU targets,
managing register pressure and reducing spilling is critical enough to
justify exceptions to this approach.

This change enables examination of instructions that can't be
immediately issued because they use an already occupied unbuffered
resource. By making these instructions visible to scheduling heuristics
anyway, we gain more flexibility in scheduling decisions, potentially
allowing better register pressure and hardware resouce management.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list