src/hotspot/share/runtime/compilationPolicy.cpp
changeset 53194 c4a64760b1b0
parent 53193 184c51e48260
child 54015 cd701366fcf8
--- a/src/hotspot/share/runtime/compilationPolicy.cpp	Tue Jan 08 11:23:19 2019 +0100
+++ b/src/hotspot/share/runtime/compilationPolicy.cpp	Tue Jan 08 16:09:54 2019 +0100
@@ -40,7 +40,6 @@
 #include "runtime/stubRoutines.hpp"
 #include "runtime/thread.hpp"
 #include "runtime/tieredThresholdPolicy.hpp"
-#include "runtime/timer.hpp"
 #include "runtime/vframe.hpp"
 #include "runtime/vmOperations.hpp"
 #include "utilities/events.hpp"
@@ -54,7 +53,6 @@
 #endif
 
 CompilationPolicy* CompilationPolicy::_policy;
-elapsedTimer       CompilationPolicy::_accumulated_time;
 
 // Determine compilation policy based on command line argument
 void compilationPolicy_init() {
@@ -198,12 +196,6 @@
 }
 
 #ifndef PRODUCT
-void CompilationPolicy::print_time() {
-  tty->print_cr ("Accumulated compilationPolicy times:");
-  tty->print_cr ("---------------------------");
-  tty->print_cr ("  Total: %3.3f sec.", _accumulated_time.seconds());
-}
-
 void NonTieredCompPolicy::trace_osr_completion(nmethod* osr_nm) {
   if (TraceOnStackReplacement) {
     if (osr_nm == NULL) tty->print_cr("compilation failed");
@@ -537,11 +529,6 @@
     assert(fr.is_interpreted_frame(), "must be interpreted");
     assert(fr.interpreter_frame_method() == m(), "bad method");
 
-    if (TraceCompilationPolicy) {
-      tty->print("method invocation trigger: ");
-      m->print_short_name(tty);
-      tty->print(" ( interpreted " INTPTR_FORMAT ", size=%d ) ", p2i((address)m()), m->code_size());
-    }
     RegisterMap reg_map(thread, false);
     javaVFrame* triggerVF = thread->last_java_vframe(&reg_map);
     // triggerVF is the frame that triggered its counter
@@ -549,15 +536,11 @@
 
     if (first->top_method()->code() != NULL) {
       // called obsolete method/nmethod -- no need to recompile
-      if (TraceCompilationPolicy) tty->print_cr(" --> " INTPTR_FORMAT, p2i(first->top_method()->code()));
     } else {
-      if (TimeCompilationPolicy) accumulated_time()->start();
       GrowableArray<RFrame*>* stack = new GrowableArray<RFrame*>(50);
       stack->push(first);
       RFrame* top = findTopInlinableFrame(stack);
-      if (TimeCompilationPolicy) accumulated_time()->stop();
       assert(top != NULL, "findTopInlinableFrame returned null");
-      if (TraceCompilationPolicy) top->print();
       CompileBroker::compile_method(top->top_method(), InvocationEntryBci, comp_level,
                                     m, hot_count, CompileTask::Reason_InvocationCount, thread);
     }
@@ -592,12 +575,6 @@
     Method* m = current->top_method();
     Method* next_m = next->top_method();
 
-    if (TraceCompilationPolicy && Verbose) {
-      tty->print("[caller: ");
-      next_m->print_short_name(tty);
-      tty->print("] ");
-    }
-
     if( !Inline ) {           // Inlining turned off
       msg = "Inlining turned off";
       break;
@@ -673,19 +650,11 @@
       break;
     }
 
-    if (TraceCompilationPolicy && Verbose) {
-      tty->print("\n\t     check caller: ");
-      next_m->print_short_name(tty);
-      tty->print(" ( interpreted " INTPTR_FORMAT ", size=%d ) ", p2i((address)next_m), next_m->code_size());
-    }
-
     current = next;
   }
 
   assert( !current || !current->is_compiled(), "" );
 
-  if (TraceCompilationPolicy && msg) tty->print("(%s)\n", msg);
-
   return current;
 }