8276833: G1: Make G1EvacFailureRegions::par_iterate const

Reviewed-by: tschatzl, ayang
This commit is contained in:
Hamlin Li 2021-11-10 01:12:43 +00:00
parent 0699220830
commit c8b0ee6b8a
2 changed files with 2 additions and 2 deletions

View File

@ -56,7 +56,7 @@ void G1EvacFailureRegions::post_collection() {
void G1EvacFailureRegions::par_iterate(HeapRegionClosure* closure,
HeapRegionClaimer* _hrclaimer,
uint worker_id) {
uint worker_id) const {
G1CollectedHeap::heap()->par_iterate_regions_array(closure,
_hrclaimer,
_evac_failure_regions,

View File

@ -56,7 +56,7 @@ public:
bool contains(uint region_idx) const;
void par_iterate(HeapRegionClosure* closure,
HeapRegionClaimer* _hrclaimer,
uint worker_id);
uint worker_id) const;
uint num_regions_failed_evacuation() const {
return Atomic::load(&_evac_failure_regions_cur_length);