[PATCH] D149773: [AMDGPU][IGLP] Add iglp_opt(1) strategy for single wave gemms

Jeffrey Byrnes via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed May 3 10:19:08 PDT 2023


jrbyrnes created this revision.
jrbyrnes added a reviewer: kerbowa.
Herald added subscribers: kosarev, foad, hiraditya, tpr, dstuttard, yaxunl, jvesely, kzhuravl, arsenm.
Herald added a project: All.
jrbyrnes requested review of this revision.
Herald added subscribers: llvm-commits, wdng.
Herald added a project: LLVM.

This adds the IGLP strategy for single-wave gemms. The SchedGroup pipeline is laid out in multiple phases, with each phase corresponding to a distinct pattern present in gemm kernels. The resilience of the optimization is dependent upon IR (as seen by pre-RA scheduling) continuing to have these patterns (as defined by instruction class and dependencies) in their current relative ordering.

The kernels of interest have these specific phases:
NT: 1, 2a, 2c
NN: 1, 2a, 2b
TT: 1, 2b, 2c
TN: 1, 2b

The general approach taken was to have a long SchedGroup pipeline. In this way the scheduler will have less capability of doing the wrong thing. In order to resolve the challenge of correctly fitting these long pipelines, we leverage the rules infrastructure to help the solver.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D149773

Files:
  llvm/lib/Target/AMDGPU/AMDGPUIGroupLP.cpp
  llvm/test/CodeGen/AMDGPU/llvm.amdgcn.iglp.opt.single.2b.mir
  llvm/test/CodeGen/AMDGPU/llvm.amdgcn.iglp.opt.single.2c.mir

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D149773.519150.patch
Type: text/x-patch
Size: 78541 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230503/226fbd6d/attachment.bin>


More information about the llvm-commits mailing list