[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 02/11] softfloat: Inline pickNaNMulAdd
From: |
Peter Maydell |
Subject: |
Re: [PATCH 02/11] softfloat: Inline pickNaNMulAdd |
Date: |
Thu, 5 Dec 2024 13:30:23 +0000 |
On Tue, 3 Dec 2024 at 20:39, Richard Henderson
<richard.henderson@linaro.org> wrote:
>
> Inline pickNaNMulAdd into its only caller. This makes
> one assert redundant with the immediately preceding IF.
>
> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
> ---
> fpu/softfloat-parts.c.inc | 35 +++++++++++++++++++++-
> fpu/softfloat-specialize.c.inc | 54 ----------------------------------
> 2 files changed, 34 insertions(+), 55 deletions(-)
> -/*----------------------------------------------------------------------------
> -| Select which NaN to propagate for a three-input operation.
> -| For the moment we assume that no CPU needs the 'larger significand'
> -| information.
> -| Return values : 0 : a; 1 : b; 2 : c; 3 : default-NaN
> -*----------------------------------------------------------------------------*/
> -static int pickNaNMulAdd(FloatClass a_cls, FloatClass b_cls, FloatClass
> c_cls,
> - bool infzero, bool have_snan, float_status *status)
> -{
> - FloatClass cls[3] = { a_cls, b_cls, c_cls };
> - Float3NaNPropRule rule = status->float_3nan_prop_rule;
> - int which;
> -
> - /*
> - * We guarantee not to require the target to tell us how to
> - * pick a NaN if we're always returning the default NaN.
> - * But if we're not in default-NaN mode then the target must
> - * specify.
> - */
This comment has got lost in the refactoring. Since it's
documenting a guarantee we make to the target, I think
it's worth retaining.
thanks
-- PMM
- [PATCH 04/11] softfloat: Remove which from parts_pick_nan_muladd, (continued)
- [PATCH 04/11] softfloat: Remove which from parts_pick_nan_muladd, Richard Henderson, 2024/12/03
- [PATCH 08/11] softfloat: Inline pickNaN, Richard Henderson, 2024/12/03
- [PATCH 09/11] softfloat: Share code between parts_pick_nan cases, Richard Henderson, 2024/12/03
- [PATCH 06/11] softfloat: Move propagateFloatx80NaN to softfloat.c, Richard Henderson, 2024/12/03
- [PATCH 02/11] softfloat: Inline pickNaNMulAdd, Richard Henderson, 2024/12/03
- [PATCH 07/11] softfloat: Use parts_pick_nan in propagateFloatx80NaN, Richard Henderson, 2024/12/03
- [PATCH 10/11] softfloat: Sink frac_cmp in parts_pick_nan until needed, Richard Henderson, 2024/12/03
- [PATCH 11/11] softfloat: Replace WHICH with RET in parts_pick_nan, Richard Henderson, 2024/12/03
- Re: [PATCH for-10.0 00/11] fpu: pickNaN follow ups, Peter Maydell, 2024/12/10