8240915: Shenandoah: Remove unused fields in init mark tasks

Reviewed-by: rkennke
This commit is contained in:
Zhengyu Gu 2020-03-12 09:25:08 -04:00
parent bb42321076
commit 95d2178ba3
2 changed files with 4 additions and 8 deletions

View File

@ -83,12 +83,10 @@ template<UpdateRefsMode UPDATE_REFS>
class ShenandoahInitMarkRootsTask : public AbstractGangTask {
private:
ShenandoahAllRootScanner* _rp;
bool _process_refs;
public:
ShenandoahInitMarkRootsTask(ShenandoahAllRootScanner* rp, bool process_refs) :
ShenandoahInitMarkRootsTask(ShenandoahAllRootScanner* rp) :
AbstractGangTask("Shenandoah init mark roots task"),
_rp(rp),
_process_refs(process_refs) {
_rp(rp) {
}
void work(uint worker_id) {
@ -260,12 +258,12 @@ void ShenandoahConcurrentMark::mark_roots(ShenandoahPhaseTimings::Phase root_pha
task_queues()->reserve(nworkers);
if (heap->has_forwarded_objects()) {
ShenandoahInitMarkRootsTask<RESOLVE> mark_roots(&root_proc, _heap->process_references());
ShenandoahInitMarkRootsTask<RESOLVE> mark_roots(&root_proc);
workers->run_task(&mark_roots);
} else {
// No need to update references, which means the heap is stable.
// Can save time not walking through forwarding pointers.
ShenandoahInitMarkRootsTask<NONE> mark_roots(&root_proc, _heap->process_references());
ShenandoahInitMarkRootsTask<NONE> mark_roots(&root_proc);
workers->run_task(&mark_roots);
}

View File

@ -161,8 +161,6 @@ class ShenandoahInitTraversalCollectionTask : public AbstractGangTask {
private:
ShenandoahCSetRootScanner* _rp;
ShenandoahHeap* _heap;
ShenandoahCsetCodeRootsIterator* _cset_coderoots;
ShenandoahStringDedupRoots _dedup_roots;
public:
ShenandoahInitTraversalCollectionTask(ShenandoahCSetRootScanner* rp) :