While MethodType uses arrays to store parameter types (which is convenient to interact with the VM), MethodTypeDesc does not have to: arrays are subject to defensive copying, which can become a performance bottleneck in sensitive applications like bytecode generation. By passing immutable lists through parameterList() and MethodTypeDesc.of (see JDK-8306698), we can avoid defensive copying without more complicated syntax like checking parameterCount() for MethodType.
- is blocked by
-
JDK-8306698 Add overloads to MethodTypeDesc::of
-
- Resolved
-
- relates to
-
JDK-8309413 Improve the performance of MethodTypeDesc::descriptorString
-
- Resolved
-