Added atomic_compare_exchange_strong_acq_rel macro

It is much better to read than:
atomic_compare_exchange_strong_explicit() with 5 arguments.
This commit is contained in:
Diego Fronza
2020-02-11 17:21:13 -03:00
parent a04cdde45d
commit c210413a8a

View File

@@ -46,6 +46,9 @@
#define atomic_compare_exchange_strong_relaxed(o, e, d) \
atomic_compare_exchange_strong_explicit( \
(o), (e), (d), memory_order_relaxed, memory_order_relaxed)
#define atomic_compare_exchange_strong_acq_rel(o, e, d) \
atomic_compare_exchange_strong_explicit( \
(o), (e), (d), memory_order_acq_rel, memory_order_acquire)
/* Acquire-Release Memory Ordering */