Can a bool read/write operation be not atomic on x86? [duplicate]
There are three separate issues that “atomic” types in C++11 address: tearing: a read or write involves multiple bus cycles, and a thread switch occurs in the middle of the operation; this can produce incorrect values. cache coherence: a write from one thread updates its processor’s cache, but does not update global memory; a read … Read more