[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 07/17] target/hexagon: Use float32_mul in helper_sfmpy
From: |
Richard Henderson |
Subject: |
[PATCH 07/17] target/hexagon: Use float32_mul in helper_sfmpy |
Date: |
Sun, 8 Dec 2024 16:48:34 -0600 |
There are no special cases for this instruction.
Remove internal_mpyf as unused.
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
---
target/hexagon/fma_emu.h | 1 -
target/hexagon/fma_emu.c | 8 --------
target/hexagon/op_helper.c | 2 +-
3 files changed, 1 insertion(+), 10 deletions(-)
diff --git a/target/hexagon/fma_emu.h b/target/hexagon/fma_emu.h
index 91591d6050..ad5df5d038 100644
--- a/target/hexagon/fma_emu.h
+++ b/target/hexagon/fma_emu.h
@@ -32,7 +32,6 @@ int32_t float32_getexp(float32 f32);
float32 infinite_float32(uint8_t sign);
float32 internal_fmafx(float32 a, float32 b, float32 c,
int scale, float_status *fp_status);
-float32 internal_mpyf(float32 a, float32 b, float_status *fp_status);
float64 internal_mpyhh(float64 a, float64 b,
unsigned long long int accumulated,
float_status *fp_status);
diff --git a/target/hexagon/fma_emu.c b/target/hexagon/fma_emu.c
index 05a56d8c10..35971b8b99 100644
--- a/target/hexagon/fma_emu.c
+++ b/target/hexagon/fma_emu.c
@@ -655,14 +655,6 @@ float32 internal_fmafx(float32 a, float32 b, float32 c,
int scale,
return accum_round_float32(result, fp_status);
}
-float32 internal_mpyf(float32 a, float32 b, float_status *fp_status)
-{
- if (float32_is_zero(a) || float32_is_zero(b)) {
- return float32_mul(a, b, fp_status);
- }
- return internal_fmafx(a, b, float32_zero, 0, fp_status);
-}
-
float64 internal_mpyhh(float64 a, float64 b,
unsigned long long int accumulated,
float_status *fp_status)
diff --git a/target/hexagon/op_helper.c b/target/hexagon/op_helper.c
index 90e7aaa097..b8b556f4c6 100644
--- a/target/hexagon/op_helper.c
+++ b/target/hexagon/op_helper.c
@@ -1157,7 +1157,7 @@ float32 HELPER(sfmpy)(CPUHexagonState *env, float32 RsV,
float32 RtV)
{
float32 RdV;
arch_fpop_start(env);
- RdV = internal_mpyf(RsV, RtV, &env->fp_status);
+ RdV = float32_mul(RsV, RtV, &env->fp_status);
arch_fpop_end(env);
return RdV;
}
--
2.43.0
- [RFC PATCH 00/17] softfloat, hexagon: Cleanup fmaf, Richard Henderson, 2024/12/08
- [PATCH 01/17] softfloat: Add float{16,32,64}_muladd_scalbn, Richard Henderson, 2024/12/08
- [PATCH 02/17] target/arm: Use float*_muladd_scalbn, Richard Henderson, 2024/12/08
- [PATCH 03/17] target/sparc: Use float*_muladd_scalbn, Richard Henderson, 2024/12/08
- [PATCH 04/17] softfloat: Remove float_muladd_halve_result, Richard Henderson, 2024/12/08
- [PATCH 07/17] target/hexagon: Use float32_mul in helper_sfmpy,
Richard Henderson <=
- [PATCH 05/17] softfloat: Add float_round_nearest_even_max, Richard Henderson, 2024/12/08
- [PATCH 06/17] softfloat: Add float_muladd_suppress_add_product_zero, Richard Henderson, 2024/12/08
- [PATCH 08/17] target/hexagon: Use float32_muladd for helper_sffma, Richard Henderson, 2024/12/08
- [PATCH 09/17] target/hexagon: Use float32_muladd for helper_sffms, Richard Henderson, 2024/12/08
- [PATCH 10/17] target/hexagon: Use float32_muladd_scalbn for helper_sffma_sc, Richard Henderson, 2024/12/08
- [PATCH 11/17] target/hexagon: Use float32_muladd for helper_sffm[as]_lib, Richard Henderson, 2024/12/08