[Openmp-commits] [PATCH] D95062: [libomptarget][devicertl][nfc] Simplify target_atomic abstraction
Johannes Doerfert via Phabricator via Openmp-commits
openmp-commits at lists.llvm.org
Wed Jan 20 13:31:19 PST 2021
jdoerfert added a comment.
In D95062#2510856 <https://reviews.llvm.org/D95062#2510856>, @tianshilei1992 wrote:
> None of the three atomic operations provided by OpenMP, `read`, `write`, and `update`, sound like similar semantics as the four operations here.
Please finish reading the section about atomics (https://www.openmp.org/spec-html/5.1/openmpsu105.html#x138-1480002.19.7). All of the above operations are expressible, as far as I can tell.
`add` and `inc` are `atomic update`, `exchange` is `atomic capture`, `max` and `cas` are `atomic compare`, all with appropriate expression statement following them.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D95062/new/
https://reviews.llvm.org/D95062
More information about the Openmp-commits
mailing list