yaxunl added inline comments.

================
Comment at: clang/test/SemaCUDA/atomic-ops.cu:69-74
+  flag = __hip_atomic_compare_exchange_weak(ptr, 0, 0, 0, 0, 
__HIP_MEMORY_SCOPE_SYSTEM); // expected-warning {{null passed to a callee that 
requires a non-null argument}}
+  flag = __hip_atomic_compare_exchange_weak(ptr, &val, desired, 0, 0, 
__HIP_MEMORY_SCOPE_SYSTEM);
+  flag = __hip_atomic_compare_exchange_weak(ptr, &val, desired, 1, 0, 
__HIP_MEMORY_SCOPE_SINGLETHREAD);
+  flag = __hip_atomic_compare_exchange_weak(ptr, &val, desired, 1, 0, 
__HIP_MEMORY_SCOPE_WAVEFRONT);
+  flag = __hip_atomic_compare_exchange_weak(ptr, &val, desired, 1, 1, 
__HIP_MEMORY_SCOPE_WORKGROUP);
+  flag = __hip_atomic_compare_exchange_weak(ptr, &val, desired, 1, 1, 
__HIP_MEMORY_SCOPE_AGENT);
----------------
pls use pre-defined macros for memory order


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D114553

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to