[llvm] LoopVectorize: fix phi cost when it is scalar after vectorization (PR #74456)
Florian Hahn via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 11 07:39:06 PST 2024
https://github.com/fhahn commented:
> Thanks @fhahn: the patch is now ready. Your comment about replacing the `load` with the `store` makes sense, but can you clarify why you thought `-force-vector-width=4` would work? Also, if you know, what is the difference between sse and sse4.2 in the context of this test?
> Thanks @fhahn: the patch is now ready. Your comment about replacing the load with the store makes sense, but can you clarify why you thought -force-vector-width=4 would work? Also, if you know, what is the difference between sse and sse4.2 in the context of this test?
The reason for not vectorizing was probably the cost-model deciding it is not profitable; `-force-vector-width=4` side-steps that by forcing to vectorize with VF=4 if legally possible.
Not sure about `sse4.2`.
https://github.com/llvm/llvm-project/pull/74456
More information about the llvm-commits
mailing list