Lines 241-247
Link Here
|
241 |
AtomicPtr::assign(void* ptrNew, const void* const ptrOld) |
241 |
AtomicPtr::assign(void* ptrNew, const void* const ptrOld) |
242 |
{ |
242 |
{ |
243 |
#if defined(_OPENTHREADS_ATOMIC_USE_GCC_BUILTINS) |
243 |
#if defined(_OPENTHREADS_ATOMIC_USE_GCC_BUILTINS) |
244 |
return __sync_bool_compare_and_swap(&_ptr, ptrOld, ptrNew); |
244 |
return __sync_bool_compare_and_swap(&_ptr, (void*)ptrOld, ptrNew); |
245 |
#elif defined(_OPENTHREADS_ATOMIC_USE_MIPOSPRO_BUILTINS) |
245 |
#elif defined(_OPENTHREADS_ATOMIC_USE_MIPOSPRO_BUILTINS) |
246 |
return __compare_and_swap((unsigned long*)&_ptr, (unsigned long)ptrOld, (unsigned long)ptrNew); |
246 |
return __compare_and_swap((unsigned long*)&_ptr, (unsigned long)ptrOld, (unsigned long)ptrNew); |
247 |
#elif defined(_OPENTHREADS_ATOMIC_USE_SUN) |
247 |
#elif defined(_OPENTHREADS_ATOMIC_USE_SUN) |