RFR: 8347459: C2: missing transformation for chain of shifts/multiplications by constants [v9]
Marc Chevalier
duke at openjdk.org
Tue Mar 11 10:09:38 UTC 2025
On Mon, 10 Mar 2025 15:33:48 GMT, Emanuel Peter <epeter at openjdk.org> wrote:
>> Marc Chevalier has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Random testing, trying...
>
> src/hotspot/share/opto/memnode.cpp line 3549:
>
>> 3547: // Let's also remember that conIL < 32 since (x << 33) is simplified into (x << 1)
>> 3548: // and (x << 31) << 2 is simplified into 0. This means that in any case, after the
>> 3549: // left shift, we always have at least one bit of the original v.
>
> What does `original v` refer to? Is this the same as the `X` and the `valIn`?
rephrased
> src/hotspot/share/opto/memnode.cpp line 3577:
>
>> 3575: // +------------------+---------+-----+
>> 3576: // 31 8 7 2 1 0
>> 3577: // The non-rejected bits are the 8 lower one of (v << conIL - conIR).
>
> Suggestion:
>
> // The non-rejected bits are the 8 lower ones of (v << conIL - conIR).
nice.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/23728#discussion_r1988873142
PR Review Comment: https://git.openjdk.org/jdk/pull/23728#discussion_r1988872799
More information about the hotspot-compiler-dev
mailing list