哈哈,你的这篇文档很好。我之前看cppreference,真是云里雾里。
你这个文档里有个点题一句:
The relaxed mode is most commonly used when the programmer *simply wants an variable to be atomic* in nature rather than using it to synchronize threads for other shared memory data.
【 在 libgcc 的大作中提到: 】
:
https://gcc.gnu.org/wiki/Atomic/GCCMM/AtomicSync: -Thread 1-
: y.store (20, memory_order_relaxed)
: ...................
--
FROM 117.39.204.*