RFR: 8293337: Store method handle intrinsics in AOT cache
Vladimir Kozlov
kvn at openjdk.org
Fri Sep 13 21:48:10 UTC 2024
On Thu, 12 Sep 2024 03:42:05 GMT, Ioi Lam <iklam at openjdk.org> wrote:
> This is the 5th PR for [JEP 483: Ahead-of-Time Class Loading & Linking](https://bugs.openjdk.org/browse/JDK-8315737).
>
> This PR is necessary to support [JDK-8293336: AOT-linking of invokedynamic for lambda expression and string concat](https://bugs.openjdk.org/browse/JDK-8293336), which needs to store Java heap objects that have native pointers to the C++ `Method` objects returned by `SystemDictionary::find_method_handle_intrinsic()`
>
> These `Method` objects are created within the JVM. They do not belong to any actual Java classes. We store all these `Method` objects into the AOT cache, so that they can be referenced by other artifacts in the AOT cache.
>
> ---
> See [here](https://bugs.openjdk.org/browse/JDK-8315737) for the sequence of dependent RFEs for implementing JEP 483.
src/hotspot/share/classfile/systemDictionary.hpp line 349:
> 347: // Second part of load_shared_class
> 348: static void load_shared_class_misc(InstanceKlass* ik, ClassLoaderData* loader_data) NOT_CDS_RETURN;
> 349: static void restore_archived_method_handle_intrinsics_impl(TRAPS);
Missing `NOT_CDS_RETURN` ?
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/20959#discussion_r1759549906
More information about the hotspot-dev
mailing list