[PATCH] D151997: [AMDGPU] Document amdgpu_cs_chain[_preserve] CCs. NFC

Jay Foad via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 12 01:39:03 PDT 2023


foad added inline comments.


================
Comment at: llvm/docs/AMDGPUUsage.rst:1113-1118
+                                     However, we add waits for errata / hardware workarounds in the epilog:
+
+                                     * On gfx11+, the function epilog waits for any scratch stores to be confirmed. This
+                                       works around the issue that we must wait for scratch stores before sending a
+                                       ``MSG_DEALLOC_VGPRS`` message.
+                                     * Additional waits may be required (e.g. ``s_waitcnt_depctr``).
----------------
rovka wrote:
> nhaehnle wrote:
> > foad wrote:
> > > I'm not sure any of this belongs in a calling convention description. The dealloc_vgprs thing applies to all kernels regardless of calling convention, but probably doesn't need to be documented to the end user anyway.
> > It is relevant if anybody wanted to try writing compatible code via some non-LLVM mechanism. @t-tye may have opinions on this as well.
> Ok, I'll wait for more feedback on this.
> It is relevant if anybody wanted to try writing compatible code via some non-LLVM mechanism.
Then I don't understand what the part about waitcnts, starting from "Waits for regular memory counters are not inserted", is trying to tell me. (And I speak as someone who //is// quite familiar with the dealloc vgprs issue!) It is written in the style "the compiler does X". Could you rephrase it more like "the required state at a function call boundary is Y"?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D151997/new/

https://reviews.llvm.org/D151997



More information about the llvm-commits mailing list