By: Gabriele Svelto (gabriele.svelto.delete@this.gmail.com), December 8, 2014 7:10 pm
Room: Moderated Discussions
Konrad Schwarz (no.spam.delete@this.no.spam) on December 7, 2014 2:28 pm wrote:
> Atomic operations with acquire/release semantics are in the same boat, of course.
No, because a mutex effectively implements full sequential consistency around the protected region, acquire/release is weaker. This is reflected in the implementation of both on POWER, for example. You can provide atomics with acquire/release semantics using only lwsync instructions while a mutex will need isync/sync to work properly.
> Atomic operations with acquire/release semantics are in the same boat, of course.
No, because a mutex effectively implements full sequential consistency around the protected region, acquire/release is weaker. This is reflected in the implementation of both on POWER, for example. You can provide atomics with acquire/release semantics using only lwsync instructions while a mutex will need isync/sync to work properly.