RFR: 8330981: ZGC: Should not dedup strings in the finalizer graph
Thomas Schatzl
tschatzl at openjdk.org
Wed May 29 07:56:01 UTC 2024
On Wed, 29 May 2024 07:18:24 GMT, Erik Österlund <eosterlund at openjdk.org> wrote:
> The generic logic we have for deduplicating strings during marking in various GCs, relies on creating a phantom root to store strings to be deduplicated. When storing an oop into a phantom root, it is required that the oop is strongly reachable at that point. However, when ZGC marks through finalizers (as opposed to the strongly reachable graph), the oop has not been marked as strongly reachable, and hence it isn't really safe to create that phantom root.
>
> The solution is quite simple, really. Just don't deduplicate strings when marking through the finalizer graph.
Marked as reviewed by tschatzl (Reviewer).
-------------
PR Review: https://git.openjdk.org/jdk/pull/19444#pullrequestreview-2084590066
More information about the hotspot-gc-dev
mailing list