RFR: 8305636: Expand and clean up predicate classes and move them into separate files [v2]
Roland Westrelin
roland at openjdk.org
Fri Jul 28 09:44:55 UTC 2023
On Thu, 27 Jul 2023 15:39:56 GMT, Christian Hagedorn <chagedorn at openjdk.org> wrote:
>> src/hotspot/share/opto/loopPredicate.cpp line 324:
>>
>>> 322: }
>>> 323: register_control(new_iff, lp, entry);
>>> 324: IfProjNode* if_cont;
>>
>> Why is it ok to remove that code?
>
> Thanks Roland for your review!
>
> I think it is okay because when I [originally introduced](https://github.com/openjdk/jdk/commit/a51dd58f388bb04851961dc5265291f01be422b8#diff-57d27180e9c833e88433025fd97a49467aed4a5d6e1867f86622dcffa47e951aL147-L149) the parameter `if_cont_is_true_proj`, I've copied all range checks to the unswitched loop (including hoisted check predicates for range checks). Later, this was [corrected](https://github.com/openjdk/jdk/commit/3fe5886b#diff-57d27180e9c833e88433025fd97a49467aed4a5d6e1867f86622dcffa47e951aL252) to only clone the template assertion predicates which always have a true projection as success projection. The only other case where we use `create_new_if_for_predicate` is with parse predicates which also only have a true projection as success projection. I therefore cleaned this up/reverted it here.
Thanks for the explanation.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/14814#discussion_r1277339855
More information about the hotspot-compiler-dev
mailing list