src/share/vm/gc_implementation/g1/g1CollectedHeap.hpp

Print this page
rev 5918 : 8035326: Assume non-NULL references in G1CollectedHeap::in_cset_fast_test
Summary: Remove the assumption that G1CollectedHeap::in_cset_fast_test needs to check for NULL references. Most of the time this is not required, making the code doing this check multiple times.
Reviewed-by:
rev 5919 : 8035329: Move G1ParCopyClosure::copy_to_survivor_space into G1ParScanThreadState
Summary: Move G1ParCopyClosure::copy_to_survivor_space to decrease code size.

@@ -1873,10 +1873,12 @@
   G1ParGCAllocBufferContainer  _surviving_alloc_buffer;
   G1ParGCAllocBufferContainer  _tenured_alloc_buffer;
   G1ParGCAllocBufferContainer* _alloc_buffers[GCAllocPurposeCount];
   ageTable            _age_table;
 
+  G1ParScanClosure    _scanner;
+
   size_t           _alloc_buffer_waste;
   size_t           _undo_waste;
 
   OopsInHeapRegionClosure*      _evac_failure_cl;
   G1ParScanHeapEvacClosure*     _evac_cl;

@@ -1925,11 +1927,11 @@
       }
     }
   }
 
 public:
-  G1ParScanThreadState(G1CollectedHeap* g1h, uint queue_num);
+  G1ParScanThreadState(G1CollectedHeap* g1h, uint queue_num, ReferenceProcessor* rp);
 
   ~G1ParScanThreadState() {
     FREE_C_HEAP_ARRAY(size_t, _surviving_young_words_base, mtGC);
   }
 

@@ -2060,10 +2062,12 @@
                                                  true /* end_of_gc */,
                                                  false /* retain */);
     }
   }
 
+  oop copy_to_survivor_space(oop const obj);
+
   template <class T> void deal_with_reference(T* ref_to_scan) {
     if (has_partial_array_mask(ref_to_scan)) {
       _partial_scan_cl->do_oop_nv(ref_to_scan);
     } else {
       // Note: we can use "raw" versions of "region_containing" because