RFR: 8369902: C2 SuperWord: wrong result because filterin NaN instead of zero in MemPointerParser::canonicalize_raw_summands [v2]

Emanuel Peter epeter at openjdk.org
Mon Oct 20 05:53:56 UTC 2025


On Fri, 17 Oct 2025 13:09:49 GMT, Manuel Hässig <mhaessig at openjdk.org> wrote:

>> Emanuel Peter has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Update test/hotspot/jtreg/compiler/loopopts/superword/TestMemorySegmentFilterSummands.java
>>   
>>   Co-authored-by: Manuel Hässig <manuel at haessig.org>
>
> test/hotspot/jtreg/compiler/loopopts/superword/TestMemorySegmentFilterSummands.java line 71:
> 
>> 69:                        new Scenario(1, "-XX:+AlignVector", "-XX:-ShortRunningLongLoop"),
>> 70:                        new Scenario(2, "-XX:-AlignVector", "-XX:+ShortRunningLongLoop"),
>> 71:                        new Scenario(3, "-XX:+AlignVector", "-XX:+ShortRunningLongLoop"));
> 
> That might be the perfect opportunity to break out the cross-product scenario:
> Suggestion:
> 
>         f.addCrossProductScenarios(Set.of("-XX:-AlignVector", "-XX:+AlignVector"),
>                                    Set.of("-XX:-ShortRunningLongLoop", "-XX:+ShortRunningLoop);

Nice idea, let me try that :)

> test/hotspot/jtreg/compiler/loopopts/superword/TestMemorySegmentFilterSummands.java line 82:
> 
>> 80:         applyIfPlatform = {"64-bit", "true"},
>> 81:         applyIf = {"AlignVector", "false"},
>> 82:         applyIfCPUFeatureOr = {"avx", "true", "asimd", "true"})
> 
> I always forget what the best practice is regarding detecting CPU features to not break the CIs of riscv and others. But this should be fine, since you are matching for the CPU features, right?

Yes, I do this everywhere, and have not gotten any complaints ;)

I think we first check CPU features / platform, and only then flags.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/27848#discussion_r2443865579
PR Review Comment: https://git.openjdk.org/jdk/pull/27848#discussion_r2443865330


More information about the hotspot-compiler-dev mailing list