Details
-
Bug
-
Resolution: Fixed
-
P4
-
8, openjdk8u352
-
b01
Backports
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8332281 | 8u431 | Ludvig Janiuk | P4 | Resolved | Fixed | b01 |
Description
Crashes in JvmtiExport::post_compiled_method_load were found in JDK8 of our production environment after one day when users started to receive the JVMTI COMPILED_METHOD_LOAD event.
This issue behaved similarly toJDK-8173361.
After debugging, ServiceThread::nmethods_do backported byJDK-8173361 is not called.
JavaThread::nmethods_do should be a virtual function just like 11u or later, otherwise, the following routine cannot call the correct nmethods_do for ServiceThread.
ALL_JAVA_THREADS(p) {
p->nmethods_do(cf);
}
Because this issue cannot be easily reproduced, manually adding some delay on purpose in ServiceThread::service_thread_entry to keep more events pending in JvmtiDeferredEventQueue could help reproduce this issue.
After the fix, various crashes were gone.
This issue behaved similarly to
After debugging, ServiceThread::nmethods_do backported by
JavaThread::nmethods_do should be a virtual function just like 11u or later, otherwise, the following routine cannot call the correct nmethods_do for ServiceThread.
ALL_JAVA_THREADS(p) {
p->nmethods_do(cf);
}
Because this issue cannot be easily reproduced, manually adding some delay on purpose in ServiceThread::service_thread_entry to keep more events pending in JvmtiDeferredEventQueue could help reproduce this issue.
After the fix, various crashes were gone.
Attachments
Issue Links
- backported by
-
JDK-8332281 [8u] ServiceThread::nmethods_do is not called to keep nmethods from being zombied while in the queue
- Resolved
- relates to
-
JDK-8173361 various crashes in JvmtiExport::post_compiled_method_load
- Resolved