RFR: 8320725: C2: Add "requires_strict_order" flag for floating-point add-reduction [v10]

Emanuel Peter epeter at openjdk.org
Thu May 30 12:22:07 UTC 2024


On Thu, 30 May 2024 12:01:37 GMT, Bhavana Kilambi <bkilambi at openjdk.org> wrote:

>> test/hotspot/jtreg/compiler/c2/irTests/TestVectorFPReduction.java line 67:
>> 
>>> 65:     @IR(applyIfCPUFeatureAnd = {"asimd", "true", "sve", "false"}, failOn = {IRNode.ADD_REDUCTION_VD})
>>> 66:     @IR(applyIfCPUFeature = {"sve", "true"}, counts = {"requires_strict_order", ">=1", IRNode.ADD_REDUCTION_VD, ">=1"},
>>> 67:         failOn = {"no_strict_order"}, phase = CompilePhase.PRINT_IDEAL)
>> 
>> Also: I realize that you only check for `asimd / sve` features. Can you also apply it for avx features?
>
> I am not sure which specific avx/sse features/versions support these operations. Is it ok to add - 
> `applyIfCPUFeatureOr = {"sve", "true", "avx", "true"}` ? 
> or maybe anyone with x86 knowledge who would work on adding strict ordering conditions in their backend (after this patch is merged) can also modify these two testcases accordingly? Also in the vectorapi case, I have included only specific shapes of Vectors where the Reduction nodes would be generated on aarch64. It may or may not be the case for x86 and they might have to add more tests accordingly.

I don't fully know what is ok. I usually check this experimentally, and  just put the lowest feature that makes my test pass.

Do you have access to any x86 machine you could test this on?

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

PR Review Comment: https://git.openjdk.org/jdk/pull/18034#discussion_r1620604302


More information about the hotspot-compiler-dev mailing list