comparison src/share/vm/gc_implementation/g1/g1ParScanThreadState.inline.hpp @ 20504:6948da6d7c13

8052172: Evacuation failure handling in G1 does not evacuate all objects if -XX:-G1DeferredRSUpdate is set Summary: Remove -XX:-G1DeferredRSUpdate functionality as it is racy. During evacuation failure handling, threads where evacuation failure handling occurred may try to add remembered sets to regions which remembered sets are currently being scanned. The iterator to handle the remembered set scan does not support addition of entries during scan and so may skip valid references. Reviewed-by: iveresov, brutisso, mgerdin
author tschatzl
date Tue, 30 Sep 2014 09:44:36 +0200
parents a3953c777565
children f2e3f0e1f97d
comparison
equal deleted inserted replaced
20503:fa56205f142c 20504:6948da6d7c13
26 #define SHARE_VM_GC_IMPLEMENTATION_G1_G1PARSCANTHREADSTATE_INLINE_HPP 26 #define SHARE_VM_GC_IMPLEMENTATION_G1_G1PARSCANTHREADSTATE_INLINE_HPP
27 27
28 #include "gc_implementation/g1/g1ParScanThreadState.hpp" 28 #include "gc_implementation/g1/g1ParScanThreadState.hpp"
29 #include "gc_implementation/g1/g1RemSet.inline.hpp" 29 #include "gc_implementation/g1/g1RemSet.inline.hpp"
30 #include "oops/oop.inline.hpp" 30 #include "oops/oop.inline.hpp"
31
32 template <class T> inline void G1ParScanThreadState::immediate_rs_update(HeapRegion* from, T* p, int tid) {
33 if (!from->is_survivor()) {
34 _g1_rem->par_write_ref(from, p, tid);
35 }
36 }
37
38 template <class T> void G1ParScanThreadState::update_rs(HeapRegion* from, T* p, int tid) {
39 if (G1DeferredRSUpdate) {
40 deferred_rs_update(from, p, tid);
41 } else {
42 immediate_rs_update(from, p, tid);
43 }
44 }
45 31
46 template <class T> void G1ParScanThreadState::do_oop_evac(T* p, HeapRegion* from) { 32 template <class T> void G1ParScanThreadState::do_oop_evac(T* p, HeapRegion* from) {
47 assert(!oopDesc::is_null(oopDesc::load_decode_heap_oop(p)), 33 assert(!oopDesc::is_null(oopDesc::load_decode_heap_oop(p)),
48 "Reference should not be NULL here as such are never pushed to the task queue."); 34 "Reference should not be NULL here as such are never pushed to the task queue.");
49 oop obj = oopDesc::load_decode_heap_oop_not_null(p); 35 oop obj = oopDesc::load_decode_heap_oop_not_null(p);