[HIP] Add atomic load, atomic store and atomic cmpxchng_weak builtin support in HIP...
authorAnshil Gandhi <Anshil.Gandhi@amd.com>
Mon, 29 Nov 2021 19:06:52 +0000 (12:06 -0700)
committerAnshil Gandhi <Anshil.Gandhi@amd.com>
Mon, 29 Nov 2021 19:07:13 +0000 (12:07 -0700)
commitdf0560ca00182364e0a786d35adb294c3c98dbd0
tree394d64195c29f079f562f7074c92b4ddfd8eccdd
parentfe270ab061fa1200d1f7e121ac6671f7d24b73d6
[HIP] Add atomic load, atomic store and atomic cmpxchng_weak builtin support in HIP-clang

Introduce `__hip_atomic_load`, `__hip_atomic_store` and `__hip_atomic_compare_exchange_weak`
builtins in HIP.

Reviewed By: yaxunl

Differential Revision: https://reviews.llvm.org/D114553
clang/include/clang/AST/Expr.h
clang/include/clang/Basic/Builtins.def
clang/lib/AST/Expr.cpp
clang/lib/AST/StmtPrinter.cpp
clang/lib/CodeGen/CGAtomic.cpp
clang/lib/Sema/SemaChecking.cpp
clang/test/CodeGenCUDA/atomic-ops.cu
clang/test/SemaCUDA/atomic-ops.cu [new file with mode: 0644]