RFR: 8347449: C2: UseLoopPredicate off should also turn UseProfiledLoopPredicate off [v5]

Christian Hagedorn chagedorn at openjdk.org
Thu Mar 27 14:30:17 UTC 2025


On Thu, 27 Mar 2025 14:01:47 GMT, Emanuel Peter <epeter at openjdk.org> wrote:

>> Manuel Hässig has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains 11 additional commits since the last revision:
>> 
>>  - Merge branch 'master' into JDK-8347449-loop-predicate
>>  - Improve help text for UseProfiledLoopPredicate argument
>>  - loopnode: cleaner control flow
>>  - Clean up IR test
>>  - Apply suggestions from @chhagedorn
>>    
>>    Co-authored-by: Christian Hagedorn <christian.hagedorn at oracle.com>
>>  - ir-framework: rename new nodes to convention
>>  - ir-framework: fix phase for parse predicate nodes
>>  - Make conditions on UseProfiledLoopPredicate first test UseLoopPredicate
>>  - Turn off UseProfiledLoopPredicate when UseLoopPredicate is turned off
>>  - Add regression IR test
>>  - ... and 1 more: https://git.openjdk.org/jdk/compare/44c209f7...72ebfc8e
>
> src/hotspot/share/opto/c2_globals.hpp line 790:
> 
>> 788:           "Move checks with an uncommon trap out of loops based on "        \
>> 789:           "profiling data. "                                                \
>> 790:           "Requires UseLoopPredicate to be turned on (default).")           \
> 
> Can you also update the comment for `UseLoopPredicate`? It seems outdated / wrong.
> 
> Now is:
> `Generate a predicate to select fast/slow loop versions`
> 
> @chhagedorn do you have a good suggestion for what to put now?

Good catch! It could be similar but without mentioning profiling data:

Move checks with an uncommon trap out of loops.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/24248#discussion_r2016804557


More information about the hotspot-dev mailing list