RFR: 8275063: Implementation of Foreign Function & Memory API (Second incubator) [v10]
Paul Sandoz
psandoz at openjdk.java.net
Tue Nov 2 00:27:23 UTC 2021
On Mon, 1 Nov 2021 12:05:32 GMT, Maurizio Cimadamore <mcimadamore at openjdk.org> wrote:
>> This PR contains the API and implementation changes for JEP-419 [1]. A more detailed description of such changes, to avoid repetitions during the review process, is included as a separate comment.
>>
>> [1] - https://openjdk.java.net/jeps/419
>
> Maurizio Cimadamore has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 17 commits:
>
> - Add cache for memory address var handles
> - Merge branch 'master' into JEP-419
> - Fix regression in VaList treatment on AArch64 (contributed by @nick-arm)
> - Merge branch 'master' into JEP-419
> - Fix copyright header in TestArrayCopy
> - Fix failing microbenchmarks. Contributed by @FrauBoes (thanks!)
> - * use `invokeWithArguments` to simplify new test
> - Add test for liveness check with high-aririty downcalls
> (make sure that if an exception occurs in a downcall because of liveness,
> ref count of other resources are left intact).
> - * Fix javadoc issue in VaList
> * Fix bug in concurrent logic for shared scope acquire
> - Address review comments
> - ... and 7 more: https://git.openjdk.java.net/jdk/compare/5bb1992b...9b519343
src/jdk.incubator.foreign/share/classes/jdk/internal/foreign/Utils.java line 111:
> 109: class VarHandleCache {
> 110: private static final Map<ValueLayout, VarHandle> handleMap = new ConcurrentHashMap<>();
> 111: private static final Map<ValueLayout, VarHandle> handleMapNoAlignCheck = new ConcurrentHashMap<>();
Something to consider later if this is an issue. Since the number of `ValueLayout` instances is fixed, carrier x order = 18, we can use stable arrays with ordinals on the instances.
-------------
PR: https://git.openjdk.java.net/jdk/pull/5907
More information about the build-dev
mailing list