8238691: C2: turn subtype check into macro node

Roland Westrelin rwestrel at redhat.com
Thu Feb 13 16:45:16 UTC 2020


Hi Tobias,

Thanks for the review.

http://cr.openjdk.java.net/~roland/8238691/webrev.02/

> Here are some minor (style) comments:
> - I don't like that find_bottom_mem code but I guess there's no way to avoid it. Please add at least
> a comment because without your explanation in the RFR it's not obvious why it's needed.

I don't like it either but alternatives are not appealing: use immutable
memory when the field is mutable or carry memory as input to the macro
node which would get in the way of optimizations or build complicated
machinery to connect memory edges accurately at macro expansion time
that would make no functional difference.

> - In SubTypeCheckNode::Ideal, why are you adding these temporary nodes to the worklist instead of
> just calling remove_dead_node? Also, shouldn't you do these before the return in line 143 as well?

I usually go with pushing the node on the worklist and you usually ask
me to change it to calling remove_dead_node. I don't have a strong
preference so I changed it but I'm not sure I see why one is better than
another.

>> I verified that it fixes JDK-8220708 [1]. 
>
> Can we close JDK-8220708 as duplicate then?

A question for Vladimir?

> Have you filed an issue for the node budget problem yet?

Not yet. I was waiting to see what others would say.

Roland.



More information about the hotspot-compiler-dev mailing list