< prev index next >

src/share/vm/memory/sharedHeap.hpp

Print this page




  96 //  The active_workers is not reset to 0 after a parallel phase.  It's
  97 //  value may be used in later phases and in one instance at least
  98 //  (the parallel remark) it has to be used (the parallel remark depends
  99 //  on the partitioning done in the previous parallel scavenge).
 100 
 101 class SharedHeap : public CollectedHeap {
 102   friend class VMStructs;
 103 
 104   friend class VM_GC_Operation;
 105   friend class VM_CGC_Operation;
 106 
 107 protected:
 108   // If we're doing parallel GC, use this gang of threads.
 109   FlexibleWorkGang* _workers;
 110 
 111   // Full initialization is done in a concrete subtype's "initialize"
 112   // function.
 113   SharedHeap();
 114 
 115 public:
 116   void set_barrier_set(BarrierSet* bs);
 117 
 118   // Does operations required after initialization has been done.
 119   virtual void post_initialize();
 120 
 121   // Initialization of ("weak") reference processing support
 122   virtual void ref_processing_init();
 123 
 124   // Iteration functions.
 125   void oop_iterate(ExtendedOopClosure* cl) = 0;
 126 
 127   // Iterate over all spaces in use in the heap, in an undefined order.
 128   virtual void space_iterate(SpaceClosure* cl) = 0;
 129 
 130   // A SharedHeap will contain some number of spaces.  This finds the
 131   // space whose reserved area contains the given address, or else returns
 132   // NULL.
 133   virtual Space* space_containing(const void* addr) const = 0;
 134 
 135   bool no_gc_in_progress() { return !is_gc_active(); }
 136 
 137   // Note, the below comment needs to be updated to reflect the changes




  96 //  The active_workers is not reset to 0 after a parallel phase.  It's
  97 //  value may be used in later phases and in one instance at least
  98 //  (the parallel remark) it has to be used (the parallel remark depends
  99 //  on the partitioning done in the previous parallel scavenge).
 100 
 101 class SharedHeap : public CollectedHeap {
 102   friend class VMStructs;
 103 
 104   friend class VM_GC_Operation;
 105   friend class VM_CGC_Operation;
 106 
 107 protected:
 108   // If we're doing parallel GC, use this gang of threads.
 109   FlexibleWorkGang* _workers;
 110 
 111   // Full initialization is done in a concrete subtype's "initialize"
 112   // function.
 113   SharedHeap();
 114 
 115 public:


 116   // Does operations required after initialization has been done.
 117   virtual void post_initialize();
 118 
 119   // Initialization of ("weak") reference processing support
 120   virtual void ref_processing_init();
 121 
 122   // Iteration functions.
 123   void oop_iterate(ExtendedOopClosure* cl) = 0;
 124 
 125   // Iterate over all spaces in use in the heap, in an undefined order.
 126   virtual void space_iterate(SpaceClosure* cl) = 0;
 127 
 128   // A SharedHeap will contain some number of spaces.  This finds the
 129   // space whose reserved area contains the given address, or else returns
 130   // NULL.
 131   virtual Space* space_containing(const void* addr) const = 0;
 132 
 133   bool no_gc_in_progress() { return !is_gc_active(); }
 134 
 135   // Note, the below comment needs to be updated to reflect the changes


< prev index next >