On Mon, 8 Feb 2021 at 04:02, Richard Henderson
<richard.hender...@linaro.org> wrote:
>
> NEON has 3 instructions implementing this 4 argument operation,
> with each insn overlapping a different logical input onto the
> destination register.
>
> Signed-off-by: Richard Henderson <richard.hender...@linaro.org>
> @@ -2899,6 +2904,18 @@ static void tcg_out_vec_op(TCGContext *s, TCGOpcode 
> opc,
>          }
>          return;
>
> +    case INDEX_op_bitsel_vec:
> +        a3 = args[3];
> +        if (a0 == a3) {
> +            tcg_out_vreg3(s, INSN_VBIT, q, 0, a0, a2, a1);
> +        } else if (a0 == a2) {
> +            tcg_out_vreg3(s, INSN_VBIF, q, 0, a0, a3, a1);
> +        } else {
> +            tcg_out_mov(s, type, a0, a1);

Side note: aarch64 tcg guards this tcg_out_mov with "if (a0 != a1)",
which if I understand correctly is superfluous and could be removed.

> +            tcg_out_vreg3(s, INSN_VBSL, q, 0, a0, a2, a3);
> +        }
> +        return;
> +

Reviewed-by: Peter Maydell <peter.mayd...@linaro.org>

thanks
-- PMM

Reply via email to