equal
deleted
inserted
replaced
36 JVMCICompiler* JVMCICompiler::_instance = NULL; |
36 JVMCICompiler* JVMCICompiler::_instance = NULL; |
37 elapsedTimer JVMCICompiler::_codeInstallTimer; |
37 elapsedTimer JVMCICompiler::_codeInstallTimer; |
38 |
38 |
39 JVMCICompiler::JVMCICompiler() : AbstractCompiler(jvmci) { |
39 JVMCICompiler::JVMCICompiler() : AbstractCompiler(jvmci) { |
40 _bootstrapping = false; |
40 _bootstrapping = false; |
41 _methodsCompiled = 0; |
41 _methods_compiled = 0; |
42 assert(_instance == NULL, "only one instance allowed"); |
42 assert(_instance == NULL, "only one instance allowed"); |
43 _instance = this; |
43 _instance = this; |
44 } |
44 } |
45 |
45 |
46 // Initialization |
46 // Initialization |
97 os::sleep(THREAD, 100, true); |
97 os::sleep(THREAD, 100, true); |
98 qsize = CompileBroker::queue_size(CompLevel_full_optimization); |
98 qsize = CompileBroker::queue_size(CompLevel_full_optimization); |
99 } while (first_round && qsize == 0); |
99 } while (first_round && qsize == 0); |
100 first_round = false; |
100 first_round = false; |
101 if (PrintBootstrap) { |
101 if (PrintBootstrap) { |
102 while (z < (_methodsCompiled / 100)) { |
102 while (z < (_methods_compiled / 100)) { |
103 ++z; |
103 ++z; |
104 tty->print_raw("."); |
104 tty->print_raw("."); |
105 } |
105 } |
106 } |
106 } |
107 } while (qsize != 0); |
107 } while (qsize != 0); |
108 |
108 |
109 if (PrintBootstrap) { |
109 if (PrintBootstrap) { |
110 tty->print_cr(" in " JLONG_FORMAT " ms (compiled %d methods)", os::javaTimeMillis() - start, _methodsCompiled); |
110 tty->print_cr(" in " JLONG_FORMAT " ms (compiled %d methods)", os::javaTimeMillis() - start, _methods_compiled); |
111 } |
111 } |
112 _bootstrapping = false; |
112 _bootstrapping = false; |
113 } |
113 } |
114 |
114 |
115 #define CHECK_ABORT THREAD); \ |
115 #define CHECK_ABORT THREAD); \ |
174 } else { |
174 } else { |
175 if (env->task()->code() == NULL) { |
175 if (env->task()->code() == NULL) { |
176 env->set_failure("no nmethod produced", true); |
176 env->set_failure("no nmethod produced", true); |
177 } else { |
177 } else { |
178 env->task()->set_num_inlined_bytecodes(CompilationRequestResult::inlinedBytecodes(result_object)); |
178 env->task()->set_num_inlined_bytecodes(CompilationRequestResult::inlinedBytecodes(result_object)); |
179 _methodsCompiled++; |
179 Atomic::inc(&_methods_compiled); |
180 } |
180 } |
181 } |
181 } |
182 } else { |
182 } else { |
183 assert(false, "JVMCICompiler.compileMethod should always return non-null"); |
183 assert(false, "JVMCICompiler.compileMethod should always return non-null"); |
184 } |
184 } |