[clang] [llvm] AMDGPU: Add builtin/intrinsic global_(load|store)_b128 (PR #172090)
Matt Arsenault via cfe-commits
cfe-commits at lists.llvm.org
Mon Dec 15 06:39:28 PST 2025
================
@@ -5243,6 +5243,43 @@ returns the bit at the position of the current lane. It is almost equivalent to
``(mask & (1 << lane_id)) != 0``, except that its behavior is only defined if
the given mask has the same value for all active lanes of the current wave.
+
+__builtin_amdgcn_global_load_b128 and __builtin_amdgcn_global_store_b128
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+Signature:
+
+.. code-block:: c
+
+ typedef __attribute__((__vector_size__(4 * sizeof(unsigned int)))) unsigned int v4u;
+ typedef v4u __attribute__((address_space(1))) *global_ptr_to_v4u;
----------------
arsenm wrote:
```suggestion
typedef v4u __attribute__((opencl_global)) *global_ptr_to_v4u;
```
Don't suggest using numbered address spaces
https://github.com/llvm/llvm-project/pull/172090
More information about the cfe-commits
mailing list