< prev index next >

src/share/vm/gc/g1/g1CollectedHeap.cpp

Print this page
rev 11935 : [mq]: 8165292-gc-task-logging-spams-log


1315       check_gc_time_stamps();
1316 
1317       resize_if_necessary_after_full_collection();
1318 
1319       // We should do this after we potentially resize the heap so
1320       // that all the COMMIT / UNCOMMIT events are generated before
1321       // the compaction events.
1322       print_hrm_post_compaction();
1323 
1324       if (_hot_card_cache->use_cache()) {
1325         _hot_card_cache->reset_card_counts();
1326         _hot_card_cache->reset_hot_cache();
1327       }
1328 
1329       // Rebuild remembered sets of all regions.
1330       uint n_workers =
1331         AdaptiveSizePolicy::calc_active_workers(workers()->total_workers(),
1332                                                 workers()->active_workers(),
1333                                                 Threads::number_of_non_daemon_threads());
1334       workers()->update_active_workers(n_workers);

1335 
1336       ParRebuildRSTask rebuild_rs_task(this);
1337       workers()->run_task(&rebuild_rs_task);
1338 
1339       // Rebuild the strong code root lists for each region
1340       rebuild_strong_code_roots();
1341 
1342       if (true) { // FIXME
1343         MetaspaceGC::compute_new_size();
1344       }
1345 
1346 #ifdef TRACESPINNING
1347       ParallelTaskTerminator::print_termination_counts();
1348 #endif
1349 
1350       // Discard all rset updates
1351       JavaThread::dirty_card_queue_set().abandon_logs();
1352       assert(dirty_card_queue_set().completed_buffers_num() == 0, "DCQS should be empty");
1353 
1354       // At this point there should be no regions in the


3051     }
3052 
3053     _gc_tracer_stw->report_yc_type(collector_state()->yc_type());
3054 
3055     GCTraceCPUTime tcpu;
3056 
3057     FormatBuffer<> gc_string("Pause ");
3058     if (collector_state()->during_initial_mark_pause()) {
3059       gc_string.append("Initial Mark");
3060     } else if (collector_state()->gcs_are_young()) {
3061       gc_string.append("Young");
3062     } else {
3063       gc_string.append("Mixed");
3064     }
3065     GCTraceTime(Info, gc) tm(gc_string, NULL, gc_cause(), true);
3066 
3067     uint active_workers = AdaptiveSizePolicy::calc_active_workers(workers()->total_workers(),
3068                                                                   workers()->active_workers(),
3069                                                                   Threads::number_of_non_daemon_threads());
3070     workers()->update_active_workers(active_workers);

3071 
3072     TraceCollectorStats tcs(g1mm()->incremental_collection_counters());
3073     TraceMemoryManagerStats tms(false /* fullGC */, gc_cause());
3074 
3075     // If the secondary_free_list is not empty, append it to the
3076     // free_list. No need to wait for the cleanup operation to finish;
3077     // the region allocation code will check the secondary_free_list
3078     // and wait if necessary. If the G1StressConcRegionFreeing flag is
3079     // set, skip this step so that the region allocation code has to
3080     // get entries from the secondary_free_list.
3081     if (!G1StressConcRegionFreeing) {
3082       append_secondary_free_list_if_not_empty_with_lock();
3083     }
3084 
3085     G1HeapTransition heap_transition(this);
3086     size_t heap_used_bytes_before_gc = used();
3087 
3088     // Don't dynamically change the number of GC threads this early.  A value of
3089     // 0 is used to indicate serial work.  When parallel work is done,
3090     // it will be set.




1315       check_gc_time_stamps();
1316 
1317       resize_if_necessary_after_full_collection();
1318 
1319       // We should do this after we potentially resize the heap so
1320       // that all the COMMIT / UNCOMMIT events are generated before
1321       // the compaction events.
1322       print_hrm_post_compaction();
1323 
1324       if (_hot_card_cache->use_cache()) {
1325         _hot_card_cache->reset_card_counts();
1326         _hot_card_cache->reset_hot_cache();
1327       }
1328 
1329       // Rebuild remembered sets of all regions.
1330       uint n_workers =
1331         AdaptiveSizePolicy::calc_active_workers(workers()->total_workers(),
1332                                                 workers()->active_workers(),
1333                                                 Threads::number_of_non_daemon_threads());
1334       workers()->update_active_workers(n_workers);
1335       log_info(gc,task)("Using %u workers of %u to rebuild remembered set", n_workers, workers()->total_workers());
1336 
1337       ParRebuildRSTask rebuild_rs_task(this);
1338       workers()->run_task(&rebuild_rs_task);
1339 
1340       // Rebuild the strong code root lists for each region
1341       rebuild_strong_code_roots();
1342 
1343       if (true) { // FIXME
1344         MetaspaceGC::compute_new_size();
1345       }
1346 
1347 #ifdef TRACESPINNING
1348       ParallelTaskTerminator::print_termination_counts();
1349 #endif
1350 
1351       // Discard all rset updates
1352       JavaThread::dirty_card_queue_set().abandon_logs();
1353       assert(dirty_card_queue_set().completed_buffers_num() == 0, "DCQS should be empty");
1354 
1355       // At this point there should be no regions in the


3052     }
3053 
3054     _gc_tracer_stw->report_yc_type(collector_state()->yc_type());
3055 
3056     GCTraceCPUTime tcpu;
3057 
3058     FormatBuffer<> gc_string("Pause ");
3059     if (collector_state()->during_initial_mark_pause()) {
3060       gc_string.append("Initial Mark");
3061     } else if (collector_state()->gcs_are_young()) {
3062       gc_string.append("Young");
3063     } else {
3064       gc_string.append("Mixed");
3065     }
3066     GCTraceTime(Info, gc) tm(gc_string, NULL, gc_cause(), true);
3067 
3068     uint active_workers = AdaptiveSizePolicy::calc_active_workers(workers()->total_workers(),
3069                                                                   workers()->active_workers(),
3070                                                                   Threads::number_of_non_daemon_threads());
3071     workers()->update_active_workers(active_workers);
3072     log_info(gc,task)("Using %u workers of %u for evacuation", active_workers, workers()->total_workers());
3073 
3074     TraceCollectorStats tcs(g1mm()->incremental_collection_counters());
3075     TraceMemoryManagerStats tms(false /* fullGC */, gc_cause());
3076 
3077     // If the secondary_free_list is not empty, append it to the
3078     // free_list. No need to wait for the cleanup operation to finish;
3079     // the region allocation code will check the secondary_free_list
3080     // and wait if necessary. If the G1StressConcRegionFreeing flag is
3081     // set, skip this step so that the region allocation code has to
3082     // get entries from the secondary_free_list.
3083     if (!G1StressConcRegionFreeing) {
3084       append_secondary_free_list_if_not_empty_with_lock();
3085     }
3086 
3087     G1HeapTransition heap_transition(this);
3088     size_t heap_used_bytes_before_gc = used();
3089 
3090     // Don't dynamically change the number of GC threads this early.  A value of
3091     // 0 is used to indicate serial work.  When parallel work is done,
3092     // it will be set.


< prev index next >