[jmm-dev] Specifying VarHandle acquire/release without ill effects

Andrew Haley aph at redhat.com
Fri Jun 17 08:08:50 UTC 2016

On 16/06/16 21:28, Aleksey Shipilev wrote:

> The clause about reorderings trips users into believing that
> getAcquire and putRelease have fence-like semantics. But in reality,
> they are weaker than fences, because optimizers are not obliged to
> introduce barriers around the operation to get the needed semantics.

I've read this several times now and I still do not understand it.
Release and acquire are well-defined terms in the industry, and I
can't think of any great reason to add more words like yours, which
seem to make things even more confusing than they were.  The wording
which is there seems to me to be accurate, at least, as a description
of release and acquire.


More information about the jmm-dev mailing list