On Mon, 16 May 2022 17:40:41 GMT, Jorn Vernee <[email protected]> wrote:
>> Hi,
>>
>> This PR brings over commits from the panama-foreign repo. These commits
>> mostly pertain to the switch to ASM and away from MethodHandle combinators
>> for the binding recipe specialization. But, there is one more commit which
>> adds freeing of downcall stubs, since those changes were mostly Java as well.
>>
>> Thanks,
>> Jorn
>>
>> Testing: `run-test-jdk_foreign` with `-Dgenerator.sample.factor=-1` on
>> Windows and Linux.
>
> Jorn Vernee has updated the pull request incrementally with one additional
> commit since the last revision:
>
> BootstrapMethodError -> ExceptionInInitializerError
src/java.base/share/classes/jdk/internal/foreign/abi/BindingSpecializer.java
line 157:
> 155: }
> 156:
> 157: static MethodHandle doSpecialize(MethodHandle leafHandle,
> CallingSequence callingSequence, ABIDescriptor abi) {
I think thise method should be split in to, one version for the upcall, one for
the downcall, i do not see the point of merging the two codes.
src/java.base/share/classes/jdk/internal/foreign/abi/BindingSpecializer.java
line 816:
> 814: return;
> 815: }
> 816: if (con instanceof Integer) {
those can use the instanceof + type pattern
-------------
PR: https://git.openjdk.java.net/jdk/pull/8685