[PATCH] D126363: [VPlan, VP] 1/4 Introduce new recipes to support predicated vectorization

Alexey Bataev via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed May 25 07:33:35 PDT 2022


ABataev added a comment.

In D126363#3537197 <https://reviews.llvm.org/D126363#3537197>, @simoll wrote:

> In D126363#3536686 <https://reviews.llvm.org/D126363#3536686>, @ABataev wrote:
>
>> Hi Simon, did you think about making EVL a member of VPlan just like TripCount? In this case we might be not needed lots of these new classes.
>
> Hi Alexey! The EVL behaves like a mask and less like the TripCount. When used for tail predication, the value of EVL still depends on the current vector iteration and needs to be computed in the vector loop.

But you can also treat it as an effective vector factor and use it similarly to VectorTripCount. Introducing new nodes just to add an extra operand EVL does not look necessary

> Also - depending on you target - setting EVL is relatively light weight and instructions in the vector loop may have different EVLs in the future.

In what case this can happen? I believe for unrolled loop? But it can be handled by the VPTransformState::Part and VPTransformState::set/get functions.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D126363



More information about the llvm-commits mailing list