diff options
author | Richard Braun <rbraun@sceen.net> | 2019-08-16 20:54:18 +0200 |
---|---|---|
committer | Richard Braun <rbraun@sceen.net> | 2019-08-16 20:54:56 +0200 |
commit | 672cb64d45f77fc804c6d250e55e53e22fc65813 (patch) | |
tree | 5b127baec87ae9ca25b1c9ffa20e1b2a07687a3a | |
parent | eca41c204162da52e54ca340f6a73d13bbdc7a7b (diff) |
Use atomic signal fences in the x86 local atomic implementation
-rw-r--r-- | arch/x86/machine/latomic.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/x86/machine/latomic.h b/arch/x86/machine/latomic.h index efc8301c..6684d20f 100644 --- a/arch/x86/machine/latomic.h +++ b/arch/x86/machine/latomic.h @@ -30,21 +30,21 @@ #include <kern/macros.h> /* - * Memory ordering is implemented with compiler barriers on entry, exit, + * Memory ordering is implemented with atomic signal fences on entry, exit, * both, or neither, according to the specified ordering. */ #define latomic_x86_enter(memorder) \ MACRO_BEGIN \ if ((memorder) != LATOMIC_RELAXED && (memorder) != LATOMIC_ACQUIRE) { \ - barrier(); \ + __atomic_signal_fence(__ATOMIC_ACQ_REL); \ } \ MACRO_END #define latomic_x86_leave(memorder) \ MACRO_BEGIN \ if ((memorder) != LATOMIC_RELAXED && (memorder) != LATOMIC_RELEASE) { \ - barrier(); \ + __atomic_signal_fence(__ATOMIC_ACQ_REL); \ } \ MACRO_END |