[foreign-abi] [Rev 01] RFR: 8247678: StdLibTest fails to create an empty VaList on Windows
Jorn Vernee
jvernee at openjdk.java.net
Tue Jun 16 19:43:44 UTC 2020
On Tue, 16 Jun 2020 15:47:20 GMT, Maurizio Cimadamore <mcimadamore at openjdk.org> wrote:
>> Jorn Vernee has updated the pull request incrementally with one additional commit since the last revision:
>>
>> - Fix SysVVaList confinement issues when closing the EMPTY VaList
>> - Update VaList benchmark to use the new 'make' factory
>
> src/jdk.incubator.foreign/share/classes/jdk/internal/foreign/abi/x64/sysv/SysVVaList.java line 132:
>
>> 131: MemorySegment ms = MemorySegment.allocateNative(LAYOUT);
>> 132: cleaner.register(SysVVaList.class, ms::close);
>> 133: MemoryAddress base = ms.baseAddress();
>
> This will fail because of confinement
Thanks, I fixed it by switching to Unsafe for the allocation, so that we can free from any thread.
-------------
PR: https://git.openjdk.java.net/panama-foreign/pull/208
More information about the panama-dev
mailing list