[PATCH] D146031: [AMDGPU] Add MMOs for GFX11 Streamout Instructions

Diana Picus via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 14 03:54:06 PDT 2023


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

The GFX11 NGG Streamout Instructions perform atomic operations on
dedicated registers. At the moment, they lack machine memory operands,
which causes the si-memory-legalizer pass to treat them conservatively
and introduce several unnecessary waits and cache invalidations.

This patch introduces a new address space to represent these special
registers and teaches instruction selection to add memory operands with
this new address space to DS_ADD/SUB_GS_REG_RTN.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D146031

Files:
  llvm/docs/AMDGPUUsage.rst
  llvm/include/llvm/IR/IntrinsicsAMDGPU.td
  llvm/lib/Target/AMDGPU/AMDGPU.h
  llvm/lib/Target/AMDGPU/SIISelLowering.cpp
  llvm/test/CodeGen/AMDGPU/llvm.amdgcn.ds.add.gs.reg.rtn.ll
  llvm/test/CodeGen/AMDGPU/llvm.amdgcn.ds.sub.gs.reg.rtn.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D146031.505017.patch
Type: text/x-patch
Size: 8253 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230314/e1868cb5/attachment.bin>


More information about the llvm-commits mailing list