extern "C" {
#endif
-#ifndef BITS_PER_LONG
-#define BITS_PER_LONG (__SIZEOF_LONG__ * 8)
-#endif
-
#ifndef uatomic_set
#define uatomic_set(addr, v) STORE_SHARED(*(addr), (v))
#endif
do {
old = uatomic_read((unsigned int *)addr);
- while (!__sync_bool_compare_and_swap_4(addr, old, val));
+ } while (!__sync_bool_compare_and_swap_4(addr, old, val));
- } return old;
+ return old;
}
#if (BITS_PER_LONG == 64)
case 8: