[llvm-branch-commits] [llvm] [LangRef][AMDGPU] Specify that syncscope can cause atomic operations to race (PR #189015)
via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Mon Apr 13 05:08:29 PDT 2026
================
@@ -3934,7 +3934,8 @@ Given that definition, R\ :sub:`byte` is defined as follows:
- Otherwise, if R is atomic, and all the writes R\ :sub:`byte` may
see are atomic, it chooses one of the values written. See the :ref:`Atomic
Memory Ordering Constraints <ordering>` section for additional
- constraints on how the choice is made.
+ constraints on how the choice is made. Targets may impose additional
+ requirements on R and the writes it may see based on their ``syncscope``.
----------------
gonzalobg wrote:
> That seems correct. But where is this quoted from?
[CUDA C++ Programming Guide - Memory Model](https://docs.nvidia.com/cuda/cuda-programming-guide/05-appendices/cuda-cpp-memory-model.html#data-races).
> In fact we are already trying to build something much more comprehensive in a separate RFC[1]. It will be really good to continue this discussion over there.
Thank you, that makes sense, lets move this discussion over there.
https://github.com/llvm/llvm-project/pull/189015
More information about the llvm-branch-commits
mailing list