qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH 5/5] target/arm: Make isar_feature_aa32_fp16_arith() handle M


From: Richard Henderson
Subject: Re: [PATCH 5/5] target/arm: Make isar_feature_aa32_fp16_arith() handle M-profile
Date: Fri, 11 Sep 2020 12:32:23 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0

On 9/10/20 10:38 AM, Peter Maydell wrote:
> +static inline bool isar_feature_aa32_mprofile(const ARMISARegisters *id)
> +{
> +    return FIELD_EX32(id->id_pfr1, ID_PFR1, MPROGMOD) != 0;
> +}
> +
>  static inline bool isar_feature_aa32_fp16_arith(const ARMISARegisters *id)
>  {
> -    return FIELD_EX32(id->mvfr1, MVFR1, FPHP) >= 3;
> +    /* Sadly this is encoded differently for A-profile and M-profile */
> +    if (isar_feature_aa32_mprofile(id)) {
> +        return FIELD_EX32(id->mvfr1, MVFR1, FP16) > 0;
> +    } else {
> +        return FIELD_EX32(id->mvfr1, MVFR1, FPHP) >= 3;
> +    }

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>

r~




reply via email to

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