RFR: 8347645: C2: XOR bounded value handling blocks constant folding [v4]

Emanuel Peter epeter at openjdk.org
Thu Jan 23 08:25:49 UTC 2025


On Thu, 23 Jan 2025 00:24:26 GMT, Chen Liang <liach at openjdk.org> wrote:

>> Johannes Graham has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   fix test names
>
> src/hotspot/share/opto/addnode.cpp line 1013:
> 
>> 1011:     if( r0 == TypeInt::BOOL && ( r1 == TypeInt::ONE
>> 1012:                                  || r1 == TypeInt::BOOL))
>> 1013:       return TypeInt::BOOL;
> 
> @eme64 Can you verify that it's right for the bounded value handling to come before this boolean range checking, and the bounded value handling is still correct if one of the input arguments is constant?

@j3graham can you give us an explanation here?

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

PR Review Comment: https://git.openjdk.org/jdk/pull/23089#discussion_r1926546081


More information about the hotspot-compiler-dev mailing list