RFR: 8294961: Convert java.base/java.lang.reflect.ProxyGenerator to use the Classfile API to generate proxy classes [v5]
Adam Sotona
asotona at openjdk.org
Wed Jan 3 11:52:52 UTC 2024
On Sun, 24 Dec 2023 04:07:07 GMT, Chen Liang <liach at openjdk.org> wrote:
>> This code is part of the **ClassFile API**’s internals, and so it doesn’t have access to `ProxyGenerator`’s cached `MethodTypeDesc`s, only the underlying `Utf8Entry`, so it’d need to be parsed.
>
> I see that now Class return type and Class array parameter types are directly converted to Strings instead of MTDs. I think that we should really run ProxyGenerator with JFR to profile and see the results (for instance, old ASM has a stackmap generation penalty due to parsing method descriptors on the fly compared to CF API, despite CF's slower overall performance due to allocations like Optional)
These changes are based on profiling of the benchmarks.
StackCounter was not used in any performance critical applications and profiling revealed some obvious bottlenecks.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/17121#discussion_r1440364580
More information about the core-libs-dev
mailing list