[Openmp-commits] [PATCH] D145290: [OpenMP] Ensure memory fences are created with barriers for AMDGPUs

Johannes Doerfert via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Mon May 1 13:32:41 PDT 2023


jdoerfert added inline comments.


================
Comment at: openmp/libomptarget/DeviceRTL/src/Synchronization.cpp:266
+  if (Ordering != atomic::relaxed)
+    fenceTeam(Ordering == atomic::acq_rel ? atomic::release : atomic::seq_cst);
+
----------------
dhruvachak wrote:
> What if I want a release fence before the barrier and nothing else? As a client, I pass in atomic::release and I get a seq_cst fence before and after the barrier. Seems like an overkill.
If you want functionality beyond what is implemented, you need to implement it.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D145290



More information about the Openmp-commits mailing list