RFR: 8358738: AOT cache created without graal jit should not be used with graal jit [v2]

Calvin Cheung ccheung at openjdk.org
Fri Jun 13 16:16:35 UTC 2025


On Fri, 13 Jun 2025 15:50:02 GMT, Vladimir Kozlov <kvn at openjdk.org> wrote:

>> src/hotspot/share/cds/filemap.cpp line 1952:
>> 
>>> 1950:                             (compiler_type == CompilerType::compiler_none);
>>> 1951:   if (!intepreter_is_used &&
>>> 1952:       jvmci_compiler_is_enabled != (archive_compiler_type == CompilerType::compiler_jvmci)) {
>> 
>> Does it mean we allow different compiler type during assembly phase and production phase? e.g. assembly phase using c1, production phase using c2?
>
> Yes. By default we have both with TieredCompilation. But we can switch it off (C2 only) or use TieredStopAtLevel=1 (C1 only). When they are mixed (one phase use only C1 and an other C2) we simple will not load AOT nmethods because corresponding compiler's runtime stubs will not be created so we can't use AOT nmethods referencing these stubs. But nothing in code generation or methods profiling prevents us from mixing them.
> 
> On other hand Graal creates different profiling data and additional nmethod's metadata. So we can't use such data with other JIT compilers.

Thanks for the explanations.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/25782#discussion_r2145446449


More information about the hotspot-runtime-dev mailing list