RFR(S): 8196296: Lucene test crashes C2 compilation

Uwe Schindler uschindler at apache.org
Fri Jan 26 22:50:11 UTC 2018

Hi Roland,

Many thanks. Did you figure out which code part in Lucene or ICU4J caused this?

I don't see a test case in the patch.


Am January 26, 2018 10:21:17 PM UTC schrieb Roland Westrelin <rwestrel at redhat.com>:
>C2 attempts to merge 2 back to back ifs with the same condition:
>if (condition) {
>} else {
>if (condition) {
>but the second if is a counted loop end test. This causes the counted
>loop to not keep a canonical shape. With debug builds, loop strip
>verification code then causes the test to crash. With product builds,
>the logic that finalizes the outer strip mined loop bails out but
>the outer loop. The test of the outer loop is turned into an If with a
>constant input that's not optimized out. In the reported failure,
>Matcher code then breaks because the If has a non Cmp input. I fixed
>the logic in OuterStripMinedLoopNode::adjust_strip_mined_loop() so that
>when it bails out, it causes the outer loop to go away and prevent 2
>back to back ifs to merge if the second one is a counted loop end.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/hotspot-compiler-dev/attachments/20180126/ea74132b/attachment.html>

More information about the hotspot-compiler-dev mailing list