[jdk18] RFR: 8279930: Synthetic cast causes generation of store barriers when using heap segments
Maurizio Cimadamore
mcimadamore at openjdk.java.net
Wed Jan 12 19:10:39 UTC 2022
On Wed, 12 Jan 2022 19:05:30 GMT, Maurizio Cimadamore <mcimadamore at openjdk.org> wrote:
>> src/jdk.incubator.foreign/share/classes/jdk/internal/foreign/HeapMemorySegmentImpl.java line 89:
>>
>>> 87: public static class OfByte extends HeapMemorySegmentImpl {
>>> 88:
>>> 89: OfByte(long offset, Object base, long length, int mask) {
>>
>> Is it possible to retain the array type for the constructor?
>
> yes, that should be harmless
Actually, no, sorry. If I sharpen the type, then `dup` has to cast, so we go back to the original issue.
-------------
PR: https://git.openjdk.java.net/jdk18/pull/97
More information about the core-libs-dev
mailing list