hotspot/src/share/vm/compiler/compileTask.cpp
changeset 38218 f5ba1dea04eb
parent 38133 78b95467b9f1
child 40084 98825f02aa8d
equal deleted inserted replaced
38217:7ecc47b7df3d 38218:f5ba1dea04eb
    80                              const methodHandle& method,
    80                              const methodHandle& method,
    81                              int osr_bci,
    81                              int osr_bci,
    82                              int comp_level,
    82                              int comp_level,
    83                              const methodHandle& hot_method,
    83                              const methodHandle& hot_method,
    84                              int hot_count,
    84                              int hot_count,
    85                              const char* comment,
    85                              CompileTask::CompileReason compile_reason,
    86                              bool is_blocking) {
    86                              bool is_blocking) {
    87   assert(!_lock->is_locked(), "bad locking");
    87   assert(!_lock->is_locked(), "bad locking");
    88 
    88 
    89   _compile_id = compile_id;
    89   _compile_id = compile_id;
    90   _method = method();
    90   _method = method();
   102 
   102 
   103   _hot_method = NULL;
   103   _hot_method = NULL;
   104   _hot_method_holder = NULL;
   104   _hot_method_holder = NULL;
   105   _hot_count = hot_count;
   105   _hot_count = hot_count;
   106   _time_queued = 0;  // tidy
   106   _time_queued = 0;  // tidy
   107   _comment = comment;
   107   _compile_reason = compile_reason;
   108   _failure_reason = NULL;
   108   _failure_reason = NULL;
   109 
   109 
   110   if (LogCompilation) {
   110   if (LogCompilation) {
   111     _time_queued = os::elapsed_counter();
   111     _time_queued = os::elapsed_counter();
   112     if (hot_method.not_null()) {
   112     if (hot_method.not_null()) {
   307   ttyLocker ttyl;
   307   ttyLocker ttyl;
   308   ResourceMark rm(thread);
   308   ResourceMark rm(thread);
   309 
   309 
   310   xtty->begin_elem("task_queued");
   310   xtty->begin_elem("task_queued");
   311   log_task(xtty);
   311   log_task(xtty);
   312   if (_comment != NULL) {
   312   assert(_compile_reason > CompileTask::Reason_None && _compile_reason < CompileTask::Reason_Count, "Valid values");
   313     xtty->print(" comment='%s'", _comment);
   313   xtty->print(" comment='%s'", reason_name(_compile_reason));
   314   }
   314 
   315   if (_hot_method != NULL) {
   315   if (_hot_method != NULL) {
   316     methodHandle hot(thread, _hot_method);
   316     methodHandle hot(thread, _hot_method);
   317     methodHandle method(thread, _method);
   317     methodHandle method(thread, _method);
   318     if (hot() != method()) {
   318     if (hot() != method()) {
   319       xtty->method(hot);
   319       xtty->method(hot);
   438   if (msg != NULL) {
   438   if (msg != NULL) {
   439     st->print("   %s", msg);
   439     st->print("   %s", msg);
   440   }
   440   }
   441   st->cr();
   441   st->cr();
   442 }
   442 }
       
   443 
       
   444