[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 15/76] target/arm: Use fp_status_f16_a64 in AArch64-only helpers
From: |
Peter Maydell |
Subject: |
[PATCH 15/76] target/arm: Use fp_status_f16_a64 in AArch64-only helpers |
Date: |
Fri, 24 Jan 2025 16:27:35 +0000 |
We directly use fp_status_f16 in a handful of helpers that are
AArch64-specific; switch to fp_status_f16_a64 for these.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
target/arm/tcg/sme_helper.c | 4 ++--
target/arm/tcg/vec_helper.c | 8 ++++----
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/target/arm/tcg/sme_helper.c b/target/arm/tcg/sme_helper.c
index 2aad00d3ad9..727c085f374 100644
--- a/target/arm/tcg/sme_helper.c
+++ b/target/arm/tcg/sme_helper.c
@@ -1038,12 +1038,12 @@ void HELPER(sme_fmopa_h)(void *vza, void *vzn, void
*vzm, void *vpn,
float_status fpst_odd, fpst_std, fpst_f16;
/*
- * Make copies of fp_status and fp_status_f16, because this operation
+ * Make copies of the fp status fields we use, because this operation
* does not update the cumulative fp exception status. It also
* produces default NaNs. We also need a second copy of fp_status with
* round-to-odd -- see above.
*/
- fpst_f16 = env->vfp.fp_status_f16;
+ fpst_f16 = env->vfp.fp_status_f16_a64;
fpst_std = env->vfp.fp_status_a64;
set_default_nan_mode(true, &fpst_std);
set_default_nan_mode(true, &fpst_f16);
diff --git a/target/arm/tcg/vec_helper.c b/target/arm/tcg/vec_helper.c
index aaad947e506..3fbca8bc8bf 100644
--- a/target/arm/tcg/vec_helper.c
+++ b/target/arm/tcg/vec_helper.c
@@ -2067,7 +2067,7 @@ void HELPER(gvec_fmlal_a64)(void *vd, void *vn, void *vm,
CPUARMState *env, uint32_t desc)
{
do_fmlal(vd, vn, vm, &env->vfp.fp_status_a64, desc,
- get_flush_inputs_to_zero(&env->vfp.fp_status_f16));
+ get_flush_inputs_to_zero(&env->vfp.fp_status_f16_a64));
}
void HELPER(sve2_fmlal_zzzw_s)(void *vd, void *vn, void *vm, void *va,
@@ -2077,7 +2077,7 @@ void HELPER(sve2_fmlal_zzzw_s)(void *vd, void *vn, void
*vm, void *va,
uint16_t negn = extract32(desc, SIMD_DATA_SHIFT, 1) << 15;
intptr_t sel = extract32(desc, SIMD_DATA_SHIFT + 1, 1) * sizeof(float16);
float_status *status = &env->vfp.fp_status_a64;
- bool fz16 = get_flush_inputs_to_zero(&env->vfp.fp_status_f16);
+ bool fz16 = get_flush_inputs_to_zero(&env->vfp.fp_status_f16_a64);
for (i = 0; i < oprsz; i += sizeof(float32)) {
float16 nn_16 = *(float16 *)(vn + H1_2(i + sel)) ^ negn;
@@ -2129,7 +2129,7 @@ void HELPER(gvec_fmlal_idx_a64)(void *vd, void *vn, void
*vm,
CPUARMState *env, uint32_t desc)
{
do_fmlal_idx(vd, vn, vm, &env->vfp.fp_status_a64, desc,
- get_flush_inputs_to_zero(&env->vfp.fp_status_f16));
+ get_flush_inputs_to_zero(&env->vfp.fp_status_f16_a64));
}
void HELPER(sve2_fmlal_zzxw_s)(void *vd, void *vn, void *vm, void *va,
@@ -2140,7 +2140,7 @@ void HELPER(sve2_fmlal_zzxw_s)(void *vd, void *vn, void
*vm, void *va,
intptr_t sel = extract32(desc, SIMD_DATA_SHIFT + 1, 1) * sizeof(float16);
intptr_t idx = extract32(desc, SIMD_DATA_SHIFT + 2, 3) * sizeof(float16);
float_status *status = &env->vfp.fp_status_a64;
- bool fz16 = get_flush_inputs_to_zero(&env->vfp.fp_status_f16);
+ bool fz16 = get_flush_inputs_to_zero(&env->vfp.fp_status_f16_a64);
for (i = 0; i < oprsz; i += 16) {
float16 mm_16 = *(float16 *)(vm + i + idx);
--
2.34.1
- [PATCH 07/76] target/arm: Use vfp.fp_status_a64 in A64-only helper functions, (continued)
- [PATCH 17/76] target/arm: Use FPST_FPCR_F16_A64 in A64 decoder, Peter Maydell, 2025/01/24
- [PATCH 22/76] fpu: Add float_class_denormal, Peter Maydell, 2025/01/24
- [PATCH 21/76] fpu: Fix a comment in softfloat-types.h, Peter Maydell, 2025/01/24
- [PATCH 15/76] target/arm: Use fp_status_f16_a64 in AArch64-only helpers,
Peter Maydell <=
- [PATCH 24/76] fpu: allow flushing of output denormals to be after rounding, Peter Maydell, 2025/01/24
[PATCH 16/76] target/arm: Use FPST_FPCR_F16_A32 in A32 decoder, Peter Maydell, 2025/01/24
[PATCH 14/76] target/arm: Use fp_status_f16_a32 in AArch32-only helpers, Peter Maydell, 2025/01/24