RFR: JDK-8269423: ZGC: Support pinned Object and remove/simplify GCLocker usage in ZGC

Per Liden pliden at openjdk.java.net
Thu Jul 1 13:01:04 UTC 2021


On Thu, 1 Jul 2021 09:21:33 GMT, Hamlin Li <mli at openjdk.org> wrote:

> This PR is not an real intention to push current implementation, and current implementation does not support ZVerifyViews (which was pointed out by Per at https://github.com/openjdk/jdk/pull/4638#issuecomment-872033165).
> 
> Let's see if this solution is feasible and how to support ZVerifyViews efficiently.

I suggest we close this PR for now and revisit this once we have the generational work in place, since that might open up some doors for this.

One thing to also keep in mind is that ZGC is less affected by the GC locker than an STW collector is, since all the GC locker does is potentially delaying the start of the marking and relocation phases. In a STW collector context it typically also blocks allocations from happening, which isn't the case in ZGC. So, I am a bit curious if you have actually seen GC locker related problems with ZGC?

Finally, just a quick comment on the code. I see you moved the installation of the relocation set and the setup of forwarding tables into `ZHeap::relocate_start()`. This means this will now be executed in a STW pause, which is not an option as those operations can be quite expensive and are not O(1).

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

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


More information about the hotspot-gc-dev mailing list