src/hotspot/share/gc/g1/g1FullCollector.hpp
changeset 49964 99e698e94cc7
parent 49826 ad1a5f49b8ae
child 51497 ec014e5694ec
--- a/src/hotspot/share/gc/g1/g1FullCollector.hpp	Thu Apr 26 12:54:53 2018 +0200
+++ b/src/hotspot/share/gc/g1/g1FullCollector.hpp	Thu May 03 14:09:00 2018 +0200
@@ -42,6 +42,16 @@
 class GCMemoryManager;
 class ReferenceProcessor;
 
+// Subject-to-discovery closure for reference processing during Full GC. During
+// Full GC the whole heap is subject to discovery.
+class G1FullGCSubjectToDiscoveryClosure: public BoolObjectClosure {
+public:
+  bool do_object_b(oop p) {
+    assert(p != NULL, "must be");
+    return true;
+  }
+};
+
 // The G1FullCollector holds data associated with the current Full GC.
 class G1FullCollector : StackObj {
   G1CollectedHeap*          _heap;
@@ -58,6 +68,9 @@
 
   static uint calc_active_workers();
 
+  G1FullGCSubjectToDiscoveryClosure _always_subject_to_discovery;
+  ReferenceProcessorSubjectToDiscoveryMutator _is_subject_mutator;
+
 public:
   G1FullCollector(G1CollectedHeap* heap, GCMemoryManager* memory_manager, bool explicit_gc, bool clear_soft_refs);
   ~G1FullCollector();