Top


定義場所(file name)

hotspot/src/share/vm/prims/jvmtiExport.cpp

説明(description)

// Unset current event collection in this thread and reset it with previous
// collector.

名前(function name)

void JvmtiEventCollector::unset_jvmti_thread_state() {

本体部(body)

  {- -------------------------------------------
  (1) カレントスレッドに対応する JvmtiThreadState 内から
      この JvmtiEventCollector (のサブクラスの) オブジェクトを除去する.

      * JvmtiVMObjectAllocEventCollector オブジェクトの場合:
        JvmtiThreadState::set_vm_object_alloc_event_collector() を呼び出して除去.
      * JvmtiDynamicCodeEventCollector オブジェクトの場合:
        JvmtiThreadState::set_dynamic_code_event_collector() を呼び出して除去.
      ---------------------------------------- -}

      JvmtiThreadState* state = JavaThread::current()->jvmti_thread_state();
      if (state != NULL) {
        // restore the previous event collector (if any)
        if (is_vm_object_alloc_event()) {
          if (state->get_vm_object_alloc_event_collector() == this) {
            state->set_vm_object_alloc_event_collector((JvmtiVMObjectAllocEventCollector *)_prev);
          } else {
            // this thread's jvmti state was created during the scope of
            // the event collector.
          }
        } else {
          if (is_dynamic_code_event()) {
            if (state->get_dynamic_code_event_collector() == this) {
              state->set_dynamic_code_event_collector((JvmtiDynamicCodeEventCollector *)_prev);
            } else {
              // this thread's jvmti state was created during the scope of
              // the event collector.
            }
          }
        }
      }
    }

This document is available under the GNU GENERAL PUBLIC LICENSE Version 2.