RFR: JDK-8214055: GC/C2 abstraction for phaseX

Roman Kennke rkennke at redhat.com
Wed Nov 21 10:53:40 UTC 2018


There are (Z)GC specific changes in
PhaseIterGVN::add_users_to_worklist() and PhaseCCP::analyze(), and
Shenandoah needs to add some stuff there too. Let's put in an
abstraction for this.

It should be noted that the ZGC path is now unwoven from the general
path, at the expense of iterating the outputs 2x. I don't expect this to
be a problem.

The way it was before I did not like much, because it built some fairly
ZGC specific implicit knowledge (has_load_barriers()) into the shared
path, the way it's done now it seems more explicitely ZGC path. It could
be argued that a future GC with load-barriers would need this too, but
we don't know this yet. It could just the same be the case that a future
GC has load-barriers, but needs slightly different handling there. I'd
even say that this type of implicit knowledge is worse than simply
guarding a path with #if INCLUDE_ZGC or similar, because the latter
actually screams "THIS IS GC SPECIFIC" while the current implicit way
doesn't.

Also note that this includes a subtle bugfix: in the PhaseCPP::analyze()
path, the ZGC version pushed to _worklist, but every other code there
uses the local worklist instead.

Bug:
https://bugs.openjdk.java.net/browse/JDK-8214055
Webrev:
http://cr.openjdk.java.net/~rkennke/JDK-8214055/webrev.00/

Testing: tier1 ok

Can I please get reviews?

Thanks, Roman

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <https://mail.openjdk.org/pipermail/hotspot-gc-dev/attachments/20181121/8ec973e0/signature.asc>


More information about the hotspot-gc-dev mailing list