diff options
author | 2016-05-02 21:22:46 -0700 | |
---|---|---|
committer | 2016-05-02 21:22:46 -0700 | |
commit | 0bc11711b7f2f33bd4e399bda46e4c20ac4bc6ca (patch) | |
tree | cf86afd230e101ea700597a15ca0558720204b06 /include/grpc/impl/codegen/atm_gcc_atomic.h | |
parent | dfbb1c080aa22e1f39cd934e1dc731ee4c74100b (diff) |
Direct translation of http://www.1024cores.net/home/lock-free-algorithms/queues/intrusive-mpsc-node-based-queue
Diffstat (limited to 'include/grpc/impl/codegen/atm_gcc_atomic.h')
-rw-r--r-- | include/grpc/impl/codegen/atm_gcc_atomic.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/grpc/impl/codegen/atm_gcc_atomic.h b/include/grpc/impl/codegen/atm_gcc_atomic.h index 8caf7edbde..7d4ae98cf7 100644 --- a/include/grpc/impl/codegen/atm_gcc_atomic.h +++ b/include/grpc/impl/codegen/atm_gcc_atomic.h @@ -69,4 +69,6 @@ static __inline int gpr_atm_rel_cas(gpr_atm *p, gpr_atm o, gpr_atm n) { __ATOMIC_RELAXED); } +#define gpr_atm_full_xchg(p, n) __atomic_exchange_n((p), (n), __ATOMIC_ACQ_REL) + #endif /* GRPC_IMPL_CODEGEN_ATM_GCC_ATOMIC_H */ |