RFR: 8252105: Parallel heap inspection for ZCollectedHeap

Lin Zang lzang at openjdk.java.net
Tue Oct 6 22:48:09 UTC 2020


On Tue, 6 Oct 2020 13:11:20 GMT, Erik Österlund <eosterlund at openjdk.org> wrote:

>> This patch changes the ZHeapIterator to also support parallel iteration, for use in
>> ZCollectedHeap::parallel_object_iterator(). I initially looked at using the heap walking logic in ZMark, instead of
>> also implementing it in ZHeapIterator. That's probably something we want to do at some point, but that would require
>> some major restructuring of ZMark. In the mean time I've kept the heap walking logic in ZHeapIterator.  The
>> ZHeapIterator now implements ParallelObjectIterator, and the same code paths is used for both serial and parallel
>> iteration. Arrays are chunked using ObjArrayTask to reduce mark stack space. A terminator is used for better work
>> stealing/balance.  Tested using `jmap -histo` and various benchmarks with `-XX:+ZVerifyObjects` and
>> `-XX:+VerifyDuringGC` enabled.
>
> Looks good.

looks good to me( I am not a reviewer)
Thanks for helping refine the patch!

-------------

PR: https://git.openjdk.java.net/jdk/pull/507



More information about the hotspot-gc-dev mailing list