[jmm-dev] weakCompareAndSet memory semantics

Paul Sandoz paul.sandoz at oracle.com
Wed Apr 20 13:32:56 UTC 2016

> On 20 Apr 2016, at 15:25, Doug Lea <dl at cs.oswego.edu> wrote:
> On 04/20/2016 08:58 AM, Aleksey Shipilev wrote:
>> This raises the naming questions, which will be cast in stone in
>> VarHandles public API:
>> a)
>>   weakCompareAndSet (relaxed!)
>>   weakCompareAndSetAcquire
>>   weakCompareAndSetRelease
>>   weakCompareAndSetVolatile
>> (This provides the symmetry against j.u.c, and does not require re-spec,
>> just adding a new method)
> Let's do it this way.

Ok. I’ll stick to the current naming convention.

I was proposing b) in a previous email (before i read this email).


> The only downside I can imagine is that some
> C++ programmer converting to Java using an an IDE with autocomplete
> might select it by mistake without reading the JavaDoc.

More information about the jmm-dev mailing list