RFR: 8305898: Alternative self-forwarding mechanism
Albert Mingkun Yang
ayang at openjdk.org
Thu Aug 22 09:35:02 UTC 2024
On Thu, 22 Aug 2024 09:24:11 GMT, Stefan Karlsson <stefank at openjdk.org> wrote:
>> I wasn't sure about this. What happens to successfully-promoted objects? Are we sure that no references point to their from-space parts? If yes, then I'd remove the else-if part and place an assert there instead.
>
> The else if part is needed when we later turn on UseCompactObjectHeaders, because the "normal" forwarding pointers then destroy the klass pointers, causing the object_iterate to fail to read the size of the objects.
> What happens to successfully-promoted objects? ...
Successfully-forwarded objs are don't live in eden/from spaces, which are the spaces this closure is applied on. One can't have assert here, because as we iterate over eden/from spaces, we will encounter successfully-forwarded objs, but they should just be skipped.
> The else if part is needed when we later turn on UseCompactObjectHeaders...
I believe so, but it should be in the UseCompactObjectHeaders PR, not this one.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/20603#discussion_r1726703952
More information about the hotspot-gc-dev
mailing list