RFR: 8327381 Refactor type-improving transformations in BoolNode::Ideal to BoolNode::Value [v4]

Emanuel Peter epeter at openjdk.org
Tue Mar 26 06:36:22 UTC 2024


On Mon, 25 Mar 2024 16:51:29 GMT, Kangcheng Xu <kxu at openjdk.org> wrote:

>> test/hotspot/jtreg/compiler/c2/irTests/TestBoolNodeGvn.java line 58:
>> 
>>> 56:                 & !(Integer.compareUnsigned((m & x), m) > 0)
>>> 57:                 & Integer.compareUnsigned((x & m), m + 1) < 0
>>> 58:                 & Integer.compareUnsigned((m & x), m + 1) < 0;
>> 
>> For easier reading, I would have put the `&` at the end of the line.
>> Btw: is this supposed to be a bitwise or a binary and?
>
> Done. I'm intentionally using bitwise `&` here so that the compiler doesn't short-circuits on conditions with `&&`.  We wish to test all for correctness.

The indentation is still not right, now it looks like the first `!` might apply to all lines.
My "short-circuit" you mean exit after checking the first term, rather than evaluating all? Ok, I get that, makes sense.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/18198#discussion_r1538657223


More information about the hotspot-compiler-dev mailing list