< prev index next >

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

Print this page

  68 #include "gc/g1/g1RootClosures.hpp"
  69 #include "gc/g1/g1RootProcessor.hpp"
  70 #include "gc/g1/g1SATBMarkQueueSet.hpp"
  71 #include "gc/g1/g1ServiceThread.hpp"
  72 #include "gc/g1/g1ThreadLocalData.hpp"
  73 #include "gc/g1/g1Trace.hpp"
  74 #include "gc/g1/g1UncommitRegionTask.hpp"
  75 #include "gc/g1/g1VMOperations.hpp"
  76 #include "gc/g1/g1YoungCollector.hpp"
  77 #include "gc/g1/g1YoungGCAllocationFailureInjector.hpp"
  78 #include "gc/shared/classUnloadingContext.hpp"
  79 #include "gc/shared/concurrentGCBreakpoints.hpp"
  80 #include "gc/shared/gcBehaviours.hpp"
  81 #include "gc/shared/gcHeapSummary.hpp"
  82 #include "gc/shared/gcId.hpp"
  83 #include "gc/shared/gcTimer.hpp"
  84 #include "gc/shared/gcTraceTime.inline.hpp"
  85 #include "gc/shared/isGCActiveMark.hpp"
  86 #include "gc/shared/locationPrinter.inline.hpp"
  87 #include "gc/shared/oopStorageParState.hpp"
  88 #include "gc/shared/preservedMarks.inline.hpp"
  89 #include "gc/shared/referenceProcessor.inline.hpp"

  90 #include "gc/shared/suspendibleThreadSet.hpp"
  91 #include "gc/shared/taskqueue.inline.hpp"
  92 #include "gc/shared/taskTerminator.hpp"
  93 #include "gc/shared/tlab_globals.hpp"
  94 #include "gc/shared/workerPolicy.hpp"
  95 #include "gc/shared/weakProcessor.inline.hpp"
  96 #include "logging/log.hpp"
  97 #include "memory/allocation.hpp"
  98 #include "memory/heapInspection.hpp"
  99 #include "memory/iterator.hpp"
 100 #include "memory/metaspaceUtils.hpp"
 101 #include "memory/resourceArea.hpp"
 102 #include "memory/universe.hpp"
 103 #include "oops/access.inline.hpp"
 104 #include "oops/compressedOops.inline.hpp"
 105 #include "oops/oop.inline.hpp"
 106 #include "runtime/atomic.hpp"
 107 #include "runtime/cpuTimeCounters.hpp"
 108 #include "runtime/handles.inline.hpp"
 109 #include "runtime/init.hpp"

1416   dummy_region->set_top(dummy_region->end());
1417   G1AllocRegion::setup(this, dummy_region);
1418 
1419   _allocator->init_mutator_alloc_regions();
1420 
1421   // Do create of the monitoring and management support so that
1422   // values in the heap have been properly initialized.
1423   _monitoring_support = new G1MonitoringSupport(this);
1424 
1425   _collection_set.initialize(max_reserved_regions());
1426 
1427   allocation_failure_injector()->reset();
1428 
1429   CPUTimeCounters::create_counter(CPUTimeGroups::CPUTimeType::gc_parallel_workers);
1430   CPUTimeCounters::create_counter(CPUTimeGroups::CPUTimeType::gc_conc_mark);
1431   CPUTimeCounters::create_counter(CPUTimeGroups::CPUTimeType::gc_conc_refine);
1432   CPUTimeCounters::create_counter(CPUTimeGroups::CPUTimeType::gc_service);
1433 
1434   G1InitLogger::print();
1435 


1436   return JNI_OK;
1437 }
1438 
1439 bool G1CollectedHeap::concurrent_mark_is_terminating() const {
1440   return _cm_thread->should_terminate();
1441 }
1442 
1443 void G1CollectedHeap::stop() {
1444   // Stop all concurrent threads. We do this to make sure these threads
1445   // do not continue to execute and access resources (e.g. logging)
1446   // that are destroyed during shutdown.
1447   _cr->stop();
1448   _service_thread->stop();
1449   _cm_thread->stop();
1450 }
1451 
1452 void G1CollectedHeap::safepoint_synchronize_begin() {
1453   SuspendibleThreadSet::synchronize();
1454 }
1455 

  68 #include "gc/g1/g1RootClosures.hpp"
  69 #include "gc/g1/g1RootProcessor.hpp"
  70 #include "gc/g1/g1SATBMarkQueueSet.hpp"
  71 #include "gc/g1/g1ServiceThread.hpp"
  72 #include "gc/g1/g1ThreadLocalData.hpp"
  73 #include "gc/g1/g1Trace.hpp"
  74 #include "gc/g1/g1UncommitRegionTask.hpp"
  75 #include "gc/g1/g1VMOperations.hpp"
  76 #include "gc/g1/g1YoungCollector.hpp"
  77 #include "gc/g1/g1YoungGCAllocationFailureInjector.hpp"
  78 #include "gc/shared/classUnloadingContext.hpp"
  79 #include "gc/shared/concurrentGCBreakpoints.hpp"
  80 #include "gc/shared/gcBehaviours.hpp"
  81 #include "gc/shared/gcHeapSummary.hpp"
  82 #include "gc/shared/gcId.hpp"
  83 #include "gc/shared/gcTimer.hpp"
  84 #include "gc/shared/gcTraceTime.inline.hpp"
  85 #include "gc/shared/isGCActiveMark.hpp"
  86 #include "gc/shared/locationPrinter.inline.hpp"
  87 #include "gc/shared/oopStorageParState.hpp"

  88 #include "gc/shared/referenceProcessor.inline.hpp"
  89 #include "gc/shared/slidingForwarding.hpp"
  90 #include "gc/shared/suspendibleThreadSet.hpp"
  91 #include "gc/shared/taskqueue.inline.hpp"
  92 #include "gc/shared/taskTerminator.hpp"
  93 #include "gc/shared/tlab_globals.hpp"
  94 #include "gc/shared/workerPolicy.hpp"
  95 #include "gc/shared/weakProcessor.inline.hpp"
  96 #include "logging/log.hpp"
  97 #include "memory/allocation.hpp"
  98 #include "memory/heapInspection.hpp"
  99 #include "memory/iterator.hpp"
 100 #include "memory/metaspaceUtils.hpp"
 101 #include "memory/resourceArea.hpp"
 102 #include "memory/universe.hpp"
 103 #include "oops/access.inline.hpp"
 104 #include "oops/compressedOops.inline.hpp"
 105 #include "oops/oop.inline.hpp"
 106 #include "runtime/atomic.hpp"
 107 #include "runtime/cpuTimeCounters.hpp"
 108 #include "runtime/handles.inline.hpp"
 109 #include "runtime/init.hpp"

1416   dummy_region->set_top(dummy_region->end());
1417   G1AllocRegion::setup(this, dummy_region);
1418 
1419   _allocator->init_mutator_alloc_regions();
1420 
1421   // Do create of the monitoring and management support so that
1422   // values in the heap have been properly initialized.
1423   _monitoring_support = new G1MonitoringSupport(this);
1424 
1425   _collection_set.initialize(max_reserved_regions());
1426 
1427   allocation_failure_injector()->reset();
1428 
1429   CPUTimeCounters::create_counter(CPUTimeGroups::CPUTimeType::gc_parallel_workers);
1430   CPUTimeCounters::create_counter(CPUTimeGroups::CPUTimeType::gc_conc_mark);
1431   CPUTimeCounters::create_counter(CPUTimeGroups::CPUTimeType::gc_conc_refine);
1432   CPUTimeCounters::create_counter(CPUTimeGroups::CPUTimeType::gc_service);
1433 
1434   G1InitLogger::print();
1435 
1436   SlidingForwarding::initialize(heap_rs.region(), G1HeapRegion::GrainWords);
1437 
1438   return JNI_OK;
1439 }
1440 
1441 bool G1CollectedHeap::concurrent_mark_is_terminating() const {
1442   return _cm_thread->should_terminate();
1443 }
1444 
1445 void G1CollectedHeap::stop() {
1446   // Stop all concurrent threads. We do this to make sure these threads
1447   // do not continue to execute and access resources (e.g. logging)
1448   // that are destroyed during shutdown.
1449   _cr->stop();
1450   _service_thread->stop();
1451   _cm_thread->stop();
1452 }
1453 
1454 void G1CollectedHeap::safepoint_synchronize_begin() {
1455   SuspendibleThreadSet::synchronize();
1456 }
1457 
< prev index next >