src/share/vm/runtime/thread.hpp
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File 8004128_2 Sdiff src/share/vm/runtime

src/share/vm/runtime/thread.hpp

Print this page




1399     }
1400   }
1401 
1402  private:
1403   void set_entry_point(ThreadFunction entry_point) { _entry_point = entry_point; }
1404 
1405  public:
1406 
1407   // Frame iteration; calls the function f for all frames on the stack
1408   void frames_do(void f(frame*, const RegisterMap*));
1409 
1410   // Memory operations
1411   void oops_do(OopClosure* f, CLDClosure* cld_f, CodeBlobClosure* cf);
1412 
1413   // Sweeper operations
1414   void nmethods_do(CodeBlobClosure* cf);
1415 
1416   // RedefineClasses Support
1417   void metadata_do(void f(Metadata*));
1418 
1419   // Memory management operations
1420   void gc_epilogue();
1421   void gc_prologue();
1422 
1423   // Misc. operations
1424   char* name() const { return (char*)get_thread_name(); }
1425   void print_on(outputStream* st) const;
1426   void print_value();
1427   void print_thread_state_on(outputStream* ) const      PRODUCT_RETURN;
1428   void print_thread_state() const                       PRODUCT_RETURN;
1429   void print_on_error(outputStream* st, char* buf, int buflen) const;
1430   void verify();
1431   const char* get_thread_name() const;
1432 private:
1433   // factor out low-level mechanics for use in both normal and error cases
1434   const char* get_thread_name_string(char* buf = NULL, int buflen = 0) const;
1435 public:
1436   const char* get_threadgroup_name() const;
1437   const char* get_parent_name() const;
1438 
1439   // Accessing frames
1440   frame last_frame() {
1441     _anchor.make_walkable(this);
1442     return pd_last_frame();


1882   // This version may be called by sequential or parallel code.
1883   static void possibly_parallel_oops_do(OopClosure* f, CLDClosure* cld_f, CodeBlobClosure* cf);
1884   // This creates a list of GCTasks, one per thread.
1885   static void create_thread_roots_tasks(GCTaskQueue* q);
1886   // This creates a list of GCTasks, one per thread, for marking objects.
1887   static void create_thread_roots_marking_tasks(GCTaskQueue* q);
1888 
1889   // Apply "f->do_oop" to roots in all threads that
1890   // are part of compiled frames
1891   static void compiled_frame_oops_do(OopClosure* f, CodeBlobClosure* cf);
1892 
1893   static void convert_hcode_pointers();
1894   static void restore_hcode_pointers();
1895 
1896   // Sweeper
1897   static void nmethods_do(CodeBlobClosure* cf);
1898 
1899   // RedefineClasses support
1900   static void metadata_do(void f(Metadata*));
1901 
1902   static void gc_epilogue();
1903   static void gc_prologue();
1904 #ifdef ASSERT
1905   static bool is_vm_complete() { return _vm_complete; }
1906 #endif
1907 
1908   // Verification
1909   static void verify();
1910   static void print_on(outputStream* st, bool print_stacks, bool internal_format, bool print_concurrent_locks);
1911   static void print(bool print_stacks, bool internal_format) {
1912     // this function is only used by debug.cpp
1913     print_on(tty, print_stacks, internal_format, false /* no concurrent lock printed */);
1914   }
1915   static void print_on_error(outputStream* st, Thread* current, char* buf, int buflen);
1916 
1917   // Get Java threads that are waiting to enter a monitor. If doLock
1918   // is true, then Threads_lock is grabbed as needed. Otherwise, the
1919   // VM needs to be at a safepoint.
1920   static GrowableArray<JavaThread*>* get_pending_threads(int count,
1921     address monitor, bool doLock);
1922 
1923   // Get owning Java thread from the monitor's owner field. If doLock




1399     }
1400   }
1401 
1402  private:
1403   void set_entry_point(ThreadFunction entry_point) { _entry_point = entry_point; }
1404 
1405  public:
1406 
1407   // Frame iteration; calls the function f for all frames on the stack
1408   void frames_do(void f(frame*, const RegisterMap*));
1409 
1410   // Memory operations
1411   void oops_do(OopClosure* f, CLDClosure* cld_f, CodeBlobClosure* cf);
1412 
1413   // Sweeper operations
1414   void nmethods_do(CodeBlobClosure* cf);
1415 
1416   // RedefineClasses Support
1417   void metadata_do(void f(Metadata*));
1418 




1419   // Misc. operations
1420   char* name() const { return (char*)get_thread_name(); }
1421   void print_on(outputStream* st) const;
1422   void print_value();
1423   void print_thread_state_on(outputStream* ) const      PRODUCT_RETURN;
1424   void print_thread_state() const                       PRODUCT_RETURN;
1425   void print_on_error(outputStream* st, char* buf, int buflen) const;
1426   void verify();
1427   const char* get_thread_name() const;
1428 private:
1429   // factor out low-level mechanics for use in both normal and error cases
1430   const char* get_thread_name_string(char* buf = NULL, int buflen = 0) const;
1431 public:
1432   const char* get_threadgroup_name() const;
1433   const char* get_parent_name() const;
1434 
1435   // Accessing frames
1436   frame last_frame() {
1437     _anchor.make_walkable(this);
1438     return pd_last_frame();


1878   // This version may be called by sequential or parallel code.
1879   static void possibly_parallel_oops_do(OopClosure* f, CLDClosure* cld_f, CodeBlobClosure* cf);
1880   // This creates a list of GCTasks, one per thread.
1881   static void create_thread_roots_tasks(GCTaskQueue* q);
1882   // This creates a list of GCTasks, one per thread, for marking objects.
1883   static void create_thread_roots_marking_tasks(GCTaskQueue* q);
1884 
1885   // Apply "f->do_oop" to roots in all threads that
1886   // are part of compiled frames
1887   static void compiled_frame_oops_do(OopClosure* f, CodeBlobClosure* cf);
1888 
1889   static void convert_hcode_pointers();
1890   static void restore_hcode_pointers();
1891 
1892   // Sweeper
1893   static void nmethods_do(CodeBlobClosure* cf);
1894 
1895   // RedefineClasses support
1896   static void metadata_do(void f(Metadata*));
1897 


1898 #ifdef ASSERT
1899   static bool is_vm_complete() { return _vm_complete; }
1900 #endif
1901 
1902   // Verification
1903   static void verify();
1904   static void print_on(outputStream* st, bool print_stacks, bool internal_format, bool print_concurrent_locks);
1905   static void print(bool print_stacks, bool internal_format) {
1906     // this function is only used by debug.cpp
1907     print_on(tty, print_stacks, internal_format, false /* no concurrent lock printed */);
1908   }
1909   static void print_on_error(outputStream* st, Thread* current, char* buf, int buflen);
1910 
1911   // Get Java threads that are waiting to enter a monitor. If doLock
1912   // is true, then Threads_lock is grabbed as needed. Otherwise, the
1913   // VM needs to be at a safepoint.
1914   static GrowableArray<JavaThread*>* get_pending_threads(int count,
1915     address monitor, bool doLock);
1916 
1917   // Get owning Java thread from the monitor's owner field. If doLock


src/share/vm/runtime/thread.hpp
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File