summaryrefslogtreecommitdiff
path: root/test/float_ops.txt
diff options
context:
space:
mode:
Diffstat (limited to 'test/float_ops.txt')
-rw-r--r--test/float_ops.txt139
1 files changed, 139 insertions, 0 deletions
diff --git a/test/float_ops.txt b/test/float_ops.txt
index aa28b7eb6..3cd01846b 100644
--- a/test/float_ops.txt
+++ b/test/float_ops.txt
@@ -15,6 +15,12 @@ dfloor
-1 ==> -1
0 ==> 0
-2 ==> -2
+ 4294967296 ==> 4294967296
+ 4294967294 ==> 4294967294
+ 1 ==> 1
+ -3 ==> -3
+ 4294967297 ==> 4294967297
+ 4294967293 ==> 4294967293
dadd
0,0 ==> 0
0,1 ==> 1
@@ -308,6 +314,12 @@ int_to_double
-1 ==> 0.22999999999999998
0 ==> 1.23
-2 ==> -0.77
+ 4294967296 ==> 1.23
+ 4294967294 ==> -0.77
+ 1 ==> 2.23
+ -3 ==> -1.77
+ 4294967297 ==> 2.23
+ 4294967293 ==> -1.77
uint_to_double
0 ==> 1.23
1 ==> 2.23
@@ -325,6 +337,12 @@ uint_to_double
-1 ==> 4294967296.23
0 ==> 1.23
-2 ==> 4294967295.23
+ 4294967296 ==> 1.23
+ 4294967294 ==> 4294967295.23
+ 1 ==> 2.23
+ -3 ==> 4294967294.23
+ 4294967297 ==> 2.23
+ 4294967293 ==> 4294967294.23
double_to_int
0 ==> 1
1 ==> 2
@@ -342,4 +360,125 @@ double_to_int
-1 ==> 0
0 ==> 1
-2 ==> 0
+ 4294967296 ==> 1
+ 4294967294 ==> -1
+ 1 ==> 2
+ -3 ==> -1
+ 4294967297 ==> 2
+ 4294967293 ==> -2
+double_to_uint
+ 0 ==> 1
+ 1 ==> 2
+ -1 ==> 0
+ 0.5 ==> 1
+ -0.5 ==> 0
+ 1.4 ==> 2
+ -1.4 ==> 0
+ 1.6 ==> 2
+ -1.6 ==> 0
+ 5.1 ==> 6
+ 5.3 ==> 6
+ 5.7 ==> 6
+ 5.9 ==> 7
+ -1 ==> 0
+ 0 ==> 1
+ -2 ==> 0
+ 4294967296 ==> 1
+ 4294967294 ==> -1
+ 1 ==> 2
+ -3 ==> -1
+ 4294967297 ==> 2
+ 4294967293 ==> -2
+int_to_float
+ 0 ==> 1.2300000190734863
+ 1 ==> 2.2300000190734863
+ -1 ==> 0.23000000417232513
+ 0.5 ==> 1.2300000190734863
+ -0.5 ==> 1.2300000190734863
+ 1.4 ==> 2.2300000190734863
+ -1.4 ==> 0.23000000417232513
+ 1.6 ==> 2.2300000190734863
+ -1.6 ==> 0.23000000417232513
+ 5.1 ==> 6.230000019073486
+ 5.3 ==> 6.230000019073486
+ 5.7 ==> 6.230000019073486
+ 5.9 ==> 6.230000019073486
+ -1 ==> 0.23000000417232513
+ 0 ==> 1.2300000190734863
+ -2 ==> -0.7699999809265137
+ 4294967296 ==> 1.2300000190734863
+ 4294967294 ==> -0.7699999809265137
+ 1 ==> 2.2300000190734863
+ -3 ==> -1.7699999809265137
+ 4294967297 ==> 2.2300000190734863
+ 4294967293 ==> -1.7699999809265137
+uint_to_float
+ 0 ==> 1.2300000190734863
+ 1 ==> 2.2300000190734863
+ -1 ==> 4294967296
+ 0.5 ==> 1.2300000190734863
+ -0.5 ==> 1.2300000190734863
+ 1.4 ==> 2.2300000190734863
+ -1.4 ==> 4294967296
+ 1.6 ==> 2.2300000190734863
+ -1.6 ==> 4294967296
+ 5.1 ==> 6.230000019073486
+ 5.3 ==> 6.230000019073486
+ 5.7 ==> 6.230000019073486
+ 5.9 ==> 6.230000019073486
+ -1 ==> 4294967296
+ 0 ==> 1.2300000190734863
+ -2 ==> 4294967296
+ 4294967296 ==> 1.2300000190734863
+ 4294967294 ==> 4294967296
+ 1 ==> 2.2300000190734863
+ -3 ==> 4294967296
+ 4294967297 ==> 2.2300000190734863
+ 4294967293 ==> 4294967296
+float_to_int
+ 0 ==> 1
+ 1 ==> 2
+ -1 ==> 0
+ 0.5 ==> 1
+ -0.5 ==> 0
+ 1.4 ==> 2
+ -1.4 ==> 0
+ 1.6 ==> 2
+ -1.6 ==> 0
+ 5.1 ==> 6
+ 5.3 ==> 6
+ 5.7 ==> 6
+ 5.9 ==> 7
+ -1 ==> 0
+ 0 ==> 1
+ -2 ==> 0
+ 4294967296 ==> 0
+ 4294967294 ==> 0
+ 1 ==> 2
+ -3 ==> -1
+ 4294967297 ==> 0
+ 4294967293 ==> 0
+float_to_uint
+ 0 ==> 1
+ 1 ==> 2
+ -1 ==> 0
+ 0.5 ==> 1
+ -0.5 ==> 0
+ 1.4 ==> 2
+ -1.4 ==> 0
+ 1.6 ==> 2
+ -1.6 ==> 0
+ 5.1 ==> 6
+ 5.3 ==> 6
+ 5.7 ==> 6
+ 5.9 ==> 7
+ -1 ==> 0
+ 0 ==> 1
+ -2 ==> 0
+ 4294967296 ==> 0
+ 4294967294 ==> 0
+ 1 ==> 2
+ -3 ==> -1
+ 4294967297 ==> 0
+ 4294967293 ==> 0
done.