RFR: 8348028: Unable to run gtests with CDS enabled

Calvin Cheung ccheung at openjdk.org
Tue Feb 25 20:51:54 UTC 2025


On Tue, 25 Feb 2025 09:19:52 GMT, David Holmes <dholmes at openjdk.org> wrote:

> This doesn't look right to me. What if we are in a client-only VM build, or a minimal-VM build?
> 
For minimal-VM build, libjvm.so is located at:
jdk/lib/minimal/libjvm.so

For zero-VM build, libjvm.so is located at:
jdk/lib/zero/libjvm.so

For client-only VM build, I think it should be located under the "client" directory, e.g. on Windows:
jdk/bin/client/jvm.dll

> I'm not even sure hotspot/libjvm.so is meant to be a filesystem path because it doesn't exist in the filesystem image. ??

The "hotspot" directory maybe a leftover from some old JDK releases?

More details: the `init_vm()` in gtestMain.cpp set the following property before creating a JVM:
-Dsun.java.launcher.is_altjvm=true
`CDSConfig::default_archive_path()` calls `os::jvm_path()` to locate the default CDS archive.

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

PR Comment: https://git.openjdk.org/jdk/pull/23758#issuecomment-2683251639


More information about the hotspot-runtime-dev mailing list