Mercurial > hg > graal-compiler
comparison src/share/vm/gc_implementation/g1/g1OopClosures.hpp @ 14305:c685ef164975
8027746: Remove do_gen_barrier template parameter in G1ParCopyClosure
Summary: Remove the above mentioned template parameter and related unused code. Also remove some classes that are never used.
Reviewed-by: stefank, mgerdin, jwilhelm
author | tschatzl |
---|---|
date | Mon, 20 Jan 2014 11:47:53 +0100 |
parents | 190899198332 |
children | bec0ef450ead |
comparison
equal
deleted
inserted
replaced
14304:a2866d45e99e | 14305:c685ef164975 |
---|---|
36 class CMTask; | 36 class CMTask; |
37 class ReferenceProcessor; | 37 class ReferenceProcessor; |
38 | 38 |
39 // A class that scans oops in a given heap region (much as OopsInGenClosure | 39 // A class that scans oops in a given heap region (much as OopsInGenClosure |
40 // scans oops in a generation.) | 40 // scans oops in a generation.) |
41 class OopsInHeapRegionClosure: public OopsInGenClosure { | 41 class OopsInHeapRegionClosure: public ExtendedOopClosure { |
42 protected: | 42 protected: |
43 HeapRegion* _from; | 43 HeapRegion* _from; |
44 public: | 44 public: |
45 void set_region(HeapRegion* from) { _from = from; } | 45 void set_region(HeapRegion* from) { _from = from; } |
46 }; | 46 }; |
129 | 129 |
130 void set_scanned_klass(Klass* k) { _scanned_klass = k; } | 130 void set_scanned_klass(Klass* k) { _scanned_klass = k; } |
131 template <class T> void do_klass_barrier(T* p, oop new_obj); | 131 template <class T> void do_klass_barrier(T* p, oop new_obj); |
132 }; | 132 }; |
133 | 133 |
134 template <bool do_gen_barrier, G1Barrier barrier, bool do_mark_object> | 134 template <G1Barrier barrier, bool do_mark_object> |
135 class G1ParCopyClosure : public G1ParCopyHelper { | 135 class G1ParCopyClosure : public G1ParCopyHelper { |
136 G1ParScanClosure _scanner; | 136 G1ParScanClosure _scanner; |
137 template <class T> void do_oop_work(T* p); | 137 template <class T> void do_oop_work(T* p); |
138 | 138 |
139 protected: | 139 protected: |
164 } | 164 } |
165 virtual void do_oop(oop* p) { do_oop_nv(p); } | 165 virtual void do_oop(oop* p) { do_oop_nv(p); } |
166 virtual void do_oop(narrowOop* p) { do_oop_nv(p); } | 166 virtual void do_oop(narrowOop* p) { do_oop_nv(p); } |
167 }; | 167 }; |
168 | 168 |
169 typedef G1ParCopyClosure<false, G1BarrierNone, false> G1ParScanExtRootClosure; | 169 typedef G1ParCopyClosure<G1BarrierNone, false> G1ParScanExtRootClosure; |
170 typedef G1ParCopyClosure<false, G1BarrierKlass, false> G1ParScanMetadataClosure; | 170 typedef G1ParCopyClosure<G1BarrierKlass, false> G1ParScanMetadataClosure; |
171 | 171 |
172 | 172 |
173 typedef G1ParCopyClosure<false, G1BarrierNone, true> G1ParScanAndMarkExtRootClosure; | 173 typedef G1ParCopyClosure<G1BarrierNone, true> G1ParScanAndMarkExtRootClosure; |
174 typedef G1ParCopyClosure<true, G1BarrierNone, true> G1ParScanAndMarkClosure; | 174 typedef G1ParCopyClosure<G1BarrierKlass, true> G1ParScanAndMarkMetadataClosure; |
175 typedef G1ParCopyClosure<false, G1BarrierKlass, true> G1ParScanAndMarkMetadataClosure; | |
176 | |
177 // The following closure types are no longer used but are retained | |
178 // for historical reasons: | |
179 // typedef G1ParCopyClosure<false, G1BarrierRS, false> G1ParScanHeapRSClosure; | |
180 // typedef G1ParCopyClosure<false, G1BarrierRS, true> G1ParScanAndMarkHeapRSClosure; | |
181 | 175 |
182 // The following closure type is defined in g1_specialized_oop_closures.hpp: | 176 // The following closure type is defined in g1_specialized_oop_closures.hpp: |
183 // | 177 // |
184 // typedef G1ParCopyClosure<false, G1BarrierEvac, false> G1ParScanHeapEvacClosure; | 178 // typedef G1ParCopyClosure<G1BarrierEvac, false> G1ParScanHeapEvacClosure; |
185 | 179 |
186 // We use a separate closure to handle references during evacuation | 180 // We use a separate closure to handle references during evacuation |
187 // failure processing. | 181 // failure processing. |
188 // We could have used another instance of G1ParScanHeapEvacClosure | 182 // We could have used another instance of G1ParScanHeapEvacClosure |
189 // (since that closure no longer assumes that the references it | 183 // (since that closure no longer assumes that the references it |
190 // handles point into the collection set). | 184 // handles point into the collection set). |
191 | 185 |
192 typedef G1ParCopyClosure<false, G1BarrierEvac, false> G1ParScanHeapEvacFailureClosure; | 186 typedef G1ParCopyClosure<G1BarrierEvac, false> G1ParScanHeapEvacFailureClosure; |
193 | 187 |
194 class FilterIntoCSClosure: public ExtendedOopClosure { | 188 class FilterIntoCSClosure: public ExtendedOopClosure { |
195 G1CollectedHeap* _g1; | 189 G1CollectedHeap* _g1; |
196 OopClosure* _oc; | 190 OopClosure* _oc; |
197 DirtyCardToOopClosure* _dcto_cl; | 191 DirtyCardToOopClosure* _dcto_cl; |