[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 17/20] target/arm: Fix sve_punpk_p vs odd vector lengths
From: |
Peter Maydell |
Subject: |
Re: [PATCH 17/20] target/arm: Fix sve_punpk_p vs odd vector lengths |
Date: |
Tue, 25 Aug 2020 14:53:26 +0100 |
On Sat, 15 Aug 2020 at 02:32, Richard Henderson
<richard.henderson@linaro.org> wrote:
>
> Wrote too much with punpk1 with vl % 512 != 0.
>
> Reported-by: Laurent Desnogues <laurent.desnogues@gmail.com>
> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
> ---
> target/arm/sve_helper.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/target/arm/sve_helper.c b/target/arm/sve_helper.c
> index b8651ae173..c983cd4356 100644
> --- a/target/arm/sve_helper.c
> +++ b/target/arm/sve_helper.c
> @@ -2104,11 +2104,11 @@ void HELPER(sve_punpk_p)(void *vd, void *vn, uint32_t
> pred_desc)
> high = oprsz >> 1;
> }
>
> - if ((high & 3) == 0) {
> + if ((oprsz & 7) == 0) {
> uint32_t *n = vn;
> high >>= 2;
>
> - for (i = 0; i < DIV_ROUND_UP(oprsz, 8); i++) {
> + for (i = 0; i < oprsz / 8; i++) {
> uint64_t nn = n[H4(high + i)];
> d[i] = expand_bits(nn, 0);
> }
> --
> 2.25.1
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
thanks
-- PMM
- Re: [PATCH 20/20] target/arm: Convert sq{, r}dmulh to gvec for aa64 advsimd, (continued)
- [PATCH 13/20] target/arm: Tidy SVE tszimm shift formats, Richard Henderson, 2020/08/15
- [PATCH 09/20] target/arm: Merge helper_sve_clr_* and helper_sve_movz_*, Richard Henderson, 2020/08/15
- [PATCH 07/20] target/arm: Use tcg_gen_gvec_bitsel for trans_SEL_pppp, Richard Henderson, 2020/08/15
- [PATCH 08/20] target/arm: Split out gen_gvec_ool_zzzp, Richard Henderson, 2020/08/15
- [PATCH 17/20] target/arm: Fix sve_punpk_p vs odd vector lengths, Richard Henderson, 2020/08/15
- Re: [PATCH 17/20] target/arm: Fix sve_punpk_p vs odd vector lengths,
Peter Maydell <=
- [PATCH 19/20] target/arm: Convert integer multiply-add (indexed) to gvec for aa64 advsimd, Richard Henderson, 2020/08/15
- [PATCH 11/20] target/arm: Split out gen_gvec_ool_zzz, Richard Henderson, 2020/08/15
- [PATCH 04/20] target/arm: Rearrange {sve,fp}_check_access assert, Richard Henderson, 2020/08/15
- [PATCH 15/20] target/arm: Fix sve_uzp_p vs odd vector lengths, Richard Henderson, 2020/08/15