A release on an atomic object can synchronize with an acquire that reads the released value, establishing happens-before for surrounding accesses. A test-and-set spinlock needs suitable acquisition and release semantics for its guarded data; relaxed flag operations alone do not supply that relationship. This is a separate question from the flag's indivisibility.[ref]
Working Draft, Standard for Programming Language C++ (N4861). pp. 1524–1525: relaxed ordering and release/acquire synchronization
Articles by others on the same topic
There are currently no matching articles.