Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8240915

Shenandoah: Remove unused fields in init mark tasks

XMLWordPrintable

    • gc
    • b15

        There are unused fields in ShenandoahInitMarkRootsTask and ShenandoahInitTraversalCollectionTask.

        diff -r 98fe04cf4e13 src/hotspot/share/gc/shenandoah/shenandoahConcurrentMark.cpp
        --- a/src/hotspot/share/gc/shenandoah/shenandoahConcurrentMark.cpp Tue Feb 25 12:01:35 2020 -0500
        +++ b/src/hotspot/share/gc/shenandoah/shenandoahConcurrentMark.cpp Wed Mar 11 19:47:50 2020 -0400
        @@ -84,12 +84,10 @@
         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) {
        @@ -292,12 +290,12 @@
           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);
           }
         
        diff -r 98fe04cf4e13 src/hotspot/share/gc/shenandoah/shenandoahTraversalGC.cpp
        --- a/src/hotspot/share/gc/shenandoah/shenandoahTraversalGC.cpp Tue Feb 25 12:01:35 2020 -0500
        +++ b/src/hotspot/share/gc/shenandoah/shenandoahTraversalGC.cpp Wed Mar 11 19:47:50 2020 -0400
        @@ -162,8 +162,6 @@
         private:
           ShenandoahCSetRootScanner* _rp;
           ShenandoahHeap* _heap;
        - ShenandoahCsetCodeRootsIterator* _cset_coderoots;
        - ShenandoahStringDedupRoots _dedup_roots;
         
         public:
           ShenandoahInitTraversalCollectionTask(ShenandoahCSetRootScanner* rp) :

              zgu Zhengyu Gu
              zgu Zhengyu Gu
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: