RFR: 8298935: fix cyclic dependency bug in create_pack logic in SuperWord::find_adjacent_refs [v15]
Emanuel Peter
epeter at openjdk.org
Thu Mar 2 16:00:47 UTC 2023
On Thu, 2 Mar 2023 07:09:46 GMT, Emanuel Peter <epeter at openjdk.org> wrote:
>> test/hotspot/jtreg/compiler/loopopts/superword/TestDependencyOffsets.java line 881:
>>
>>> 879: // cpu: sse4.1 to avx -> vector_width: 16 -> elements in vector: 4
>>> 880: // positive byte_offset 4 can lead to cyclic dependency
>>> 881: @IR(counts = {IRNode.LOAD_VECTOR, "> 0", IRNode.MUL_V, "> 0", IRNode.STORE_VECTOR, "> 0"},
>>
>> Needs to fix the test generation script. This IR rule looks incorrect since there is a valid dependency with distance 1.
>
> @jatin-bhateja I think the IR rule is just ineffective. I have the following condition in it that will never be met:
> `applyIfAnd = {"MaxVectorSize", ">= 8", "MaxVectorSize", "<= 4"},`
> The `<= 4` must hold so that `byte_offset <= MaxVectorSize`, and so the cyclical dependency would not happen. But `>= 8` must hold so that two ints fit in a vector, so that we even vectorize.
>
> I could improve the script and filter out such ineffective IR rules. Not sure if that is worth it though.
I fixed my script, it should now compute the ranges correctly, and not add IR rules with impossible ranges.
-------------
PR: https://git.openjdk.org/jdk/pull/12350
More information about the hotspot-compiler-dev
mailing list