gatomic: Use new __atomic_*() intrinsics for all atomic operations
Previously we used the old
__sync_fetch_*() intrinsics for some of the
atomic operations, such as
available, use the new
__atomic_*() intrinsics for those instead.
As with the rest of our use of
__atomic_*() intrinsics, we use the
__ATOMIC_SEQ_CST memory model. If people want to use a less
restrictive memory model to get better performance in certain
situations, they can use the compiler intrinsics directly themselves.
g_atomic_*() aim to be as fast as possible while remaining general
meson test --repeat 1000 atomic atomic-test
Signed-off-by: Philip Withnall email@example.com