--- old/src/share/vm/jvmci/jvmciCompiler.cpp 2016-05-10 17:49:04.011757717 +0200 +++ new/src/share/vm/jvmci/jvmciCompiler.cpp 2016-05-10 17:49:03.780756927 +0200 @@ -39,6 +39,7 @@ JVMCICompiler::JVMCICompiler() : AbstractCompiler(jvmci) { _bootstrapping = false; + _bootstrap_compilation_request_seen = false; _methods_compiled = 0; assert(_instance == NULL, "only one instance allowed"); _instance = this; @@ -97,7 +98,7 @@ do { os::sleep(THREAD, 100, true); qsize = CompileBroker::queue_size(CompLevel_full_optimization); - } while (first_round && qsize == 0); + } while (!_bootstrap_compilation_request_seen && first_round && qsize == 0); first_round = false; if (PrintBootstrap) { while (z < (_methods_compiled / 100)) { @@ -111,6 +112,7 @@ tty->print_cr(" in " JLONG_FORMAT " ms (compiled %d methods)", os::javaTimeMillis() - start, _methods_compiled); } _bootstrapping = false; + JVMCIRuntime::bootstrapFinished(); } #define CHECK_ABORT THREAD); \ @@ -187,6 +189,9 @@ assert(false, "JVMCICompiler.compileMethod should always return non-null"); } } + if (_bootstrapping) { + _bootstrap_compilation_request_seen = true; + } } /**