< prev index next >

src/hotspot/share/gc/g1/g1OopClosures.hpp

Print this page
rev 52676 : imported patch AMGC-impl
rev 52677 : imported patch AMGC-tsch-rev1


  66                                   G1ParScanThreadState* pss) :
  67     G1ScanClosureBase(g1h, pss) { }
  68 
  69   template <class T> void do_oop_work(T* p);
  70   virtual void do_oop(narrowOop* p) { do_oop_work(p); }
  71   virtual void do_oop(oop* p)       { do_oop_work(p); }
  72 };
  73 
  74 // Used during the Scan RS phase to scan cards from the remembered set during garbage collection.
  75 class G1ScanObjsDuringScanRSClosure : public G1ScanClosureBase {
  76 public:
  77   G1ScanObjsDuringScanRSClosure(G1CollectedHeap* g1h,
  78                                 G1ParScanThreadState* par_scan_state):
  79     G1ScanClosureBase(g1h, par_scan_state) { }
  80 
  81   template <class T> void do_oop_work(T* p);
  82   virtual void do_oop(oop* p)          { do_oop_work(p); }
  83   virtual void do_oop(narrowOop* p)    { do_oop_work(p); }
  84 };
  85 










  86 
  87 // This closure is applied to the fields of the objects that have just been copied during evacuation.
  88 class G1ScanEvacuatedObjClosure : public G1ScanClosureBase {
  89   friend class G1ScanInYoungSetter;
  90 
  91   enum ScanningInYoungValues {
  92     False = 0,
  93     True,
  94     Uninitialized
  95   };
  96 
  97   ScanningInYoungValues _scanning_in_young;
  98 
  99 public:
 100   G1ScanEvacuatedObjClosure(G1CollectedHeap* g1h, G1ParScanThreadState* par_scan_state) :
 101     G1ScanClosureBase(g1h, par_scan_state), _scanning_in_young(Uninitialized) { }
 102 
 103   template <class T> void do_oop_work(T* p);
 104   virtual void do_oop(oop* p)          { do_oop_work(p); }
 105   virtual void do_oop(narrowOop* p)    { do_oop_work(p); }




  66                                   G1ParScanThreadState* pss) :
  67     G1ScanClosureBase(g1h, pss) { }
  68 
  69   template <class T> void do_oop_work(T* p);
  70   virtual void do_oop(narrowOop* p) { do_oop_work(p); }
  71   virtual void do_oop(oop* p)       { do_oop_work(p); }
  72 };
  73 
  74 // Used during the Scan RS phase to scan cards from the remembered set during garbage collection.
  75 class G1ScanObjsDuringScanRSClosure : public G1ScanClosureBase {
  76 public:
  77   G1ScanObjsDuringScanRSClosure(G1CollectedHeap* g1h,
  78                                 G1ParScanThreadState* par_scan_state):
  79     G1ScanClosureBase(g1h, par_scan_state) { }
  80 
  81   template <class T> void do_oop_work(T* p);
  82   virtual void do_oop(oop* p)          { do_oop_work(p); }
  83   virtual void do_oop(narrowOop* p)    { do_oop_work(p); }
  84 };
  85 
  86 // Used during Optional RS scanning to make sure we trim the queues in a timely manner.
  87 class G1ScanRSForOptionalClosure : public OopClosure {
  88   G1ScanObjsDuringScanRSClosure* _scan_cl;
  89 public:
  90   G1ScanRSForOptionalClosure(G1ScanObjsDuringScanRSClosure* cl) : _scan_cl(cl) { }
  91 
  92   template <class T> void do_oop_work(T* p);
  93   virtual void do_oop(oop* p)          { do_oop_work(p); }
  94   virtual void do_oop(narrowOop* p)    { do_oop_work(p); }
  95 };
  96 
  97 // This closure is applied to the fields of the objects that have just been copied during evacuation.
  98 class G1ScanEvacuatedObjClosure : public G1ScanClosureBase {
  99   friend class G1ScanInYoungSetter;
 100 
 101   enum ScanningInYoungValues {
 102     False = 0,
 103     True,
 104     Uninitialized
 105   };
 106 
 107   ScanningInYoungValues _scanning_in_young;
 108 
 109 public:
 110   G1ScanEvacuatedObjClosure(G1CollectedHeap* g1h, G1ParScanThreadState* par_scan_state) :
 111     G1ScanClosureBase(g1h, par_scan_state), _scanning_in_young(Uninitialized) { }
 112 
 113   template <class T> void do_oop_work(T* p);
 114   virtual void do_oop(oop* p)          { do_oop_work(p); }
 115   virtual void do_oop(narrowOop* p)    { do_oop_work(p); }


< prev index next >