< prev index next >

src/hotspot/share/gc/z/zRelocationSetSelector.cpp

Print this page

        

*** 167,176 **** --- 167,177 ---- } ZRelocationSetSelector::ZRelocationSetSelector() : _small("Small", ZPageSizeSmall, ZObjectSizeLimitSmall), _medium("Medium", ZPageSizeMedium, ZObjectSizeLimitMedium), + _reclaimable(), _live(0), _garbage(0), _fragmentation(0) {} void ZRelocationSetSelector::register_live_page(ZPage* page) {
*** 188,201 **** _live += live; _garbage += garbage; } ! void ZRelocationSetSelector::register_garbage_page(ZPage* page) { _garbage += page->size(); } void ZRelocationSetSelector::select(ZRelocationSet* relocation_set) { // Select pages to relocate. The resulting relocation set will be // sorted such that medium pages comes first, followed by small // pages. Pages within each page group will be semi-sorted by live // bytes in ascending order. Relocating pages in this order allows --- 189,207 ---- _live += live; _garbage += garbage; } ! void ZRelocationSetSelector::register_reclaimable_page(ZPage* page) { ! _reclaimable.add(page); _garbage += page->size(); } + ZArray<ZPage*>* ZRelocationSetSelector::reclaimable() { + return &_reclaimable; + } + void ZRelocationSetSelector::select(ZRelocationSet* relocation_set) { // Select pages to relocate. The resulting relocation set will be // sorted such that medium pages comes first, followed by small // pages. Pages within each page group will be semi-sorted by live // bytes in ascending order. Relocating pages in this order allows
< prev index next >