RFR: 8350177: C2 SuperWord: Integer.numberOfLeadingZeros, numberOfTrailingZeros, reverse and bitCount have input types wrongly turncated for byte and short

Jasmine Karthikeyan jkarthikeyan at openjdk.org
Wed Jun 25 06:03:29 UTC 2025


On Tue, 24 Jun 2025 16:27:29 GMT, Emanuel Peter <epeter at openjdk.org> wrote:

>> @eme64 I've updated the patch to address the comments, let me know what you think!
>> 
>> @mur47x111 Thanks for the comment! I've merged from master.
>
> @jaskarth I just checked the results, and there is a series of failing tests.
> 
> ------------------------
> `compiler/c2/Test6958485.java`
> 
> Flags: `-server -Xcomp` or `-XX:+UnlockExperimentalVMOptions -XX:PerMethodSpecTrapLimit=0 -XX:PerMethodTrapLimit=0`.
> 
> `#  assert(false) failed: Unexpected node in SuperWord truncation: Conv2B`
> 
> --------------------------
> 
> `compiler/intrinsics/TestDoubleIsInfinite.java` -> D
> `compiler/intrinsics/TestFloatIsInfinite.java` -> F
> 
> Flags: `-XX:UseAVX=3` or `-XX:-TieredCompilation -XX:+StressReflectiveCode -XX:-ReduceInitialCardMarks -XX:-ReduceBulkZeroing -XX:-ReduceFieldZeroing` ... not sure if any are necessary actually.
> 
> `#  assert(false) failed: Unexpected node in SuperWord truncation: IsInfiniteD`
> and
> `#  assert(false) failed: Unexpected node in SuperWord truncation: IsInfiniteF`
> 
> -----------------------------
> 
> `jdk/incubator/vector/Byte128VectorTests.java` (same issue with all related vector tests, just reporting one here)
> 
> Flag: `-XX:UseAVX=2`
> 
> `#  assert(false) failed: Unexpected node in SuperWord truncation: AddReductionVI`

@eme64 Thanks for the test results! I've added these nodes to the non-truncating list, as well as the other reduction nodes that showed up when running the vector tests.

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

PR Comment: https://git.openjdk.org/jdk/pull/25440#issuecomment-3003445470


More information about the hotspot-compiler-dev mailing list