[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v4 3/5] target/riscv: add vector index load and store instruc
From: |
Richard Henderson |
Subject: |
Re: [PATCH v4 3/5] target/riscv: add vector index load and store instructions |
Date: |
Thu, 27 Feb 2020 11:49:01 -0800 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 |
On 2/25/20 2:35 AM, LIU Zhiwei wrote:
> +vsxb_v ... 011 . ..... ..... 000 ..... 0100111 @r_nfvm
> +vsxh_v ... 011 . ..... ..... 101 ..... 0100111 @r_nfvm
> +vsxw_v ... 011 . ..... ..... 110 ..... 0100111 @r_nfvm
> +vsxe_v ... 011 . ..... ..... 111 ..... 0100111 @r_nfvm
> +vsuxb_v ... 111 . ..... ..... 000 ..... 0100111 @r_nfvm
> +vsuxh_v ... 111 . ..... ..... 101 ..... 0100111 @r_nfvm
> +vsuxw_v ... 111 . ..... ..... 110 ..... 0100111 @r_nfvm
> +vsuxe_v ... 111 . ..... ..... 111 ..... 0100111 @r_nfvm
These can be merged, with a comment, like
# Vector ordered-indexed and unordered-indexed store insns.
vsxb_v ... -11 . ..... ..... 000 ..... 0100111 @r_nfvm
which means you don't need these:
> +static bool trans_vsuxb_v(DisasContext *s, arg_rnfvm* a)
> +{
> + return trans_vsxb_v(s, a);
> +}
> +
> +static bool trans_vsuxh_v(DisasContext *s, arg_rnfvm* a)
> +{
> + return trans_vsxh_v(s, a);
> +}
> +
> +static bool trans_vsuxw_v(DisasContext *s, arg_rnfvm* a)
> +{
> + return trans_vsxw_v(s, a);
> +}
> +
> +static bool trans_vsuxe_v(DisasContext *s, arg_rnfvm* a)
> +{
> + return trans_vsxe_v(s, a);
> +}
> +static inline void vext_ld_index(void *vd, void *v0, target_ulong base,
> + void *vs2, CPURISCVState *env, uint32_t desc,
> + vext_get_index_addr get_index_addr,
> + vext_ld_elem_fn ld_elem,
> + vext_ld_clear_elem clear_elem,
> + uint32_t esz, uint32_t msz, uintptr_t ra)
Similar comment about merging vext_ld_index and vext_st_index.
r~
- [PATCH v4 0/5] target/riscv: support vector extension part 2, LIU Zhiwei, 2020/02/25
- [PATCH v4 4/5] target/riscv: add fault-only-first unit stride load, LIU Zhiwei, 2020/02/25
- [PATCH v4 2/5] target/riscv: add vector stride load and store instructions, LIU Zhiwei, 2020/02/25
- [PATCH v4 3/5] target/riscv: add vector index load and store instructions, LIU Zhiwei, 2020/02/25
- Re: [PATCH v4 3/5] target/riscv: add vector index load and store instructions,
Richard Henderson <=
- [PATCH v4 1/5] target/riscv: add vector unit stride load and store instructions, LIU Zhiwei, 2020/02/25
- [PATCH v4 5/5] target/riscv: add vector amo operations, LIU Zhiwei, 2020/02/25