]>
Commit | Line | Data |
---|---|---|
4710c53d | 1 | ------------------------------------------------------------------------\r |
2 | -- dqCopyNegate.decTest -- quiet decQuad copy and negate --\r | |
3 | -- Copyright (c) IBM Corporation, 1981, 2008. All rights reserved. --\r | |
4 | ------------------------------------------------------------------------\r | |
5 | -- Please see the document "General Decimal Arithmetic Testcases" --\r | |
6 | -- at http://www2.hursley.ibm.com/decimal for the description of --\r | |
7 | -- these testcases. --\r | |
8 | -- --\r | |
9 | -- These testcases are experimental ('beta' versions), and they --\r | |
10 | -- may contain errors. They are offered on an as-is basis. In --\r | |
11 | -- particular, achieving the same results as the tests here is not --\r | |
12 | -- a guarantee that an implementation complies with any Standard --\r | |
13 | -- or specification. The tests are not exhaustive. --\r | |
14 | -- --\r | |
15 | -- Please send comments, suggestions, and corrections to the author: --\r | |
16 | -- Mike Cowlishaw, IBM Fellow --\r | |
17 | -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK --\r | |
18 | -- mfc@uk.ibm.com --\r | |
19 | ------------------------------------------------------------------------\r | |
20 | version: 2.59\r | |
21 | \r | |
22 | -- All operands and results are decQuads.\r | |
23 | extended: 1\r | |
24 | clamp: 1\r | |
25 | precision: 34\r | |
26 | maxExponent: 6144\r | |
27 | minExponent: -6143\r | |
28 | rounding: half_even\r | |
29 | \r | |
30 | -- Sanity check\r | |
31 | dqcpn001 copynegate +7.50 -> -7.50\r | |
32 | \r | |
33 | -- Infinities\r | |
34 | dqcpn011 copynegate Infinity -> -Infinity\r | |
35 | dqcpn012 copynegate -Infinity -> Infinity\r | |
36 | \r | |
37 | -- NaNs, 0 payload\r | |
38 | dqcpn021 copynegate NaN -> -NaN\r | |
39 | dqcpn022 copynegate -NaN -> NaN\r | |
40 | dqcpn023 copynegate sNaN -> -sNaN\r | |
41 | dqcpn024 copynegate -sNaN -> sNaN\r | |
42 | \r | |
43 | -- NaNs, non-0 payload\r | |
44 | dqcpn031 copynegate NaN13 -> -NaN13\r | |
45 | dqcpn032 copynegate -NaN13 -> NaN13\r | |
46 | dqcpn033 copynegate sNaN13 -> -sNaN13\r | |
47 | dqcpn034 copynegate -sNaN13 -> sNaN13\r | |
48 | dqcpn035 copynegate NaN70 -> -NaN70\r | |
49 | dqcpn036 copynegate -NaN70 -> NaN70\r | |
50 | dqcpn037 copynegate sNaN101 -> -sNaN101\r | |
51 | dqcpn038 copynegate -sNaN101 -> sNaN101\r | |
52 | \r | |
53 | -- finites\r | |
54 | dqcpn101 copynegate 7 -> -7\r | |
55 | dqcpn102 copynegate -7 -> 7\r | |
56 | dqcpn103 copynegate 75 -> -75\r | |
57 | dqcpn104 copynegate -75 -> 75\r | |
58 | dqcpn105 copynegate 7.50 -> -7.50\r | |
59 | dqcpn106 copynegate -7.50 -> 7.50\r | |
60 | dqcpn107 copynegate 7.500 -> -7.500\r | |
61 | dqcpn108 copynegate -7.500 -> 7.500\r | |
62 | \r | |
63 | -- zeros\r | |
64 | dqcpn111 copynegate 0 -> -0\r | |
65 | dqcpn112 copynegate -0 -> 0\r | |
66 | dqcpn113 copynegate 0E+4 -> -0E+4\r | |
67 | dqcpn114 copynegate -0E+4 -> 0E+4\r | |
68 | dqcpn115 copynegate 0.0000 -> -0.0000\r | |
69 | dqcpn116 copynegate -0.0000 -> 0.0000\r | |
70 | dqcpn117 copynegate 0E-141 -> -0E-141\r | |
71 | dqcpn118 copynegate -0E-141 -> 0E-141\r | |
72 | \r | |
73 | -- full coefficients, alternating bits\r | |
74 | dqcpn121 copynegate 2682682682682682682682682682682682 -> -2682682682682682682682682682682682\r | |
75 | dqcpn122 copynegate -2682682682682682682682682682682682 -> 2682682682682682682682682682682682\r | |
76 | dqcpn123 copynegate 1341341341341341341341341341341341 -> -1341341341341341341341341341341341\r | |
77 | dqcpn124 copynegate -1341341341341341341341341341341341 -> 1341341341341341341341341341341341\r | |
78 | \r | |
79 | -- Nmax, Nmin, Ntiny\r | |
80 | dqcpn131 copynegate 9.999999999999999999999999999999999E+6144 -> -9.999999999999999999999999999999999E+6144\r | |
81 | dqcpn132 copynegate 1E-6143 -> -1E-6143\r | |
82 | dqcpn133 copynegate 1.000000000000000000000000000000000E-6143 -> -1.000000000000000000000000000000000E-6143\r | |
83 | dqcpn134 copynegate 1E-6176 -> -1E-6176\r | |
84 | \r | |
85 | dqcpn135 copynegate -1E-6176 -> 1E-6176\r | |
86 | dqcpn136 copynegate -1.000000000000000000000000000000000E-6143 -> 1.000000000000000000000000000000000E-6143\r | |
87 | dqcpn137 copynegate -1E-6143 -> 1E-6143\r | |
88 | dqcpn138 copynegate -9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999999E+6144\r |