RFR: 8281429: PhiNode::Value() is too conservative for tripcount of CountedLoop [v6]
Xin Liu
xliu at openjdk.java.net
Thu Apr 14 16:38:32 UTC 2022
On Thu, 14 Apr 2022 15:45:51 GMT, Roland Westrelin <roland at openjdk.org> wrote:
>> src/hotspot/share/opto/loopnode.cpp line 854:
>>
>>> 852: swap(lo, hi);
>>> 853: }
>>> 854: if (hi->hi_as_long() <= lo->lo_as_long()) {
>>
>> why this is <= instead of < ?
>
> If hi->hi_as_long() == lo->lo_as_long() the body is entered at most once and there's no loop, right?
> FWIW, this test is in case the LongCountedLoop was created in the current pass of loop opts and igvn hasn't had a chance to run yet (and optimize the backedge out).
yes.
I see. we don't need to generated nested loop for it.
-------------
PR: https://git.openjdk.java.net/jdk/pull/7823
More information about the hotspot-compiler-dev
mailing list