7092309: G1: introduce old region set

Keep track of all the old regions in the heap with a heap region set.

Reviewed-by: brutisso, johnc
This commit is contained in:
Antonios Printezis 2011-11-07 22:11:12 -05:00
parent b47310ebf8
commit 83958f54fb
9 changed files with 299 additions and 65 deletions

View file

@ -26,6 +26,7 @@
#include "gc_implementation/g1/heapRegionSet.inline.hpp"
size_t HeapRegionSetBase::_unrealistically_long_length = 0;
HRSPhase HeapRegionSetBase::_phase = HRSPhaseNone;
//////////////////// HeapRegionSetBase ////////////////////
@ -192,6 +193,17 @@ void HeapRegionSetBase::verify_end() {
_verify_in_progress = false;
}
void HeapRegionSetBase::clear_phase() {
assert(_phase != HRSPhaseNone, "pre-condition");
_phase = HRSPhaseNone;
}
void HeapRegionSetBase::set_phase(HRSPhase phase) {
assert(_phase == HRSPhaseNone, "pre-condition");
assert(phase != HRSPhaseNone, "pre-condition");
_phase = phase;
}
void HeapRegionSetBase::print_on(outputStream* out, bool print_contents) {
out->cr();
out->print_cr("Set: %s ("PTR_FORMAT")", name(), this);