On Mon, 10 Jun 2024 07:56:03 GMT, Claes Redestad <redes...@openjdk.org> wrote:
>> Claes Redestad has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Adress review comments, add ConstantBootstraps#invoke to list of >> recognized type signatures > > Sure. If you can show how you'd do that I'd be happy to test it. Maybe there > are excess native linkers I'm not seeing from using `invokeExact`, but AFAICT > there are no linkers being spun when the type match is made exact via static > casts (which is what these exact matches in BMI achieves). So I remain a bit > confused about what we would be able to improve. > > Thanks for reviewing! @cl4es I'm talking about the linker being spun in `Invokers::invokeHandleForm`. When either `invoke` or `invokeExact` is called, the VM calls `MethodHandleNatives::linkMethod` and we eventually end up there. That code creates a new `LambdaForm` that has the type check (for `invokeExact`) and customization check, and then forwards the arguments to `invokeBasic`. The idea would be to call `invokeBasic` directly instead of `invokeExact` (similar to what we do in `VarHandleGuards`) ------------- PR Comment: https://git.openjdk.org/jdk/pull/19598#issuecomment-2157839857