[PATCH] D150851: [LoopVectorize] Vectorize select-cmp reduction pattern for increasing integer induction variable

Mel Chen via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 10 02:59:00 PDT 2023


Mel-Chen added a comment.

In D150851#4480316 <https://reviews.llvm.org/D150851#4480316>, @artagnon wrote:

>>> Would be good to try and find more accurate names than using `Select*Cmp` combinations. A Compare-Select pattern is also used in the existing Min/Max reduction, but has a much better name.
>
> I agree with @Ayal: I also got confused by the `SelectCmp` naming convention initially. Perhaps `[I|F]AnyOfInv`, `[I|F]AnyOfInc`, and `[I|F]AnyOfDec`, and rename the corresponding function `isAnyOfReduction`? I don't have a strong preference for the rename.

My opinion is:
Select[I|F]Cmp --> [I|F]AnyOf
SelectIV[I|F]Cmp --> [I|F]FindLastIV or [I|F]FindLastIncIV

About the function name,  I lean towards not renaming it, or renaming it to more easily understandable names like `conditional select`, `conditional assignment`, and so on.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D150851/new/

https://reviews.llvm.org/D150851



More information about the llvm-commits mailing list