RFR: JDK-8213381: Hook to allow GC to inject Node::Ideal() calls
Roman Kennke
rkennke at redhat.com
Tue Nov 6 13:28:58 UTC 2018
It now appears to me that for sake of consistency, we shall probably
provide a similar hook for Identity() (and we might actually have a use
for this in Shenandoah too). This is a bit more involved, because
Identity() seems to be called from a few places around the code. I made
the two PhaseGVN::apply_ideal(..) and PhaseGVN::apply_identity(..)
methods public for this reason. Other than that, same concept as
previous patch:
Incremental:
http://cr.openjdk.java.net/~rkennke/JDK-8213381/webrev.01.diff/
Full:
http://cr.openjdk.java.net/~rkennke/JDK-8213381/webrev.01/
Thoughts?
Roman
> Shenandoah injects a couple of reshapings into some implementations of
> Node::Ideal() (namely CallLeafNode::Ideal() and CmpPNode::Ideal()). I
> propose to provide a hook into BarrierSetC2 to better abstract this.
> This might be useful for other GCs too.
>
> The approach that I've chosen here is to call BSC2::ideal_node(..) from
> the places in phaseX.cpp where we also call Node::Ideal(..). I've
> introduced a helper method to do this: first call BSC2::ideal_node(..),
> if that returns NULL, call into the usual Node::Ideal(..).
>
> BarrierSetC2::ideal_node(..) must follow the same contract as
> Node::Ideal(..) of course.
>
> Bug:
> https://bugs.openjdk.java.net/browse/JDK-8213381
> Webrev:
> http://cr.openjdk.java.net/~rkennke/JDK-8213381/webrev.00/
>
> Testing: hotspot/jtreg:tier1 passes locally.
>
> Can I please get reviews?
>
> 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/20181106/0dbd8e28/signature.asc>
More information about the hotspot-gc-dev
mailing list