< prev index next >

src/share/vm/gc_implementation/shenandoah/shenandoahCodeRoots.cpp

Print this page
rev 11423 : [backport] 8231197: Shenandoah: JVMTI heap walking cleanup crashes with NULL forwardee
Reviewed-by: zgu, rkennke

*** 25,34 **** --- 25,35 ---- #include "code/codeCache.hpp" #include "code/nmethod.hpp" #include "gc_implementation/shenandoah/shenandoahHeap.inline.hpp" #include "gc_implementation/shenandoah/shenandoahCodeRoots.hpp" #include "memory/resourceArea.hpp" + #include "runtime/vmThread.hpp" ShenandoahParallelCodeCacheIterator::ShenandoahParallelCodeCacheIterator() : _claimed_idx(0), _finished(false) { }
*** 297,309 **** assert(_nm->is_alive(), "only alive nmethods here"); assert(_oops_count > 0, "should have filtered nmethods without oops before"); ShenandoahHeap* heap = ShenandoahHeap::heap(); for (int c = 0; c < _oops_count; c++) { oop *loc = _oops[c]; ! assert(_nm->code_contains((address)loc) || _nm->oops_contains(loc), "nmethod should contain the oop*"); oop o = oopDesc::load_heap_oop(loc); ! shenandoah_assert_correct_except(loc, o, o == NULL || heap->is_full_gc_move_in_progress()); } } void ShenandoahNMethod::assert_same_oops(GrowableArray<oop*>* oops) { assert(_oops_count == oops->length(), "should have the same number of oop*"); --- 298,314 ---- assert(_nm->is_alive(), "only alive nmethods here"); assert(_oops_count > 0, "should have filtered nmethods without oops before"); ShenandoahHeap* heap = ShenandoahHeap::heap(); for (int c = 0; c < _oops_count; c++) { oop *loc = _oops[c]; ! assert(_nm->code_contains((address) loc) || _nm->oops_contains(loc), "nmethod should contain the oop*"); oop o = oopDesc::load_heap_oop(loc); ! shenandoah_assert_correct_except(loc, o, ! o == NULL || ! heap->is_full_gc_move_in_progress() || ! (VMThread::vm_operation() != NULL) && (VMThread::vm_operation()->type() == VM_Operation::VMOp_HeapWalkOperation) ! ); } } void ShenandoahNMethod::assert_same_oops(GrowableArray<oop*>* oops) { assert(_oops_count == oops->length(), "should have the same number of oop*");
< prev index next >