< prev index next >

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

Print this page
rev 8137 : 8077836: Make sure G1ParGCAllocBuffer are marked as retired
Reviewed-by:

@@ -167,10 +167,15 @@
       return;
     }
     ParGCAllocBuffer::retire();
     _retired = true;
   }
+
+  virtual void flush_and_retire_stats(PLABStats* stats) {
+    ParGCAllocBuffer::flush_and_retire_stats(stats);
+    _retired = true;
+  }
 };
 
 class G1ParGCAllocator : public CHeapObj<mtGC> {
   friend class G1ParScanThreadState;
 protected:

@@ -209,10 +214,11 @@
 public:
   G1ParGCAllocator(G1CollectedHeap* g1h) :
     _g1h(g1h), _survivor_alignment_bytes(calc_survivor_alignment_bytes()),
     _alloc_buffer_waste(0), _undo_waste(0) {
   }
+  virtual ~G1ParGCAllocator() { }
 
   static G1ParGCAllocator* create_allocator(G1CollectedHeap* g1h);
 
   size_t alloc_buffer_waste() { return _alloc_buffer_waste; }
   size_t undo_waste() {return _undo_waste; }
< prev index next >