RFR: 8355003: Implement Ahead-of-Time Method Profiling

Igor Veresov iveresov at openjdk.org
Sun Apr 27 00:23:45 UTC 2025


On Sat, 26 Apr 2025 21:30:25 GMT, Vladimir Kozlov <kvn at openjdk.org> wrote:

>> Improve warm-up time by making profile data from a previous run of an application instantly available, when the HotSpot Java Virtual Machine starts. Specifically, enhance the [AOT cache](https://openjdk.org/jeps/483) to store method execution profiles from training runs, reducing profiling delays in subsequent production runs.
>> 
>> More details in the JEP: https://bugs.openjdk.org/browse/JDK-8325147
>
> src/hotspot/share/oops/methodData.cpp line 1296:
> 
>> 1294: 
>> 1295: MethodData::MethodData() {
>> 1296:   assert(CDSConfig::is_dumping_static_archive() || UseSharedSpaces, "only for CDS");
> 
> 1. Should its code be guarded by `#if INCLUDE_CDS`?
> 2. Comment where/how it is used.
> 3. Is it used in all phases or only during TRAINING and ASSEMBLY?
> 4. Can you add query methods into `CDSConfig` which you can call here and in other places?:
> 
>  is_dumping_training_data()
>  is_using_training_data()

I think those are used for CDS serialization/deserialization, right, @iklam?

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

PR Review Comment: https://git.openjdk.org/jdk/pull/24886#discussion_r2061856884


More information about the hotspot-compiler-dev mailing list