uatomic/x86: Remove redundant memory barriers
authorOlivier Dion <odion@efficios.com>
Tue, 22 Aug 2023 20:23:17 +0000 (16:23 -0400)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Fri, 12 Apr 2024 20:12:02 +0000 (16:12 -0400)
commitae5712d110b720768dcc30522171506a4b7f28a4
tree07c33f76a739081abb1bd21331f43111cd74f39e
parent6b071d73cffc66df0bdb9ee3c062143f06923c78
uatomic/x86: Remove redundant memory barriers

When liburcu is configured to _not_ use atomic builtins, the
implementation of atomic operations is done using inline assembler for
each architecture.

Because we control the emitted assembler, we know whether specific
operations (e.g. lock; cmpxchg) already have an implicit memory barrier.
In those cases, emitting an explicit cmm_smp_mb() before/after the
operation is redundant and hurts performance.

Remove those redundant barriers on x86.

Change-Id: Ic1f6cfe9c2afe250946549cf6187f8fa88f5b009
Signed-off-by: Olivier Dion <odion@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
include/urcu/uatomic/generic.h
include/urcu/uatomic/x86.h
This page took 0.025681 seconds and 4 git commands to generate.