aboutsummaryrefslogtreecommitdiff
path: root/fpu/softfloat.c
diff options
context:
space:
mode:
authorpbrook <pbrook@c046a42c-6fe2-441c-8c8c-71466251a162>2006-10-22 00:18:54 +0000
committerpbrook <pbrook@c046a42c-6fe2-441c-8c8c-71466251a162>2006-10-22 00:18:54 +0000
commite6e5906b6e0a81718066ca43aef57515026c6624 (patch)
tree79996f66ed5a2e4f37783a114cb45f6913204486 /fpu/softfloat.c
parent223b8a40d13550ebc08216bd96d1f615597e0554 (diff)
downloadqemu-e6e5906b6e0a81718066ca43aef57515026c6624.zip
qemu-e6e5906b6e0a81718066ca43aef57515026c6624.tar.gz
qemu-e6e5906b6e0a81718066ca43aef57515026c6624.tar.bz2
ColdFire target.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2196 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'fpu/softfloat.c')
-rw-r--r--fpu/softfloat.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/fpu/softfloat.c b/fpu/softfloat.c
index 5e84620..f24913a 100644
--- a/fpu/softfloat.c
+++ b/fpu/softfloat.c
@@ -2483,6 +2483,17 @@ float64 float64_round_to_int( float64 a STATUS_PARAM )
}
+float64 float64_trunc_to_int( float64 a STATUS_PARAM)
+{
+ int oldmode;
+ float64 res;
+ oldmode = STATUS(float_rounding_mode);
+ STATUS(float_rounding_mode) = float_round_to_zero;
+ res = float64_round_to_int(a STATUS_VAR);
+ STATUS(float_rounding_mode) = oldmode;
+ return res;
+}
+
/*----------------------------------------------------------------------------
| Returns the result of adding the absolute values of the double-precision
| floating-point values `a' and `b'. If `zSign' is 1, the sum is negated