RFR: 8348322: AOT cache creation crashes with "All cached hidden classes must be aot-linkable" when AOTInvokeDynamicLinking is disabled [v2]

Calvin Cheung ccheung at openjdk.org
Fri Feb 28 23:04:38 UTC 2025


On Fri, 28 Feb 2025 18:46:27 GMT, Matias Saavedra Silva <matsaave at openjdk.org> wrote:

> Looks good overall but I had some comments. Are there any remaining uses of `is_dumping_invokedynamic()`? I see several cases were replaced and I'm wondering if it's even being used anymore.

Yes, it is still being used in several places.

> src/hotspot/share/cds/cdsConfig.cpp line 618:
> 
>> 616: // Archived MethodHandles are required for higher-level optimizations such as AOT resolution of invokedynamic
>> 617: // and dynamic proxies.
>> 618: bool CDSConfig::is_dumping_method_handles() {
> 
> This looks like it does the same check as `is_initing_classes_at_dump_time() ` and is very similar to `is_dumping_invokedynamic()`. Maybe you can combine these methods to avoid duplicate code?

I removed the `CDSConfig::is_initing_classes_at_dump_time()` since the conditions are the same as `CDSConfig::is_dumping_method_handles()`. All the calls to `CDSConfig::is_initing_classes_at_dump_time()` have been updated accordingly.

-------------

PR Comment: https://git.openjdk.org/jdk/pull/23546#issuecomment-2691685916
PR Review Comment: https://git.openjdk.org/jdk/pull/23546#discussion_r1976098169


More information about the hotspot-runtime-dev mailing list