hotspot/src/share/vm/gc_implementation/g1/g1MarkSweep.cpp
changeset 17112 e49af4ba7755
parent 17105 25b392a7740d
child 17114 b341b4c63384
equal deleted inserted replaced
17111:77f553b98e63 17112:e49af4ba7755
   168          "stack should be empty by now");
   168          "stack should be empty by now");
   169 
   169 
   170   if (VerifyDuringGC) {
   170   if (VerifyDuringGC) {
   171     HandleMark hm;  // handle scope
   171     HandleMark hm;  // handle scope
   172     COMPILER2_PRESENT(DerivedPointerTableDeactivate dpt_deact);
   172     COMPILER2_PRESENT(DerivedPointerTableDeactivate dpt_deact);
   173     gclog_or_tty->print(" VerifyDuringGC:(full)[Verifying ");
       
   174     Universe::heap()->prepare_for_verify();
   173     Universe::heap()->prepare_for_verify();
   175     // Note: we can verify only the heap here. When an object is
   174     // Note: we can verify only the heap here. When an object is
   176     // marked, the previous value of the mark word (including
   175     // marked, the previous value of the mark word (including
   177     // identity hash values, ages, etc) is preserved, and the mark
   176     // identity hash values, ages, etc) is preserved, and the mark
   178     // word is set to markOop::marked_value - effectively removing
   177     // word is set to markOop::marked_value - effectively removing
   180     // used when verifying the dictionaries and so removing them
   179     // used when verifying the dictionaries and so removing them
   181     // from the mark word can make verification of the dictionaries
   180     // from the mark word can make verification of the dictionaries
   182     // fail. At the end of the GC, the orginal mark word values
   181     // fail. At the end of the GC, the orginal mark word values
   183     // (including hash values) are restored to the appropriate
   182     // (including hash values) are restored to the appropriate
   184     // objects.
   183     // objects.
   185     Universe::heap()->verify(/* silent      */ false,
   184     if (!VerifySilently) {
   186                              /* option      */ VerifyOption_G1UseMarkWord);
   185       gclog_or_tty->print(" VerifyDuringGC:(full)[Verifying ");
   187 
   186     }
   188     G1CollectedHeap* g1h = G1CollectedHeap::heap();
   187     Universe::heap()->verify(VerifySilently, VerifyOption_G1UseMarkWord);
   189     gclog_or_tty->print_cr("]");
   188     if (!VerifySilently) {
       
   189       gclog_or_tty->print_cr("]");
       
   190     }
   190   }
   191   }
   191 }
   192 }
   192 
   193 
   193 class G1PrepareCompactClosure: public HeapRegionClosure {
   194 class G1PrepareCompactClosure: public HeapRegionClosure {
   194   G1CollectedHeap* _g1h;
   195   G1CollectedHeap* _g1h;