hotspot/src/share/vm/runtime/vmThread.cpp
changeset 5089 0cce506a0158
parent 4901 304ce755c6ee
child 5402 c51fd0c1d005
equal deleted inserted replaced
5088:a7a4e66595ec 5089:0cce506a0158
    23  */
    23  */
    24 
    24 
    25 # include "incls/_precompiled.incl"
    25 # include "incls/_precompiled.incl"
    26 # include "incls/_vmThread.cpp.incl"
    26 # include "incls/_vmThread.cpp.incl"
    27 
    27 
       
    28 HS_DTRACE_PROBE_DECL3(hotspot, vmops__request, char *, uintptr_t, int);
       
    29 HS_DTRACE_PROBE_DECL3(hotspot, vmops__begin, char *, uintptr_t, int);
       
    30 HS_DTRACE_PROBE_DECL3(hotspot, vmops__end, char *, uintptr_t, int);
       
    31 
    28 // Dummy VM operation to act as first element in our circular double-linked list
    32 // Dummy VM operation to act as first element in our circular double-linked list
    29 class VM_Dummy: public VM_Operation {
    33 class VM_Dummy: public VM_Operation {
    30   VMOp_Type type() const { return VMOp_Dummy; }
    34   VMOp_Type type() const { return VMOp_Dummy; }
    31   void  doit() {};
    35   void  doit() {};
    32 };
    36 };
   130 }
   134 }
   131 
   135 
   132 //-----------------------------------------------------------------
   136 //-----------------------------------------------------------------
   133 // High-level interface
   137 // High-level interface
   134 bool VMOperationQueue::add(VM_Operation *op) {
   138 bool VMOperationQueue::add(VM_Operation *op) {
       
   139 
       
   140   HS_DTRACE_PROBE3(hotspot, vmops__request, op->name(), strlen(op->name()),
       
   141                    op->evaluation_mode());
       
   142 
   135   // Encapsulates VM queue policy. Currently, that
   143   // Encapsulates VM queue policy. Currently, that
   136   // only involves putting them on the right list
   144   // only involves putting them on the right list
   137   if (op->evaluate_at_safepoint()) {
   145   if (op->evaluate_at_safepoint()) {
   138     queue_add_back(SafepointPriority, op);
   146     queue_add_back(SafepointPriority, op);
   139     return true;
   147     return true;
   323 void VMThread::evaluate_operation(VM_Operation* op) {
   331 void VMThread::evaluate_operation(VM_Operation* op) {
   324   ResourceMark rm;
   332   ResourceMark rm;
   325 
   333 
   326   {
   334   {
   327     PerfTraceTime vm_op_timer(perf_accumulated_vm_operation_time());
   335     PerfTraceTime vm_op_timer(perf_accumulated_vm_operation_time());
       
   336     HS_DTRACE_PROBE3(hotspot, vmops__begin, op->name(), strlen(op->name()),
       
   337                      op->evaluation_mode());
   328     op->evaluate();
   338     op->evaluate();
       
   339     HS_DTRACE_PROBE3(hotspot, vmops__end, op->name(), strlen(op->name()),
       
   340                      op->evaluation_mode());
   329   }
   341   }
   330 
   342 
   331   // Last access of info in _cur_vm_operation!
   343   // Last access of info in _cur_vm_operation!
   332   bool c_heap_allocated = op->is_cheap_allocated();
   344   bool c_heap_allocated = op->is_cheap_allocated();
   333 
   345