Description
When bootstrapping switches we currently add a call to Objects.checkIndex by adding a filterArgument to the method handle, then explicitCast to adapt the code to the right type. These operations means a not insignificant number of LF and species classes are needed to be spun up when bootstrapping even a relatively simple runtime-bootstrapped switch.
By folding the checkIndex code and generating the method with precise arguments from the start we can avoid a few MH transforms and associated class spinning, while retaining parity on throughput metrics.
By folding the checkIndex code and generating the method with precise arguments from the start we can avoid a few MH transforms and associated class spinning, while retaining parity on throughput metrics.
Attachments
Issue Links
- relates to
-
JDK-8333605 Unreachable Code in SwitchBootstraps#enumSwitch
-
- Closed
-