Commit a3c295d4 authored by Zebediah Figura's avatar Zebediah Figura Committed by Alexandre Julliard

include: Add InterlockedIncrement16() and InterlockedDecrement16().

parent 0d1345ac
......@@ -6905,7 +6905,9 @@ static inline BOOLEAN BitScanReverse(DWORD *index, DWORD mask)
#pragma intrinsic(_InterlockedExchange)
#pragma intrinsic(_InterlockedExchangeAdd)
#pragma intrinsic(_InterlockedIncrement)
#pragma intrinsic(_InterlockedIncrement16)
#pragma intrinsic(_InterlockedDecrement)
#pragma intrinsic(_InterlockedDecrement16)
#pragma intrinsic(_InterlockedOr)
long _InterlockedAnd(long volatile *,long);
......@@ -6915,9 +6917,11 @@ long long _InterlockedCompareExchange64(long long volatile*,long long,long long)
unsigned char _InterlockedCompareExchange128(volatile __int64 *, __int64, __int64, __int64 *);
#endif
long _InterlockedDecrement(long volatile*);
short _InterlockedDecrement16(short volatile*);
long _InterlockedExchange(long volatile*,long);
long _InterlockedExchangeAdd(long volatile*,long);
long _InterlockedIncrement(long volatile*);
short _InterlockedIncrement16(short volatile*);
long _InterlockedOr(long volatile *,long);
static FORCEINLINE LONG WINAPI InterlockedAnd( LONG volatile *dest, LONG val )
......@@ -6957,11 +6961,21 @@ static FORCEINLINE LONG WINAPI InterlockedIncrement( LONG volatile *dest )
return _InterlockedIncrement( (long volatile *)dest );
}
static FORCEINLINE short WINAPI InterlockedIncrement16( short volatile *dest )
{
return _InterlockedIncrement16( (long volatile *)dest );
}
static FORCEINLINE LONG WINAPI InterlockedDecrement( LONG volatile *dest )
{
return _InterlockedDecrement( (long volatile *)dest );
}
static FORCEINLINE short WINAPI InterlockedDecrement16( short volatile *dest )
{
return _InterlockedDecrement16( (long volatile *)dest );
}
static FORCEINLINE LONG WINAPI InterlockedOr( LONG volatile *dest, LONG val )
{
return _InterlockedOr( (long volatile *)dest, val );
......@@ -7098,11 +7112,21 @@ static FORCEINLINE LONG WINAPI InterlockedIncrement( LONG volatile *dest )
return __sync_add_and_fetch( dest, 1 );
}
static FORCEINLINE short WINAPI InterlockedIncrement16( short volatile *dest )
{
return __sync_add_and_fetch( dest, 1 );
}
static FORCEINLINE LONG WINAPI InterlockedDecrement( LONG volatile *dest )
{
return __sync_add_and_fetch( dest, -1 );
}
static FORCEINLINE short WINAPI InterlockedDecrement16( short volatile *dest )
{
return __sync_add_and_fetch( dest, -1 );
}
static FORCEINLINE void * WINAPI InterlockedExchangePointer( void *volatile *dest, void *val )
{
void *ret;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment