|
1 ------------------------------------------------------------------------ |
|
2 -- copyAbs.decTest -- quiet copy and set sign to zero -- |
|
3 -- Copyright (c) IBM Corporation, 1981, 2008. All rights reserved. -- |
|
4 ------------------------------------------------------------------------ |
|
5 -- Please see the document "General Decimal Arithmetic Testcases" -- |
|
6 -- at http://www2.hursley.ibm.com/decimal for the description of -- |
|
7 -- these testcases. -- |
|
8 -- -- |
|
9 -- These testcases are experimental ('beta' versions), and they -- |
|
10 -- may contain errors. They are offered on an as-is basis. In -- |
|
11 -- particular, achieving the same results as the tests here is not -- |
|
12 -- a guarantee that an implementation complies with any Standard -- |
|
13 -- or specification. The tests are not exhaustive. -- |
|
14 -- -- |
|
15 -- Please send comments, suggestions, and corrections to the author: -- |
|
16 -- Mike Cowlishaw, IBM Fellow -- |
|
17 -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- |
|
18 -- mfc@uk.ibm.com -- |
|
19 ------------------------------------------------------------------------ |
|
20 version: 2.58 |
|
21 |
|
22 extended: 1 |
|
23 precision: 9 |
|
24 rounding: half_up |
|
25 maxExponent: 999 |
|
26 minExponent: -999 |
|
27 |
|
28 -- Sanity check |
|
29 cpax001 copyabs +7.50 -> 7.50 |
|
30 |
|
31 -- Infinities |
|
32 cpax011 copyabs Infinity -> Infinity |
|
33 cpax012 copyabs -Infinity -> Infinity |
|
34 |
|
35 -- NaNs, 0 payload |
|
36 cpax021 copyabs NaN -> NaN |
|
37 cpax022 copyabs -NaN -> NaN |
|
38 cpax023 copyabs sNaN -> sNaN |
|
39 cpax024 copyabs -sNaN -> sNaN |
|
40 |
|
41 -- NaNs, non-0 payload |
|
42 cpax031 copyabs NaN10 -> NaN10 |
|
43 cpax032 copyabs -NaN15 -> NaN15 |
|
44 cpax033 copyabs sNaN15 -> sNaN15 |
|
45 cpax034 copyabs -sNaN10 -> sNaN10 |
|
46 cpax035 copyabs NaN7 -> NaN7 |
|
47 cpax036 copyabs -NaN7 -> NaN7 |
|
48 cpax037 copyabs sNaN101 -> sNaN101 |
|
49 cpax038 copyabs -sNaN101 -> sNaN101 |
|
50 |
|
51 -- finites |
|
52 cpax101 copyabs 7 -> 7 |
|
53 cpax102 copyabs -7 -> 7 |
|
54 cpax103 copyabs 75 -> 75 |
|
55 cpax104 copyabs -75 -> 75 |
|
56 cpax105 copyabs 7.10 -> 7.10 |
|
57 cpax106 copyabs -7.10 -> 7.10 |
|
58 cpax107 copyabs 7.500 -> 7.500 |
|
59 cpax108 copyabs -7.500 -> 7.500 |
|
60 |
|
61 -- zeros |
|
62 cpax111 copyabs 0 -> 0 |
|
63 cpax112 copyabs -0 -> 0 |
|
64 cpax113 copyabs 0E+6 -> 0E+6 |
|
65 cpax114 copyabs -0E+6 -> 0E+6 |
|
66 cpax115 copyabs 0.0000 -> 0.0000 |
|
67 cpax116 copyabs -0.0000 -> 0.0000 |
|
68 cpax117 copyabs 0E-141 -> 0E-141 |
|
69 cpax118 copyabs -0E-141 -> 0E-141 |
|
70 |
|
71 -- full coefficients, alternating bits |
|
72 cpax121 copyabs 268268268 -> 268268268 |
|
73 cpax122 copyabs -268268268 -> 268268268 |
|
74 cpax123 copyabs 134134134 -> 134134134 |
|
75 cpax124 copyabs -134134134 -> 134134134 |
|
76 |
|
77 -- Nmax, Nmin, Ntiny |
|
78 cpax131 copyabs 9.99999999E+999 -> 9.99999999E+999 |
|
79 cpax132 copyabs 1E-999 -> 1E-999 |
|
80 cpax133 copyabs 1.00000000E-999 -> 1.00000000E-999 |
|
81 cpax134 copyabs 1E-1007 -> 1E-1007 |
|
82 |
|
83 cpax135 copyabs -1E-1007 -> 1E-1007 |
|
84 cpax136 copyabs -1.00000000E-999 -> 1.00000000E-999 |
|
85 cpax137 copyabs -1E-999 -> 1E-999 |
|
86 cpax199 copyabs -9.99999999E+999 -> 9.99999999E+999 |