changeset 23295:c3ebefa1c743

Backed out changeset 5d04cfbd1945
author Doug Simon <doug.simon@oracle.com>
date Fri, 29 Jan 2016 22:55:42 +0100
parents 5d04cfbd1945
children f41d4011035d
files src/share/vm/compiler/compileBroker.cpp src/share/vm/compiler/compileBroker.hpp src/share/vm/runtime/thread.cpp
diffstat 3 files changed, 4 insertions(+), 19 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/vm/compiler/compileBroker.cpp	Fri Jan 29 21:52:36 2016 +0100
+++ b/src/share/vm/compiler/compileBroker.cpp	Fri Jan 29 22:55:42 2016 +0100
@@ -51,7 +51,6 @@
 #endif
 #if INCLUDE_JVMCI
 #include "jvmci/jvmciCompiler.hpp"
-#include "jvmci/jvmciJavaClasses.hpp"
 #ifdef COMPILERJVMCI
 #include "jvmci/jvmciRuntime.hpp"
 #include "runtime/vframe.hpp"
@@ -931,7 +930,7 @@
 // CompileBroker::compilation_init
 //
 // Initialize the Compilation object
-void CompileBroker::compilation_init(TRAPS) {
+void CompileBroker::compilation_init() {
   _last_method_compiled[0] = '\0';
 
   // No need to initialize compilation system if we do not use it.
@@ -960,16 +959,6 @@
   } else {
     c1_count = JVMCIHostThreads;
   }
-  if (!UseInterpreter || !BackgroundCompilation) {
-    // Force initialization of JVMCI compiler otherwise JVMCI
-    // compilations will not block until JVMCI is initialized
-    ResourceMark rm;
-    TempNewSymbol getCompiler = SymbolTable::new_symbol("getCompiler", CHECK);
-    TempNewSymbol sig = SymbolTable::new_symbol("()Ljdk/vm/ci/runtime/JVMCICompiler;", CHECK);
-    Handle jvmciRuntime = JVMCIRuntime::get_HotSpotJVMCIRuntime(CHECK);
-    JavaValue result(T_OBJECT);
-    JavaCalls::call_virtual(&result, jvmciRuntime, HotSpotJVMCIRuntime::klass(), getCompiler, sig, CHECK);
-  }
 #endif // COMPILERJVMCI
 
 #ifdef COMPILER1
@@ -1744,8 +1733,7 @@
 bool CompileBroker::wait_for_jvmci_completion(CompileTask* task, JavaThread* thread) {
   MutexLocker waiter(task->lock(), thread);
   int consecutively_blocked = 0;
-  while (!task->is_complete() && !is_compilation_disabled_forever() &&
-         task->lock()->wait(!Mutex::_no_safepoint_check_flag, BLOCKING_JVMCI_COMPILATION_WAIT_TIMESLICE)) {
+  while (task->lock()->wait(!Mutex::_no_safepoint_check_flag, BLOCKING_JVMCI_COMPILATION_WAIT_TIMESLICE)) {
     CompilerThread* jvmci_compiler_thread = task->jvmci_compiler_thread();
     if (jvmci_compiler_thread != NULL) {
       JavaThreadState state;
--- a/src/share/vm/compiler/compileBroker.hpp	Fri Jan 29 21:52:36 2016 +0100
+++ b/src/share/vm/compiler/compileBroker.hpp	Fri Jan 29 22:55:42 2016 +0100
@@ -415,7 +415,7 @@
     CompileQueue *q = compile_queue(comp_level);
     return q != NULL ? q->size() : 0;
   }
-  static void compilation_init(TRAPS);
+  static void compilation_init();
   static void init_compiler_thread_log();
   static nmethod* compile_method(methodHandle method,
                                  int osr_bci,
--- a/src/share/vm/runtime/thread.cpp	Fri Jan 29 21:52:36 2016 +0100
+++ b/src/share/vm/runtime/thread.cpp	Fri Jan 29 22:55:42 2016 +0100
@@ -3714,10 +3714,7 @@
 
   // initialize compiler(s)
 #if defined(COMPILER1) || defined(COMPILER2) || defined(SHARK) || defined(COMPILERJVMCI)
-  CompileBroker::compilation_init(THREAD);
-  if (HAS_PENDING_EXCEPTION) {
-    vm_exit_during_initialization(Handle(THREAD, PENDING_EXCEPTION));
-  }
+  CompileBroker::compilation_init();
 #endif
 
   if (EnableInvokeDynamic) {