_Bool
CompareAndSwapInt32 (int32_t *val, int32_t old, int32_t new)
{
- return __atomic_compare_exchange_n (val, &old, new, true, __ATOMIC_SEQ_CST,
+ return __atomic_compare_exchange_n (val, &old, new, false, __ATOMIC_SEQ_CST,
__ATOMIC_RELAXED);
}
{
if (((uintptr_t) val & 7) != 0)
val = NULL;
- return __atomic_compare_exchange_n (val, &old, new, true, __ATOMIC_SEQ_CST,
+ return __atomic_compare_exchange_n (val, &old, new, false, __ATOMIC_SEQ_CST,
__ATOMIC_RELAXED);
}
_Bool
CompareAndSwapUint32 (uint32_t *val, uint32_t old, uint32_t new)
{
- return __atomic_compare_exchange_n (val, &old, new, true, __ATOMIC_SEQ_CST,
+ return __atomic_compare_exchange_n (val, &old, new, false, __ATOMIC_SEQ_CST,
__ATOMIC_RELAXED);
}
{
if (((uintptr_t) val & 7) != 0)
val = NULL;
- return __atomic_compare_exchange_n (val, &old, new, true, __ATOMIC_SEQ_CST,
+ return __atomic_compare_exchange_n (val, &old, new, false, __ATOMIC_SEQ_CST,
__ATOMIC_RELAXED);
}
_Bool
CompareAndSwapUintptr (uintptr_t *val, uintptr_t old, uintptr_t new)
{
- return __atomic_compare_exchange_n (val, &old, new, true, __ATOMIC_SEQ_CST,
+ return __atomic_compare_exchange_n (val, &old, new, false, __ATOMIC_SEQ_CST,
__ATOMIC_RELAXED);
}