summaryrefslogtreecommitdiffstats
path: root/fpu
diff options
context:
space:
mode:
authorRichard Henderson2018-04-10 14:02:26 +0200
committerPeter Maydell2018-04-10 14:02:26 +0200
commitbd49e6027cbc207c87633c7add3ebd7d3474cd35 (patch)
tree85550768de15b1372fbb48e1d0c677c5ed12bcef /fpu
parenttcg: Introduce tcg_set_insn_start_param (diff)
downloadqemu-bd49e6027cbc207c87633c7add3ebd7d3474cd35.tar.gz
qemu-bd49e6027cbc207c87633c7add3ebd7d3474cd35.tar.xz
qemu-bd49e6027cbc207c87633c7add3ebd7d3474cd35.zip
fpu: Fix rounding mode for floatN_to_uintM_round_to_zero
We incorrectly passed in the current rounding mode instead of float_round_to_zero. Signed-off-by: Richard Henderson <richard.henderson@linaro.org> Message-id: 20180410055912.934-1-richard.henderson@linaro.org Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'fpu')
-rw-r--r--fpu/softfloat.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fpu/softfloat.c b/fpu/softfloat.c
index 6e16284e66..b46dccc63e 100644
--- a/fpu/softfloat.c
+++ b/fpu/softfloat.c
@@ -1486,8 +1486,8 @@ uint ## isz ## _t float ## fsz ## _to_uint ## isz ## _round_to_zero \
(float ## fsz a, float_status *s) \
{ \
FloatParts p = float ## fsz ## _unpack_canonical(a, s); \
- return round_to_uint_and_pack(p, s->float_rounding_mode, \
- UINT ## isz ## _MAX, s); \
+ return round_to_uint_and_pack(p, float_round_to_zero, \
+ UINT ## isz ## _MAX, s); \
}
FLOAT_TO_UINT(16, 16)