for review: 8236522: "always atomic" modifier for inline classes to enforce atomicity
Frederic Parain
frederic.parain at oracle.com
Wed Jan 15 14:03:02 UTC 2020
Regarding the runtime part of the code:
instanceKlass.hpp:442
In addition to the setter, a getter should be provided for the
new _is_naturally_atomic bit, this would prevent the implementation
details to leak to valueKlass.hpp:211
Thank you,
Fred
> On Dec 24, 2019, at 16:36, John Rose <john.r.rose at oracle.com> wrote:
>
> The webrev is updated in place, with an improved unit test
> for detecting tearing and its absence.
>
> This uncovered a missing StoreStore barrier in C2, which I also fixed.
>
> BTW, the funny pattern match logic for class names is not just for
> this change set. We will want the same pattern match for other
> at hoc diagnostics, such as flagging surprising synchronization.
>
> — John
>
> On Dec 24, 2019, at 12:05 AM, John Rose <john.r.rose at oracle.com> wrote:
>>
>> Define a new modifier which enforces atomicity of all instances (in the heap) of the given inline class.
>>
>> Working title "__AlwaysAtomic". Suggested final "alwaysatomic" or just "atomic".
>>
>> Represented in classfile using currently free modifier bit 0x0040 = ACC_VOLATILE.
>>
>> https://bugs.openjdk.java.net/browse/JDK-8236522
>> http://cr.openjdk.java.net/~jrose/jvm/atomic-8236522
>>
>
More information about the valhalla-dev
mailing list