equal
deleted
inserted
replaced
193 } |
193 } |
194 handle_non_cset_obj_common(state, p, obj); |
194 handle_non_cset_obj_common(state, p, obj); |
195 } |
195 } |
196 } |
196 } |
197 |
197 |
198 template <class T> |
198 void G1ParCopyHelper::do_cld_barrier(oop new_obj) { |
199 void G1ParCopyHelper::do_klass_barrier(T* p, oop new_obj) { |
|
200 if (_g1->heap_region_containing(new_obj)->is_young()) { |
199 if (_g1->heap_region_containing(new_obj)->is_young()) { |
201 _scanned_klass->record_modified_oops(); |
200 _scanned_cld->record_modified_oops(); |
202 } |
201 } |
203 } |
202 } |
204 |
203 |
205 void G1ParCopyHelper::mark_object(oop obj) { |
204 void G1ParCopyHelper::mark_object(oop obj) { |
206 assert(!_g1->heap_region_containing(obj)->in_collection_set(), "should not mark objects in the CSet"); |
205 assert(!_g1->heap_region_containing(obj)->in_collection_set(), "should not mark objects in the CSet"); |
247 // If the object is self-forwarded we don't need to explicitly |
246 // If the object is self-forwarded we don't need to explicitly |
248 // mark it, the evacuation failure protocol will do so. |
247 // mark it, the evacuation failure protocol will do so. |
249 mark_forwarded_object(obj, forwardee); |
248 mark_forwarded_object(obj, forwardee); |
250 } |
249 } |
251 |
250 |
252 if (barrier == G1BarrierKlass) { |
251 if (barrier == G1BarrierCLD) { |
253 do_klass_barrier(p, forwardee); |
252 do_cld_barrier(forwardee); |
254 } |
253 } |
255 } else { |
254 } else { |
256 if (state.is_humongous()) { |
255 if (state.is_humongous()) { |
257 _g1->set_humongous_is_live(obj); |
256 _g1->set_humongous_is_live(obj); |
258 } |
257 } |
265 if (do_mark_object == G1MarkFromRoot) { |
264 if (do_mark_object == G1MarkFromRoot) { |
266 mark_object(obj); |
265 mark_object(obj); |
267 } |
266 } |
268 } |
267 } |
269 } |
268 } |
270 |
|
271 #endif // SHARE_VM_GC_G1_G1OOPCLOSURES_INLINE_HPP |
269 #endif // SHARE_VM_GC_G1_G1OOPCLOSURES_INLINE_HPP |