8238691: C2: turn subtype check into macro node
Roland Westrelin
rwestrel at redhat.com
Mon Feb 10 12:02:36 UTC 2020
Hi Vladimir,
> I verified that it fixes JDK-8220708 [1].
>
> Overall, the patch looks good.
Thanks for the review and help with the various previous prototypes.
> Also, during performance testing we spotted that it becomes more likely
> to hit hard compilation limits with late expansion of subtype checks
> (e.g., on Octane -XX:MaxNodeLimit=160000 -XX:NodeLimitFudgeFactor=3200
> helped to recover performance).
>
> It doesn't look specific to subtype checks, but more about how macro
> nodes are handled. Existing heuristics which rely on node count don't
> take into account how many macro nodes are there and may behave too
> aggressively pushing the compilation to the limit which is hit during
> macro expansion.
>
> What's your take on that? I'm fine with handling it separately, but
> though the problem is not new, it looks like the patch may worsen the
> situation in some cases.
You're right that the risk of exhausting the node budget at macro
expansion time increases and something should be done about it. I'll
file a bug.
> Meanwhile, it looks feasible to have a diagnostic flag to force eager
> subtype check expansion during parsing. We can remove it later.
This then:
http://cr.openjdk.java.net/~roland/8238691/webrev.01/
Roland.
More information about the hotspot-compiler-dev
mailing list