Print this page
rev 6875 : 8056240: Investigate increased GC remark time after class unloading changes in CRM Fuse
Reviewed-by: mgerdin, coleenp, bdelsart

Split Split Close
Expand all
Collapse all
          --- old/src/share/vm/runtime/thread.hpp
          +++ new/src/share/vm/runtime/thread.hpp
↓ open down ↓ 34 lines elided ↑ open up ↑
  35   35  #include "runtime/jniHandles.hpp"
  36   36  #include "runtime/mutexLocker.hpp"
  37   37  #include "runtime/os.hpp"
  38   38  #include "runtime/osThread.hpp"
  39   39  #include "runtime/park.hpp"
  40   40  #include "runtime/safepoint.hpp"
  41   41  #include "runtime/stubRoutines.hpp"
  42   42  #include "runtime/threadLocalStorage.hpp"
  43   43  #include "runtime/thread_ext.hpp"
  44   44  #include "runtime/unhandledOops.hpp"
  45      -#include "utilities/macros.hpp"
  46      -
  47   45  #include "trace/traceBackend.hpp"
  48   46  #include "trace/traceMacros.hpp"
  49   47  #include "utilities/exceptions.hpp"
       48 +#include "utilities/macros.hpp"
  50   49  #include "utilities/top.hpp"
  51   50  #if INCLUDE_ALL_GCS
  52   51  #include "gc_implementation/g1/dirtyCardQueue.hpp"
  53   52  #include "gc_implementation/g1/satbQueue.hpp"
  54   53  #endif // INCLUDE_ALL_GCS
  55   54  #ifdef ZERO
  56   55  #ifdef TARGET_ARCH_zero
  57   56  # include "stack_zero.hpp"
  58   57  #endif
  59   58  #endif
↓ open down ↓ 16 lines elided ↑ open up ↑
  76   75  class CompilerCounters;
  77   76  class vframeArray;
  78   77  
  79   78  class DeoptResourceMark;
  80   79  class jvmtiDeferredLocalVariableSet;
  81   80  
  82   81  class GCTaskQueue;
  83   82  class ThreadClosure;
  84   83  class IdealGraphPrinter;
  85   84  
       85 +class Metadata;
       86 +template <class T, MEMFLAGS F> class ChunkedList;
       87 +typedef ChunkedList<Metadata*, mtInternal> MetadataOnStackBuffer;
       88 +
  86   89  DEBUG_ONLY(class ResourceMark;)
  87   90  
  88   91  class WorkerThread;
  89   92  
  90   93  // Class hierarchy
  91   94  // - Thread
  92   95  //   - NamedThread
  93   96  //     - VMThread
  94   97  //     - ConcurrentGCThread
  95   98  //     - WorkerThread
↓ open down ↓ 153 lines elided ↑ open up ↑
 249  252    friend class No_Alloc_Verifier;
 250  253    friend class No_Safepoint_Verifier;
 251  254    friend class Pause_No_Safepoint_Verifier;
 252  255    friend class ThreadLocalStorage;
 253  256    friend class GC_locker;
 254  257  
 255  258    ThreadLocalAllocBuffer _tlab;                 // Thread-local eden
 256  259    jlong _allocated_bytes;                       // Cumulative number of bytes allocated on
 257  260                                                  // the Java heap
 258  261  
      262 +  // Thread-local buffer used by MetadataOnStackMark.
      263 +  MetadataOnStackBuffer* _metadata_on_stack_buffer;
      264 +
 259  265    TRACE_DATA _trace_data;                       // Thread-local data for tracing
 260  266  
 261  267    ThreadExt _ext;
 262  268  
 263  269    int   _vm_operation_started_count;            // VM_Operation support
 264  270    int   _vm_operation_completed_count;          // VM_Operation support
 265  271  
 266  272    ObjectMonitor* _current_pending_monitor;      // ObjectMonitor this thread
 267  273                                                  // is waiting to lock
 268  274    bool _current_pending_monitor_is_from_java;   // locking is from Java code
↓ open down ↓ 241 lines elided ↑ open up ↑
 510  516    // Warning: the method can only be used on the running thread
 511  517    bool is_in_stack(address adr) const;
 512  518    // Check if address is in the usable part of the stack (excludes protected
 513  519    // guard pages)
 514  520    bool is_in_usable_stack(address adr) const;
 515  521  
 516  522    // Sets this thread as starting thread. Returns failure if thread
 517  523    // creation fails due to lack of memory, too many threads etc.
 518  524    bool set_as_starting_thread();
 519  525  
 520      - protected:
      526 +  void set_metadata_on_stack_buffer(MetadataOnStackBuffer* buffer) { _metadata_on_stack_buffer = buffer; }
      527 +  MetadataOnStackBuffer* metadata_on_stack_buffer() const          { return _metadata_on_stack_buffer; }
      528 +
      529 +protected:
 521  530    // OS data associated with the thread
 522  531    OSThread* _osthread;  // Platform-specific thread information
 523  532  
 524  533    // Thread local resource area for temporary allocation within the VM
 525  534    ResourceArea* _resource_area;
 526  535  
 527  536    DEBUG_ONLY(ResourceMark* _current_resource_mark;)
 528  537  
 529  538    // Thread local handle area for allocation of handles within the VM
 530  539    HandleArea* _handle_area;
↓ open down ↓ 1462 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX