DEVEL15-rx-no-interlockedadd-20080311

LICENSE IPL10

InterlockedAdd is only supported on Itanium


(cherry picked from commit 9cc4a8e02c)
This commit is contained in:
Jeffrey Altman 2008-03-12 05:13:59 +00:00
parent e57370db9f
commit 75673c15f2

View File

@ -1053,13 +1053,17 @@ typedef struct rx_interface_stat {
#define rx_MutexDecrement(object, mutex) InterlockedDecrement(&object)
#define rx_MutexAdd1Increment2(object1, addend, object2, mutex) \
do { \
InterlockedAdd(&object1, addend); \
MUTEX_ENTER(&mutex); \
object1 += addend; \
InterlockedIncrement(&object2); \
MUTEX_EXIT(&mutex); \
} while (0)
#define rx_MutexAdd1Decrement2(object1, addend, object2, mutex) \
do { \
InterlockedAdd(&object1, addend); \
MUTEX_ENTER(&mutex); \
object1 += addend; \
InterlockedDecrement(&object2); \
MUTEX_EXIT(&mutex); \
} while (0)
#else
#define rx_MutexIncrement(object, mutex) \