comments and spaces

develop
Petr Mrázek 2010-02-28 21:21:20 +01:00
parent c4cb3afd0b
commit 39e23dab24
1 changed files with 8 additions and 8 deletions

@ -21,15 +21,15 @@
#define WINVER 0x0501 // OpenThread(), PSAPI, Toolhelp32
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#define SCHED_YIELD Sleep(0);
#define SCHED_YIELD Sleep(0); // slow on single-core, but avoids infinite lockup
// FIXME: detect MSVC here and use the right barrier magic
#ifdef __MINGW32__
#define full_barrier asm volatile("" ::: "memory");
#else
#include <intrin.h>
#pragma intrinsic(_ReadWriteBarrier)
#define full_barrier _ReadWriteBarrier();
#endif
#ifdef __MINGW32__
#define full_barrier asm volatile("" ::: "memory");
#else
#include <intrin.h>
#pragma intrinsic(_ReadWriteBarrier)
#define full_barrier _ReadWriteBarrier();
#endif
#endif