< prev index next >

src/hotspot/share/classfile/javaClasses.hpp

Print this page

 502   static ThreadPriority maxPriority(oop java_thread_group);
 503   // Daemon
 504   static bool is_daemon(oop java_thread_group);
 505 
 506   // Debugging
 507   friend class JavaClasses;
 508 };
 509 
 510 
 511 // Interface to java.lang.VirtualThread objects
 512 
 513 class java_lang_VirtualThread : AllStatic {
 514  private:
 515   static int static_vthread_scope_offset;
 516   static int _carrierThread_offset;
 517   static int _continuation_offset;
 518   static int _state_offset;
 519   JFR_ONLY(static int _jfr_epoch_offset;)
 520  public:
 521   enum {
 522     NEW          = 0,
 523     STARTED      = 1,
 524     RUNNABLE     = 2,
 525     RUNNING      = 3,
 526     PARKING      = 4,
 527     PARKED       = 5,
 528     PINNED       = 6,
 529     YIELDING     = 7,
 530     TERMINATED   = 99,
 531 
 532     // can be suspended from scheduling when unmounted
 533     SUSPENDED    = 1 << 8,
 534     RUNNABLE_SUSPENDED = (RUNNABLE | SUSPENDED),
 535     PARKED_SUSPENDED   = (PARKED | SUSPENDED)


 536   };
 537 
 538   static void compute_offsets();
 539   static void serialize_offsets(SerializeClosure* f) NOT_CDS_RETURN;
 540 
 541   // Testers
 542   static bool is_subclass(Klass* klass) {
 543     return klass->is_subclass_of(vmClasses::VirtualThread_klass());
 544   }
 545   static bool is_instance(oop obj);
 546 
 547   static oop vthread_scope();
 548   static oop carrier_thread(oop vthread);
 549   static oop continuation(oop vthread);
 550   static int state(oop vthread);
 551   static JavaThreadStatus map_state_to_thread_status(int state);
 552 };
 553 
 554 
 555 // Interface to java.lang.Throwable objects

 502   static ThreadPriority maxPriority(oop java_thread_group);
 503   // Daemon
 504   static bool is_daemon(oop java_thread_group);
 505 
 506   // Debugging
 507   friend class JavaClasses;
 508 };
 509 
 510 
 511 // Interface to java.lang.VirtualThread objects
 512 
 513 class java_lang_VirtualThread : AllStatic {
 514  private:
 515   static int static_vthread_scope_offset;
 516   static int _carrierThread_offset;
 517   static int _continuation_offset;
 518   static int _state_offset;
 519   JFR_ONLY(static int _jfr_epoch_offset;)
 520  public:
 521   enum {
 522     NEW           = 0,
 523     STARTED       = 1,
 524     RUNNING       = 2,
 525     PARKING       = 3,
 526     PARKED        = 4,
 527     PINNED        = 5,
 528     TIMED_PARKING = 6,
 529     TIMED_PARKED  = 7,
 530     TIMED_PINNED  = 8,
 531     UNPARKED      = 9,
 532     YIELDING      = 10,
 533     YIELDED       = 11,
 534     TERMINATED    = 99,
 535 
 536     // additional state bits
 537     SUSPENDED    = 1 << 8,   // suspended when unmounted
 538   };
 539 
 540   static void compute_offsets();
 541   static void serialize_offsets(SerializeClosure* f) NOT_CDS_RETURN;
 542 
 543   // Testers
 544   static bool is_subclass(Klass* klass) {
 545     return klass->is_subclass_of(vmClasses::VirtualThread_klass());
 546   }
 547   static bool is_instance(oop obj);
 548 
 549   static oop vthread_scope();
 550   static oop carrier_thread(oop vthread);
 551   static oop continuation(oop vthread);
 552   static int state(oop vthread);
 553   static JavaThreadStatus map_state_to_thread_status(int state);
 554 };
 555 
 556 
 557 // Interface to java.lang.Throwable objects
< prev index next >