< prev index next >

src/hotspot/share/gc/g1/g1ConcurrentMark.cpp

Print this page
rev 52572 : [mq]: 8213996-remove-sparseprt-table

*** 1218,1239 **** G1CollectedHeap* _g1h; size_t _freed_bytes; FreeRegionList* _local_cleanup_list; uint _old_regions_removed; uint _humongous_regions_removed; - HRRSCleanupTask* _hrrs_cleanup_task; public: G1ReclaimEmptyRegionsClosure(G1CollectedHeap* g1h, ! FreeRegionList* local_cleanup_list, ! HRRSCleanupTask* hrrs_cleanup_task) : _g1h(g1h), _freed_bytes(0), _local_cleanup_list(local_cleanup_list), _old_regions_removed(0), ! _humongous_regions_removed(0), ! _hrrs_cleanup_task(hrrs_cleanup_task) { } size_t freed_bytes() { return _freed_bytes; } const uint old_regions_removed() { return _old_regions_removed; } const uint humongous_regions_removed() { return _humongous_regions_removed; } --- 1218,1236 ---- G1CollectedHeap* _g1h; size_t _freed_bytes; FreeRegionList* _local_cleanup_list; uint _old_regions_removed; uint _humongous_regions_removed; public: G1ReclaimEmptyRegionsClosure(G1CollectedHeap* g1h, ! FreeRegionList* local_cleanup_list) : _g1h(g1h), _freed_bytes(0), _local_cleanup_list(local_cleanup_list), _old_regions_removed(0), ! _humongous_regions_removed(0){ } size_t freed_bytes() { return _freed_bytes; } const uint old_regions_removed() { return _old_regions_removed; } const uint humongous_regions_removed() { return _humongous_regions_removed; }
*** 1249,1260 **** _g1h->free_region(hr, _local_cleanup_list, false /* skip_remset */, false /* skip_hcc */, true /* locked */); } hr->clear_cardtable(); _g1h->concurrent_mark()->clear_statistics_in_region(hr->hrm_index()); log_trace(gc)("Reclaimed empty region %u (%s) bot " PTR_FORMAT, hr->hrm_index(), hr->get_short_type_str(), p2i(hr->bottom())); - } else { - hr->rem_set()->do_cleanup_work(_hrrs_cleanup_task); } return false; } }; --- 1246,1255 ----
*** 1267,1286 **** G1ReclaimEmptyRegionsTask(G1CollectedHeap* g1h, FreeRegionList* cleanup_list, uint n_workers) : AbstractGangTask("G1 Cleanup"), _g1h(g1h), _cleanup_list(cleanup_list), _hrclaimer(n_workers) { - - HeapRegionRemSet::reset_for_cleanup_tasks(); } void work(uint worker_id) { FreeRegionList local_cleanup_list("Local Cleanup List"); ! HRRSCleanupTask hrrs_cleanup_task; ! G1ReclaimEmptyRegionsClosure cl(_g1h, ! &local_cleanup_list, ! &hrrs_cleanup_task); _g1h->heap_region_par_iterate_from_worker_offset(&cl, &_hrclaimer, worker_id); assert(cl.is_complete(), "Shouldn't have aborted!"); // Now update the old/humongous region sets _g1h->remove_from_old_sets(cl.old_regions_removed(), cl.humongous_regions_removed()); --- 1262,1276 ---- G1ReclaimEmptyRegionsTask(G1CollectedHeap* g1h, FreeRegionList* cleanup_list, uint n_workers) : AbstractGangTask("G1 Cleanup"), _g1h(g1h), _cleanup_list(cleanup_list), _hrclaimer(n_workers) { } void work(uint worker_id) { FreeRegionList local_cleanup_list("Local Cleanup List"); ! G1ReclaimEmptyRegionsClosure cl(_g1h, &local_cleanup_list); _g1h->heap_region_par_iterate_from_worker_offset(&cl, &_hrclaimer, worker_id); assert(cl.is_complete(), "Shouldn't have aborted!"); // Now update the old/humongous region sets _g1h->remove_from_old_sets(cl.old_regions_removed(), cl.humongous_regions_removed());
*** 1288,1299 **** MutexLockerEx x(ParGCRareEvent_lock, Mutex::_no_safepoint_check_flag); _g1h->decrement_summary_bytes(cl.freed_bytes()); _cleanup_list->add_ordered(&local_cleanup_list); assert(local_cleanup_list.is_empty(), "post-condition"); - - HeapRegionRemSet::finish_cleanup_task(&hrrs_cleanup_task); } } }; void G1ConcurrentMark::reclaim_empty_regions() { --- 1278,1287 ----
< prev index next >