equal
deleted
inserted
replaced
84 reuse_retained_old_region(evacuation_info, |
84 reuse_retained_old_region(evacuation_info, |
85 &_old_gc_alloc_region, |
85 &_old_gc_alloc_region, |
86 &_retained_old_gc_alloc_region); |
86 &_retained_old_gc_alloc_region); |
87 } |
87 } |
88 |
88 |
89 void G1DefaultAllocator::release_gc_alloc_regions(uint no_of_gc_workers, EvacuationInfo& evacuation_info) { |
89 void G1DefaultAllocator::release_gc_alloc_regions(EvacuationInfo& evacuation_info) { |
90 AllocationContext_t context = AllocationContext::current(); |
90 AllocationContext_t context = AllocationContext::current(); |
91 evacuation_info.set_allocation_regions(survivor_gc_alloc_region(context)->count() + |
91 evacuation_info.set_allocation_regions(survivor_gc_alloc_region(context)->count() + |
92 old_gc_alloc_region(context)->count()); |
92 old_gc_alloc_region(context)->count()); |
93 survivor_gc_alloc_region(context)->release(); |
93 survivor_gc_alloc_region(context)->release(); |
94 // If we have an old GC alloc region to release, we'll save it in |
94 // If we have an old GC alloc region to release, we'll save it in |
100 if (_retained_old_gc_alloc_region != NULL) { |
100 if (_retained_old_gc_alloc_region != NULL) { |
101 _retained_old_gc_alloc_region->record_retained_region(); |
101 _retained_old_gc_alloc_region->record_retained_region(); |
102 } |
102 } |
103 |
103 |
104 if (ResizePLAB) { |
104 if (ResizePLAB) { |
105 _g1h->alloc_buffer_stats(InCSetState::Young)->adjust_desired_plab_sz(no_of_gc_workers); |
105 _g1h->alloc_buffer_stats(InCSetState::Young)->adjust_desired_plab_sz(); |
106 _g1h->alloc_buffer_stats(InCSetState::Old)->adjust_desired_plab_sz(no_of_gc_workers); |
106 _g1h->alloc_buffer_stats(InCSetState::Old)->adjust_desired_plab_sz(); |
107 } |
107 } |
108 } |
108 } |
109 |
109 |
110 void G1DefaultAllocator::abandon_gc_alloc_regions() { |
110 void G1DefaultAllocator::abandon_gc_alloc_regions() { |
111 assert(survivor_gc_alloc_region(AllocationContext::current())->get() == NULL, "pre-condition"); |
111 assert(survivor_gc_alloc_region(AllocationContext::current())->get() == NULL, "pre-condition"); |