[Openmp-commits] [PATCH] D62393: [OPENMP][NVPTX]Mark parallel level counter as volatile.

Alexey Bataev via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Wed Jun 26 08:56:52 PDT 2019


ABataev marked an inline comment as done.
ABataev added inline comments.


================
Comment at: libomptarget/deviceRTLs/nvptx/src/supporti.h:95-99
+#ifdef __LP64__
+               "l"
+#else  // __LP64__
+               "r"
+#endif // __LP64__
----------------
tra wrote:
> Perhaps it can be deduped into something like this:
> ```
> #ifdef __LP64__
> #define PTR_CONSTRAINT               "l"
> #else  // __LP64__
> #define PTR_CONSTRAINT               "r"
> #endif // __LP64__
> 
> ... 
> asm volatile("st.volatile.u8 [%1], %0;" ::"r"(Val), : PTR_CONSTRAINT (&parLevel) 
>              : "memory");
> 
> ```
Sure, thanks.


Repository:
  rOMP OpenMP

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

https://reviews.llvm.org/D62393





More information about the Openmp-commits mailing list