[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [RFC v2 11/15] target/riscv: rvb: generalized reverse
From: |
Richard Henderson |
Subject: |
Re: [RFC v2 11/15] target/riscv: rvb: generalized reverse |
Date: |
Wed, 16 Dec 2020 10:52:28 -0600 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 |
On 12/15/20 8:01 PM, frank.chang@sifive.com wrote:
> +target_ulong HELPER(grevw)(target_ulong rs1, target_ulong rs2)
> +{
> + return do_grev(rs1, rs2, 32);
> +}
> +
> +#endif
> +
> diff --git a/target/riscv/helper.h b/target/riscv/helper.h
Stray whitespace at the end of the file.
checkpatch or git should have complained about this.
> +static bool gen_grevi(DisasContext *ctx, arg_grevi *a)
> +{
> + TCGv source1 = tcg_temp_new();
> + TCGv source2;
> +
> + gen_get_gpr(source1, a->rs1);
> +
> + if (a->shamt == (TARGET_LONG_BITS - 8)) {
> + /* rev8, byte swaps */
> +#ifdef TARGET_RISCV32
> + tcg_gen_bswap32_tl(source1, source1);
> +#else
> + tcg_gen_bswap64_tl(source1, source1);
> +#endif
I should add a tcg_gen_bswap_tl define so that this ifdef is not necessary.
For the to-do list...
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
r~
- Re: [RFC v2 06/15] target/riscv: rvb: min/max instructions, (continued)
- [RFC v2 07/15] target/riscv: rvb: sign-extend instructions, frank . chang, 2020/12/15
- [RFC v2 08/15] target/riscv: rvb: single-bit instructions, frank . chang, 2020/12/15
- [RFC v2 09/15] target/riscv: rvb: shift ones, frank . chang, 2020/12/15
- [RFC v2 10/15] target/riscv: rvb: rotate (left/right), frank . chang, 2020/12/15
- [RFC v2 11/15] target/riscv: rvb: generalized reverse, frank . chang, 2020/12/15
- Re: [RFC v2 11/15] target/riscv: rvb: generalized reverse,
Richard Henderson <=
- [RFC v2 12/15] target/riscv: rvb: generalized or-combine, frank . chang, 2020/12/15
- [RFC v2 13/15] target/riscv: rvb: address calculation, frank . chang, 2020/12/15
- [RFC v2 14/15] target/riscv: rvb: add/sub with postfix zero-extend, frank . chang, 2020/12/15
- [RFC v2 15/15] target/riscv: rvb: support and turn on B-extension from command line, frank . chang, 2020/12/15