Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update documentation for buffer fat pointers #92034

Merged
merged 1 commit into from
May 14, 2024

Conversation

krzysz00
Copy link
Contributor

Now that we've got (minus some issues around datatypes and invariant loads) working lowerings for address space 7, update the table in the AMDGPU usage guide to proerly indicate the nature of these address spaces.

Now that we've got (minus some issues around datatypes and invariant
loads) working lowerings for address space 7, update the table in
the AMDGPU usage guide to proerly indicate the nature of these address
spaces.
@llvmbot
Copy link
Collaborator

llvmbot commented May 13, 2024

@llvm/pr-subscribers-backend-amdgpu

Author: Krzysztof Drewniak (krzysz00)

Changes

Now that we've got (minus some issues around datatypes and invariant loads) working lowerings for address space 7, update the table in the AMDGPU usage guide to proerly indicate the nature of these address spaces.


Full diff: https://github.com/llvm/llvm-project/pull/92034.diff

1 Files Affected:

  • (modified) llvm/docs/AMDGPUUsage.rst (+2-2)
diff --git a/llvm/docs/AMDGPUUsage.rst b/llvm/docs/AMDGPUUsage.rst
index 029db00134c09..edf58b562a449 100644
--- a/llvm/docs/AMDGPUUsage.rst
+++ b/llvm/docs/AMDGPUUsage.rst
@@ -824,8 +824,8 @@ supported for the ``amdgcn`` target.
      Constant                              4               constant    *same as global* 64      0x0000000000000000
      Private                               5               private     scratch          32      0xFFFFFFFF
      Constant 32-bit                       6               *TODO*                               0x00000000
-     Buffer Fat Pointer (experimental)     7               *TODO*
-     Buffer Resource (experimental)        8               *TODO*
+     Buffer Fat Pointer                    7               N/A         N/A              160     0
+     Buffer Resource                       8               N/A         V#               128     0x00000000000000000000000000000000
      Buffer Strided Pointer (experimental) 9               *TODO*
      Streamout Registers                   128             N/A         GS_REGS
      ===================================== =============== =========== ================ ======= ============================

@krzysz00
Copy link
Contributor Author

One thing I noticed while writing this: should the AMDGPU metadata streamer be updated so that ptr addrspace(8) inputs to kernels get the type "image" and not "global buffer"?

@arsenm
Copy link
Contributor

arsenm commented May 13, 2024

One thing I noticed while writing this: should the AMDGPU metadata streamer be updated so that ptr addrspace(8) inputs to kernels get the type "image" and not "global buffer"?

I'm not sure what "image" is supposed to mean there, but an arbitrary resource descriptor isn't necessarily an image

@krzysz00
Copy link
Contributor Author

@arsenm I meant this code right here https://github.com/llvm/llvm-project/blob/main/llvm/lib/Target/AMDGPU/AMDGPUHSAMetadataStreamer.cpp#L120-L136 - it seems like if you provide type hints to your kernel, various buffer descriptors become "image" in the metadata?

@krzysz00 krzysz00 merged commit ac0d415 into llvm:main May 14, 2024
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants