8199882: compiler/uncommontrap/TestDeoptOOM.java failed w/ fatal error: ExceptionMark constructor expects no pending exceptions

Pre-load AbstractOwnableSynchronizer class instead of lazy loading it.

Reviewed-by: sspitsyn, cjplummer, coleenp
This commit is contained in:
David Holmes 2018-06-05 19:58:20 -04:00
parent 6aa9e85a5e
commit ab275c586e
8 changed files with 16 additions and 75 deletions

View file

@ -204,13 +204,6 @@ void VM_Verify::doit() {
}
bool VM_PrintThreads::doit_prologue() {
// Make sure AbstractOwnableSynchronizer is loaded
JavaThread* jt = JavaThread::current();
java_util_concurrent_locks_AbstractOwnableSynchronizer::initialize(jt);
if (jt->has_pending_exception()) {
return false;
}
// Get Heap_lock if concurrent locks will be dumped
if (_print_concurrent_locks) {
Heap_lock->lock();
@ -248,19 +241,6 @@ VM_FindDeadlocks::~VM_FindDeadlocks() {
}
}
bool VM_FindDeadlocks::doit_prologue() {
if (_concurrent_locks) {
// Make sure AbstractOwnableSynchronizer is loaded
JavaThread* jt = JavaThread::current();
java_util_concurrent_locks_AbstractOwnableSynchronizer::initialize(jt);
if (jt->has_pending_exception()) {
return false;
}
}
return true;
}
void VM_FindDeadlocks::doit() {
// Update the hazard ptr in the originating thread to the current
// list of threads. This VM operation needs the current list of
@ -316,13 +296,6 @@ VM_ThreadDump::VM_ThreadDump(ThreadDumpResult* result,
}
bool VM_ThreadDump::doit_prologue() {
// Make sure AbstractOwnableSynchronizer is loaded
JavaThread* jt = JavaThread::current();
java_util_concurrent_locks_AbstractOwnableSynchronizer::initialize(jt);
if (jt->has_pending_exception()) {
return false;
}
if (_with_locked_synchronizers) {
// Acquire Heap_lock to dump concurrent locks
Heap_lock->lock();