We can optimize (vec_cond eq/ne vec_cond) when vec_cond is a
result of (vec CMP vec). The optimization is because of the
observation that in vec_cond, (-1 != 0) is true. So, we can
generate vec_cond of xor of vec resulting in a single
VEC_COND_EXPR instead of 3.
The patch adds match pattern for ve
On Fri, Jun 21, 2024 at 9:12 AM Eikansh Gupta wrote:
>
> We can optimize (vec_cond eq/ne vec_cond) when vec_cond is a
> result of (vec CMP vec). The optimization is because of the
> observation that in vec_cond, (-1 != 0) is true. So, we can
> generate vec_cond of xor of vec resulting in a single
On Fri, Jun 21, 2024 at 1:04 AM Richard Biener
wrote:
>
> On Fri, Jun 21, 2024 at 9:12 AM Eikansh Gupta
> wrote:
> >
> > We can optimize (vec_cond eq/ne vec_cond) when vec_cond is a
> > result of (vec CMP vec). The optimization is because of the
> > observation that in vec_cond, (-1 != 0) is tru