On Fri, 11 Mar 2022 08:28:32 GMT, Ioi Lam <ik...@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.
>
>> 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).

Thanks for that clarification. Never mind then :)

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

PR: https://git.openjdk.java.net/jdk/pull/7748

Reply via email to