Changeset View
Changeset View
Standalone View
Standalone View
sys/sys/atomic_common.h
Show First 20 Lines • Show All 72 Lines • ▼ Show 20 Lines | |||||
/* | /* | ||||
* Currently all architectures provide acquire and release fences on their own, | * Currently all architectures provide acquire and release fences on their own, | ||||
* but they don't provide consume. Kludge below allows relevant code to stop | * but they don't provide consume. Kludge below allows relevant code to stop | ||||
* openly resorting to the stronger acquire fence, to be sorted out. | * openly resorting to the stronger acquire fence, to be sorted out. | ||||
*/ | */ | ||||
#define atomic_load_consume_ptr(p) \ | #define atomic_load_consume_ptr(p) \ | ||||
((__typeof(*p)) atomic_load_acq_ptr((uintptr_t *)p)) | ((__typeof(*p)) atomic_load_acq_ptr((uintptr_t *)p)) | ||||
#define atomic_interrupt_fence() __compiler_membar() | |||||
#endif | #endif |