[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v5 14/22] target/mips: fpu: Demacro RINT.<D|S>
From: |
Aleksandar Markovic |
Subject: |
[PATCH v5 14/22] target/mips: fpu: Demacro RINT.<D|S> |
Date: |
Mon, 18 May 2020 21:41:41 +0200 |
This is just a cosmetic change to enable tools like gcov, gdb,
callgrind, etc. to better display involved source code.
Reviewed-by: Aleksandar Rikalo <address@hidden>
Signed-off-by: Aleksandar Markovic <address@hidden>
---
target/mips/fpu_helper.c | 20 ++++++++++++++++++--
1 file changed, 18 insertions(+), 2 deletions(-)
diff --git a/target/mips/fpu_helper.c b/target/mips/fpu_helper.c
index e227e53f70..dae1331f23 100644
--- a/target/mips/fpu_helper.c
+++ b/target/mips/fpu_helper.c
@@ -1113,10 +1113,26 @@ uint ## bits ## _t helper_float_ ## name(CPUMIPSState
*env, \
return fdret; \
}
-FLOAT_RINT(rint_s, 32)
-FLOAT_RINT(rint_d, 64)
#undef FLOAT_RINT
+uint64_t helper_float_rint_d(CPUMIPSState *env, uint64_t fs)
+{
+ uint64_t fdret;
+
+ fdret = float64_round_to_int(fs, &env->active_fpu.fp_status);
+ update_fcr31(env, GETPC());
+ return fdret;
+}
+
+uint32_t helper_float_rint_s(CPUMIPSState *env, uint32_t fs)
+{
+ uint32_t fdret;
+
+ fdret = float32_round_to_int(fs, &env->active_fpu.fp_status);
+ update_fcr31(env, GETPC());
+ return fdret;
+}
+
#define FLOAT_CLASS_SIGNALING_NAN 0x001
#define FLOAT_CLASS_QUIET_NAN 0x002
#define FLOAT_CLASS_NEGATIVE_INFINITY 0x004
--
2.20.1
- [PATCH v5 03/22] target/mips: fpu: Demacro SUB.<D|S|PS>, (continued)
- [PATCH v5 03/22] target/mips: fpu: Demacro SUB.<D|S|PS>, Aleksandar Markovic, 2020/05/18
- [PATCH v5 05/22] target/mips: fpu: Demacro DIV.<D|S|PS>, Aleksandar Markovic, 2020/05/18
- [PATCH v5 04/22] target/mips: fpu: Demacro MUL.<D|S|PS>, Aleksandar Markovic, 2020/05/18
- [PATCH v5 06/22] target/mips: fpu: Remove now unused macro FLOAT_BINOP, Aleksandar Markovic, 2020/05/18
- [PATCH v5 08/22] target/mips: fpu: Demacro MSUB.<D|S|PS>, Aleksandar Markovic, 2020/05/18
- [PATCH v5 07/22] target/mips: fpu: Demacro MADD.<D|S|PS>, Aleksandar Markovic, 2020/05/18
- [PATCH v5 09/22] target/mips: fpu: Demacro NMADD.<D|S|PS>, Aleksandar Markovic, 2020/05/18
- [PATCH v5 10/22] target/mips: fpu: Demacro NMSUB.<D|S|PS>, Aleksandar Markovic, 2020/05/18
- [PATCH v5 11/22] target/mips: fpu: Remove now unused UNFUSED_FMA and FLOAT_FMA macros, Aleksandar Markovic, 2020/05/18
- [PATCH v5 12/22] target/mips: fpu: Demacro CLASS.<D|S>, Aleksandar Markovic, 2020/05/18
- [PATCH v5 14/22] target/mips: fpu: Demacro RINT.<D|S>,
Aleksandar Markovic <=
- [PATCH v5 13/22] target/mips: fpu: Remove now unused FLOAT_CLASS macro, Aleksandar Markovic, 2020/05/18
- [PATCH v5 15/22] target/mips: fpu: Remove now unused FLOAT_RINT macro, Aleksandar Markovic, 2020/05/18
- [PATCH v5 16/22] target/mips: fpu: Name better paired-single variables, Aleksandar Markovic, 2020/05/18
- [PATCH v5 17/22] target/mips: fpu: Refactor conversion from ieee to mips exception flags, Aleksandar Markovic, 2020/05/18
- [PATCH v5 18/22] MAINTAINERS: Change Aleksandar Rikalo's email address, Aleksandar Markovic, 2020/05/18
- [PATCH v5 19/22] target/mips: msa: Split helpers for MADDV.<B|H|W|D>, Aleksandar Markovic, 2020/05/18
- [PATCH v5 22/22] hw/mips: Rename malta/mipssim/r4k/jazz files in hw/mips, Aleksandar Markovic, 2020/05/18
- [PATCH v5 21/22] hw/mips: Add some logging for bad register offset cases, Aleksandar Markovic, 2020/05/18
- [PATCH v5 20/22] target/mips: msa: Split helpers for MSUBV.<B|H|W|D>, Aleksandar Markovic, 2020/05/18