[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 10/11] target/mips: Do not check MSACSR_FS_MASK in update_msacsr
From: |
Richard Henderson |
Subject: |
[PATCH 10/11] target/mips: Do not check MSACSR_FS_MASK in update_msacsr |
Date: |
Wed, 26 May 2021 21:14:04 -0700 |
The FS_MASK has already been taken into account with
restore_msa_fp_status. The definition of iflush and
oflush is that we *have* flushed to zero.
Cc: Philippe Mathieu-Daudé <f4bug@amsat.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
---
target/mips/tcg/msa_helper.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/target/mips/tcg/msa_helper.c b/target/mips/tcg/msa_helper.c
index 2f89abe166..ffe6e630ed 100644
--- a/target/mips/tcg/msa_helper.c
+++ b/target/mips/tcg/msa_helper.c
@@ -6225,8 +6225,7 @@ static int update_msacsr(CPUMIPSState *env, int action,
int denormal)
enable = GET_FP_ENABLE(env->active_tc.msacsr) | FP_UNIMPLEMENTED;
/* Set Inexact (I) when flushing inputs to zero */
- if ((ieee_exception_flags & float_flag_iflush_denormal) &&
- (env->active_tc.msacsr & MSACSR_FS_MASK) != 0) {
+ if (ieee_exception_flags & float_flag_iflush_denormal) {
if (action & CLEAR_IS_INEXACT) {
mips_exception_flags &= ~FP_INEXACT;
} else {
@@ -6235,8 +6234,7 @@ static int update_msacsr(CPUMIPSState *env, int action,
int denormal)
}
/* Set Inexact (I) and Underflow (U) when flushing outputs to zero */
- if ((ieee_exception_flags & float_flag_oflush_denormal) &&
- (env->active_tc.msacsr & MSACSR_FS_MASK) != 0) {
+ if (ieee_exception_flags & float_flag_oflush_denormal) {
mips_exception_flags |= FP_INEXACT;
if (action & CLEAR_FS_UNDERFLOW) {
mips_exception_flags &= ~FP_UNDERFLOW;
--
2.25.1
- [PATCH 07/11] target/rx: Use FloatRoundMode in helper_set_fpsw, (continued)
- [PATCH 07/11] target/rx: Use FloatRoundMode in helper_set_fpsw, Richard Henderson, 2021/05/27
- [PATCH 02/11] softfloat: Rename float_flag_output_denormal to float_flag_oflush_denormal, Richard Henderson, 2021/05/27
- [PATCH 06/11] target/rx: Handle the FPSW.DN bit in helper_set_fpsw, Richard Henderson, 2021/05/27
- [PATCH 08/11] target/rx: Fix setting of FPSW.CE, Richard Henderson, 2021/05/27
- [PATCH 09/11] target/mips: Drop inline markers from msa_helper.c, Richard Henderson, 2021/05/27
- [PATCH 10/11] target/mips: Do not check MSACSR_FS_MASK in update_msacsr,
Richard Henderson <=
- [PATCH 04/11] softfloat: Introduce float_flag_result_denormal, Richard Henderson, 2021/05/27
- [PATCH 05/11] target/i386: Use float_flag_inorm_denormal, Richard Henderson, 2021/05/27
- [PATCH 11/11] target/mips: Drop denormal operand to update_msacsr, Richard Henderson, 2021/05/27