RFR: 8242440: use separate, destroyable JavaVM instances per libgraal compiler thread [v3]

Vladimir Kozlov kvn at openjdk.java.net
Thu Apr 21 16:32:37 UTC 2022


On Thu, 21 Apr 2022 07:24:11 GMT, Doug Simon <dnsimon at openjdk.org> wrote:

>> src/hotspot/share/jvmci/jvmciCompiler.cpp line 172:
>> 
>>> 170:     // Don't detach JVMCI compiler threads from their JVMCI
>>> 171:     // runtime during the VM startup grace period
>>> 172:     if (runtime != nullptr && delay > 0 && tty->time_stamp().milliseconds() > DEFAULT_COMPILER_IDLE_DELAY) {
>> 
>> Can it be more coordinated by some status instead of time? Time depends on machine you run and does not guarantee right case. I could be done in separate changes.
>
> This check exists only to avoid adding extra overhead of creating and destroying libgraal runtimes during early VM execution for very short lived apps (i.e. less than 1000 ms). After that, normal libgraal runtime management should not be a problem. In combination with [lazy allocation of compiler threads](https://bugs.openjdk.java.net/browse/JDK-8198756), it's very rare in practice for a compiler thread to want to shutdown anyway during the first 1000 ms of VM execution.

Thank you for explanation.

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

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


More information about the hotspot-dev mailing list