Mercurial > hg > truffle
diff src/share/vm/gc_implementation/g1/heapRegionSet.cpp @ 4072:8aae2050e83e
7092309: G1: introduce old region set
Summary: Keep track of all the old regions in the heap with a heap region set.
Reviewed-by: brutisso, johnc
author | tonyp |
---|---|
date | Mon, 07 Nov 2011 22:11:12 -0500 |
parents | 455328d90876 |
children | 720b6a76dd9d |
line wrap: on
line diff
--- a/src/share/vm/gc_implementation/g1/heapRegionSet.cpp Wed Nov 02 08:04:23 2011 +0100 +++ b/src/share/vm/gc_implementation/g1/heapRegionSet.cpp Mon Nov 07 22:11:12 2011 -0500 @@ -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 @@ _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);