RFR: 8253763: ParallelObjectIterator should have virtual destructor
Aleksey Shipilev
shade at openjdk.java.net
Tue Sep 29 07:23:10 UTC 2020
On Tue, 29 Sep 2020 07:06:31 GMT, Per Liden <pliden at openjdk.org> wrote:
> 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.
Good catch.
-------------
Marked as reviewed by shade (Reviewer).
PR: https://git.openjdk.java.net/jdk/pull/395
More information about the hotspot-gc-dev
mailing list