219 // Allocation is from the top of the reserved heap downward. |
219 // Allocation is from the top of the reserved heap downward. |
220 bool alloc_new_region(); |
220 bool alloc_new_region(); |
221 |
221 |
222 public: |
222 public: |
223 G1ArchiveAllocator(G1CollectedHeap* g1h, bool open) : |
223 G1ArchiveAllocator(G1CollectedHeap* g1h, bool open) : |
|
224 _open(open), |
224 _g1h(g1h), |
225 _g1h(g1h), |
225 _allocation_region(NULL), |
226 _allocation_region(NULL), |
226 _allocated_regions((ResourceObj::set_allocation_type((address) &_allocated_regions, |
227 _allocated_regions((ResourceObj::set_allocation_type((address) &_allocated_regions, |
227 ResourceObj::C_HEAP), |
228 ResourceObj::C_HEAP), |
228 2), true /* C_Heap */), |
229 2), true /* C_Heap */), |
229 _summary_bytes_used(0), |
230 _summary_bytes_used(0), |
230 _bottom(NULL), |
231 _bottom(NULL), |
231 _top(NULL), |
232 _top(NULL), |
232 _max(NULL), |
233 _max(NULL) { } |
233 _open(open) { } |
|
234 |
234 |
235 virtual ~G1ArchiveAllocator() { |
235 virtual ~G1ArchiveAllocator() { |
236 assert(_allocation_region == NULL, "_allocation_region not NULL"); |
236 assert(_allocation_region == NULL, "_allocation_region not NULL"); |
237 } |
237 } |
238 |
238 |