RFR: 8253495: CDS generates non-deterministic output [v2]
Ioi Lam
iklam at openjdk.java.net
Fri Mar 11 08:31:45 UTC 2022
On Fri, 11 Mar 2022 07:13:35 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:
> Is reproducibility also a topic for users calling -Xdump with custom JNI coding? Or maybe having the VM instrumented somehow? Since it seems such an easy fix, I would prevent attaching too. At least the user would get a clear error message.
It's impossible to execute arbitrary Java code when running "java -Xshare:dump", so this means there's no way to load a JNI library when creating a *static* CDS archive. The loading of JVMTI agents is also not supported. So this is not a case we need to handle.
During *dynamic* CDS dumps, arbitrary Java code can execute, but we don't have a requirement for the *dynamic* CDS archive to be deterministic (at least not for now).
-------------
PR: https://git.openjdk.java.net/jdk/pull/7748
More information about the build-dev
mailing list