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

ParallelObjectIterator should have virtual destructor

    XMLWordPrintable

Details

    • gc
    • b18

    Backports

      Description

        The ParallelObjectIterator should have virtual destructor, since implementations of CollectedHeap::parallel_object_iterator() returns the base type, which is later passed to the delete operator.

        Today both G1 and Shenandoah leaks memory here. I noticed this bug when when implementing ZCollectedHeap::parallel_object_iterator(). Bug was introduced in JDK-8215624.

        Attachments

          Issue Links

            Activity

              People

                pliden Per Liden (Inactive)
                pliden Per Liden (Inactive)
                Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: