hotspot/src/share/vm/memory/genCollectedHeap.hpp
changeset 25492 d27050bdfb04
parent 25491 70fb742e40aa
child 27249 698a2dc8e83a
equal deleted inserted replaced
25491:70fb742e40aa 25492:d27050bdfb04
    76 
    76 
    77   // In support of ExplicitGCInvokesConcurrent functionality
    77   // In support of ExplicitGCInvokesConcurrent functionality
    78   unsigned int _full_collections_completed;
    78   unsigned int _full_collections_completed;
    79 
    79 
    80   // Data structure for claiming the (potentially) parallel tasks in
    80   // Data structure for claiming the (potentially) parallel tasks in
    81   // (gen-specific) strong roots processing.
    81   // (gen-specific) roots processing.
    82   SubTasksDone* _gen_process_strong_tasks;
    82   SubTasksDone* _gen_process_roots_tasks;
    83   SubTasksDone* gen_process_strong_tasks() { return _gen_process_strong_tasks; }
    83   SubTasksDone* gen_process_roots_tasks() { return _gen_process_roots_tasks; }
    84 
    84 
    85   // In block contents verification, the number of header words to skip
    85   // In block contents verification, the number of header words to skip
    86   NOT_PRODUCT(static size_t _skip_header_HeapWords;)
    86   NOT_PRODUCT(static size_t _skip_header_HeapWords;)
    87 
    87 
    88 protected:
    88 protected:
   401   // explicitly mark reachable objects in younger generations, to avoid
   401   // explicitly mark reachable objects in younger generations, to avoid
   402   // excess storage retention.)
   402   // excess storage retention.)
   403   // The "so" argument determines which of the roots
   403   // The "so" argument determines which of the roots
   404   // the closure is applied to:
   404   // the closure is applied to:
   405   // "SO_None" does none;
   405   // "SO_None" does none;
   406   // "SO_AllClasses" applies the closure to all entries in the SystemDictionary;
   406  private:
   407   // "SO_SystemClasses" to all the "system" classes and loaders;
   407   void gen_process_roots(int level,
   408   // "SO_Strings" applies the closure to all entries in the StringTable.
   408                          bool younger_gens_as_roots,
   409   void gen_process_strong_roots(int level,
   409                          bool activate_scope,
   410                                 bool younger_gens_as_roots,
   410                          SharedHeap::ScanningOption so,
   411                                 // The remaining arguments are in an order
   411                          OopsInGenClosure* not_older_gens,
   412                                 // consistent with SharedHeap::process_strong_roots:
   412                          OopsInGenClosure* weak_roots,
   413                                 bool activate_scope,
   413                          OopsInGenClosure* older_gens,
   414                                 SharedHeap::ScanningOption so,
   414                          CLDClosure* cld_closure,
   415                                 OopsInGenClosure* not_older_gens,
   415                          CLDClosure* weak_cld_closure,
   416                                 OopsInGenClosure* older_gens,
   416                          CodeBlobClosure* code_closure);
   417                                 KlassClosure* klass_closure);
   417 
       
   418  public:
       
   419   static const bool StrongAndWeakRoots = false;
       
   420   static const bool StrongRootsOnly    = true;
       
   421 
       
   422   void gen_process_roots(int level,
       
   423                          bool younger_gens_as_roots,
       
   424                          bool activate_scope,
       
   425                          SharedHeap::ScanningOption so,
       
   426                          bool only_strong_roots,
       
   427                          OopsInGenClosure* not_older_gens,
       
   428                          OopsInGenClosure* older_gens,
       
   429                          CLDClosure* cld_closure);
   418 
   430 
   419   // Apply "root_closure" to all the weak roots of the system.
   431   // Apply "root_closure" to all the weak roots of the system.
   420   // These include JNI weak roots, string table,
   432   // These include JNI weak roots, string table,
   421   // and referents of reachable weak refs.
   433   // and referents of reachable weak refs.
   422   void gen_process_weak_roots(OopClosure* root_closure);
   434   void gen_process_weak_roots(OopClosure* root_closure);