--- old/src/hotspot/share/gc/shenandoah/shenandoahSATBMarkQueueSet.cpp 2019-09-06 16:48:08.944340892 -0400 +++ new/src/hotspot/share/gc/shenandoah/shenandoahSATBMarkQueueSet.cpp 2019-09-06 16:48:08.732329544 -0400 @@ -27,20 +27,10 @@ #include "gc/shenandoah/shenandoahSATBMarkQueueSet.hpp" #include "gc/shenandoah/shenandoahThreadLocalData.hpp" -ShenandoahSATBMarkQueueSet::ShenandoahSATBMarkQueueSet() : - _heap(NULL), - _satb_mark_queue_buffer_allocator("SATB Buffer Allocator", ShenandoahSATBBufferSize) +ShenandoahSATBMarkQueueSet::ShenandoahSATBMarkQueueSet(BufferNode::Allocator* allocator) : + SATBMarkQueueSet(allocator) {} -void ShenandoahSATBMarkQueueSet::initialize(ShenandoahHeap* const heap, - int process_completed_threshold, - uint buffer_enqueue_threshold_percentage) { - SATBMarkQueueSet::initialize(&_satb_mark_queue_buffer_allocator, - process_completed_threshold, - buffer_enqueue_threshold_percentage); - _heap = heap; -} - SATBMarkQueue& ShenandoahSATBMarkQueueSet::satb_queue_for_thread(Thread* const t) const { return ShenandoahThreadLocalData::satb_mark_queue(t); } @@ -60,11 +50,11 @@ }; void ShenandoahSATBMarkQueueSet::filter(SATBMarkQueue* queue) { - assert(_heap != NULL, "SATB queue set not initialized"); - if (_heap->has_forwarded_objects()) { - apply_filter(ShenandoahSATBMarkQueueFilterFn(_heap), queue); + ShenandoahHeap* heap = ShenandoahHeap::heap(); + if (heap->has_forwarded_objects()) { + apply_filter(ShenandoahSATBMarkQueueFilterFn(heap), queue); } else { - apply_filter(ShenandoahSATBMarkQueueFilterFn(_heap), queue); + apply_filter(ShenandoahSATBMarkQueueFilterFn(heap), queue); } }