< prev index next >

src/hotspot/share/services/threadService.hpp

Print this page

614     JavaThreadStatusChanger(java_thread, JavaThreadStatus::SLEEPING) {
615     if (is_alive()) {
616       _stat = java_thread->get_thread_stat();
617       _active = ThreadService::is_thread_monitoring_contention();
618       _stat->thread_sleep();
619       if (_active) {
620         _stat->thread_sleep_begin();
621       }
622     } else {
623       _active = false;
624     }
625   }
626 
627   ~JavaThreadSleepState() {
628     if (_active) {
629       _stat->thread_sleep_end();
630     }
631   }
632 };
633 







634 #endif // SHARE_SERVICES_THREADSERVICE_HPP

614     JavaThreadStatusChanger(java_thread, JavaThreadStatus::SLEEPING) {
615     if (is_alive()) {
616       _stat = java_thread->get_thread_stat();
617       _active = ThreadService::is_thread_monitoring_contention();
618       _stat->thread_sleep();
619       if (_active) {
620         _stat->thread_sleep_begin();
621       }
622     } else {
623       _active = false;
624     }
625   }
626 
627   ~JavaThreadSleepState() {
628     if (_active) {
629       _stat->thread_sleep_end();
630     }
631   }
632 };
633 
634 
635 // jdk.internal.vm.ThreadSnapshot support
636 class ThreadSnapshotFactory: AllStatic {
637 public:
638   JVMTI_ONLY(static oop get_thread_snapshot(jobject jthread, TRAPS);)
639 };
640 
641 #endif // SHARE_SERVICES_THREADSERVICE_HPP
< prev index next >