mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-19 22:48:18 +00:00
Using MemoryBarrier() for CPUs not supporting SSE2
This commit is contained in:
parent
234a76f0b3
commit
9b81779ae3
|
@ -35,6 +35,9 @@
|
|||
#elif defined(_MSC_VER)
|
||||
#include <intrin.h>
|
||||
|
||||
#define WIN32_LEAN_AND_MEAN
|
||||
#include <windows.h>
|
||||
|
||||
inline unsigned atomic_inc(volatile unsigned *pValue)
|
||||
{
|
||||
return _InterlockedIncrement((volatile long *)pValue);
|
||||
|
@ -52,7 +55,7 @@
|
|||
|
||||
inline void sync_barrier()
|
||||
{
|
||||
_mm_mfence();
|
||||
MemoryBarrier();
|
||||
}
|
||||
#else
|
||||
#error missing atomic implementation for this compiler
|
||||
|
|
|
@ -7,7 +7,6 @@
|
|||
|
||||
#include <base/math.h>
|
||||
#include <base/system.h>
|
||||
#include <base/tl/threading.h>
|
||||
|
||||
#include <engine/client.h>
|
||||
#include <engine/config.h>
|
||||
|
|
Loading…
Reference in a new issue