qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PULL 20/45] target/arm: Implement SME LD1, ST1


From: Peter Maydell
Subject: Re: [PULL 20/45] target/arm: Implement SME LD1, ST1
Date: Fri, 15 Jul 2022 17:07:56 +0100

On Mon, 11 Jul 2022 at 14:58, Peter Maydell <peter.maydell@linaro.org> wrote:
>
> From: Richard Henderson <richard.henderson@linaro.org>
>
> We cannot reuse the SVE functions for LD[1-4] and ST[1-4],
> because those functions accept only a Zreg register number.
> For SME, we want to pass a pointer into ZA storage.
>
> Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
> Message-id: 20220708151540.18136-21-richard.henderson@linaro.org
> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
> ---
>  target/arm/helper-sme.h    |  82 +++++
>  target/arm/sme.decode      |   9 +
>  target/arm/sme_helper.c    | 595 +++++++++++++++++++++++++++++++++++++
>  target/arm/translate-sme.c |  70 +++++
>  4 files changed, 756 insertions(+)
>


> +DO_LD(q, _be, MO_128)
> +DO_LD(q, _le, MO_128)

Coverity complains that these uses of MO_128 result in an
array overrun for the pred_esz_masks[] array, because e.g.
sme_ld1() calls sve_cont_ldst_elements() calls which uses esz
as an index into pred_esz_masks[]. (Multiple coverity issues,
affects both loads and stores.)

Do we just need to add an extra entry to the array for
MO_128 (presumably 0x0001000100010001ull) ?

thanks
-- PMM



reply via email to

[Prev in Thread] Current Thread [Next in Thread]