diff --git a/dtool/src/dtoolbase/mutexSpinlockImpl.cxx b/dtool/src/dtoolbase/mutexSpinlockImpl.cxx index 73f2683ff2..788152422c 100644 --- a/dtool/src/dtoolbase/mutexSpinlockImpl.cxx +++ b/dtool/src/dtoolbase/mutexSpinlockImpl.cxx @@ -20,6 +20,8 @@ #if defined(__i386__) || defined(__x86_64) || defined(_M_IX86) || defined(_M_X64) #include #define PAUSE() _mm_pause() +#elif defined(_WIN32) +#define PAUSE() YieldProcessor() #else #define PAUSE() #endif diff --git a/panda/src/pipeline/conditionVarSpinlockImpl.cxx b/panda/src/pipeline/conditionVarSpinlockImpl.cxx index 2b4be0d4e7..c5dc58ff96 100644 --- a/panda/src/pipeline/conditionVarSpinlockImpl.cxx +++ b/panda/src/pipeline/conditionVarSpinlockImpl.cxx @@ -21,6 +21,8 @@ #if defined(__i386__) || defined(__x86_64) || defined(_M_IX86) || defined(_M_X64) #include #define PAUSE() _mm_pause() +#elif defined(_WIN32) +#define PAUSE() YieldProcessor() #else #define PAUSE() #endif diff --git a/panda/src/pipeline/reMutexSpinlockImpl.cxx b/panda/src/pipeline/reMutexSpinlockImpl.cxx index de0b2c0355..4ad9b12410 100644 --- a/panda/src/pipeline/reMutexSpinlockImpl.cxx +++ b/panda/src/pipeline/reMutexSpinlockImpl.cxx @@ -21,6 +21,8 @@ #if defined(__i386__) || defined(__x86_64) || defined(_M_IX86) || defined(_M_X64) #include #define PAUSE() _mm_pause() +#elif defined(_WIN32) +#define PAUSE() YieldProcessor() #else #define PAUSE() #endif