SDL2/src/atomic
Cameron Gutman 014f507c40 Use specific acquire and release variants of InterlockedExchange on ARM
_InterlockedExchange_rel() is required for correctness on ARM because
the _ReadWriteBarrier() macro is only a compiler memory barrier, not a
hardware memory barrier. Due to ARM's relaxed memory model, this means
the '*lock = 0' write may be observed before the operations inside the
lock, causing possible corruption of data protected by the lock.

_InterlockedExchange_acq() is more efficient on ARM because it avoids an
expensive full memory barrier that _InterlockedExchange() does.
2021-01-03 12:13:40 -06:00
..
SDL_atomic.c Updated copyright for 2021 2021-01-02 10:25:38 -08:00
SDL_spinlock.c Use specific acquire and release variants of InterlockedExchange on ARM 2021-01-03 12:13:40 -06:00