RFR: 8308994: C2: Re-implement experimental post loop vectorization [v2]
Pengfei Li
pli at openjdk.org
Tue Jul 4 02:44:17 UTC 2023
On Wed, 28 Jun 2023 10:58:02 GMT, Emanuel Peter <epeter at openjdk.org> wrote:
>> Pengfei Li has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Address part of comments from Emanuel
>
> test/hotspot/jtreg/compiler/vectorization/runner/ArrayCopyTest.java line 82:
>
>> 80: @IR(applyIfCPUFeature = {"sve", "true"},
>> 81: applyIf = {"UseMaskedLoop", "true"},
>> 82: counts = {IRNode.LOOP_VECTOR_MASK, ">0"})
>
> We could also do this:
> If the CPU features do not support the features for `UseMaskedLoop`, then just put it back to `false`. That way, we do not have to check for the required cpu features. Because when the flag it `true`, we know the platform must also support the corresponding masked instructions.
Yes, thanks for this. I will clean up all the IR rules after JDK-8311130 and JDK-8309697 are done.
> test/hotspot/jtreg/compiler/vectorization/runner/ArrayInvariantFillTest.java line 69:
>
>> 67: @Test
>> 68: @IR(applyIfCPUFeatureOr = {"asimd", "true", "sse2", "true"},
>> 69: applyIf = {"OptimizeFill", "false"},
>
> This seems unrelated. Why did you have to add this?
Will cleanup this in JDK-8309697.
> test/hotspot/jtreg/compiler/vectorization/runner/VectorizationTestRunner.java line 84:
>
>> 82: TestFramework irTest = new TestFramework(klass);
>> 83: // Add extra VM options to enable more auto-vectorization chances
>> 84: irTest.addFlags("-XX:-OptimizeFill");
>
> Aha, you removed this too. Fair enough. But since the runner is currently requiring everything to be `flagless`, now I cannot actually force `-XX:-OptimizeFill` from the outside. And that means that potentially the tests are never actually run with `OptimizeFill` off, and we never actually can check the IR rules. We lose test coverage. That makes me a bit nervous.
>
> Suggestion: if tests actually require the flag off to execute the IR rule, then we should have two scenarios, one where the flag is on, and one when it is off.
Again, will cleanup this in JDK-8309697.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/14581#discussion_r1251412833
PR Review Comment: https://git.openjdk.org/jdk/pull/14581#discussion_r1251413032
PR Review Comment: https://git.openjdk.org/jdk/pull/14581#discussion_r1251413480
More information about the hotspot-compiler-dev
mailing list