mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-20 11:04:34 +02:00
8139867: Change how startsHumongous and continuesHumongous regions work in G1
Reviewed-by: tschatzl, tbenson
This commit is contained in:
parent
fbac3a147e
commit
6bda88594d
26 changed files with 192 additions and 463 deletions
|
@ -47,6 +47,18 @@ inline HeapRegion* HeapRegionManager::at(uint index) const {
|
|||
return hr;
|
||||
}
|
||||
|
||||
inline HeapRegion* HeapRegionManager::next_region_in_humongous(HeapRegion* hr) const {
|
||||
uint index = hr->hrm_index();
|
||||
assert(is_available(index), "pre-condition");
|
||||
assert(hr->is_humongous(), "next_region_in_humongous should only be called for a humongous region.");
|
||||
index++;
|
||||
if (index < max_length() && is_available(index) && at(index)->is_continues_humongous()) {
|
||||
return at(index);
|
||||
} else {
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
|
||||
inline void HeapRegionManager::insert_into_free_list(HeapRegion* hr) {
|
||||
_free_list.add_ordered(hr);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue