Thomas Wouters | 1b7f891 | 2007-09-19 03:06:30 +0000 | [diff] [blame] | 1 | ------------------------------------------------------------------------
|
| 2 | -- copy.decTest -- quiet copy --
|
Benjamin Peterson | f17ff4e | 2008-07-31 16:32:12 +0000 | [diff] [blame] | 3 | -- Copyright (c) IBM Corporation, 1981, 2008. All rights reserved. --
|
Thomas Wouters | 1b7f891 | 2007-09-19 03:06:30 +0000 | [diff] [blame] | 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 | ------------------------------------------------------------------------
|
Mark Dickinson | 8a54653 | 2009-10-08 16:30:38 +0000 | [diff] [blame] | 20 | version: 2.59
|
Thomas Wouters | 1b7f891 | 2007-09-19 03:06:30 +0000 | [diff] [blame] | 21 |
|
| 22 | extended: 1
|
| 23 | precision: 9
|
| 24 | rounding: half_up
|
| 25 | maxExponent: 999
|
| 26 | minExponent: -999
|
| 27 |
|
| 28 | -- Sanity check
|
| 29 | cpyx001 copy +7.50 -> 7.50
|
| 30 |
|
| 31 | -- Infinities
|
| 32 | cpyx011 copy Infinity -> Infinity
|
| 33 | cpyx012 copy -Infinity -> -Infinity
|
| 34 |
|
| 35 | -- NaNs, 0 payload
|
| 36 | cpyx021 copy NaN -> NaN
|
| 37 | cpyx022 copy -NaN -> -NaN
|
| 38 | cpyx023 copy sNaN -> sNaN
|
| 39 | cpyx024 copy -sNaN -> -sNaN
|
| 40 |
|
| 41 | -- NaNs, non-0 payload
|
| 42 | cpyx031 copy NaN10 -> NaN10
|
| 43 | cpyx032 copy -NaN10 -> -NaN10
|
| 44 | cpyx033 copy sNaN10 -> sNaN10
|
| 45 | cpyx034 copy -sNaN10 -> -sNaN10
|
| 46 | cpyx035 copy NaN7 -> NaN7
|
| 47 | cpyx036 copy -NaN7 -> -NaN7
|
| 48 | cpyx037 copy sNaN101 -> sNaN101
|
| 49 | cpyx038 copy -sNaN101 -> -sNaN101
|
| 50 |
|
| 51 | -- finites
|
| 52 | cpyx101 copy 7 -> 7
|
| 53 | cpyx102 copy -7 -> -7
|
| 54 | cpyx103 copy 75 -> 75
|
| 55 | cpyx104 copy -75 -> -75
|
| 56 | cpyx105 copy 7.50 -> 7.50
|
| 57 | cpyx106 copy -7.50 -> -7.50
|
| 58 | cpyx107 copy 7.500 -> 7.500
|
| 59 | cpyx108 copy -7.500 -> -7.500
|
| 60 |
|
| 61 | -- zeros
|
| 62 | cpyx111 copy 0 -> 0
|
| 63 | cpyx112 copy -0 -> -0
|
| 64 | cpyx113 copy 0E+4 -> 0E+4
|
| 65 | cpyx114 copy -0E+4 -> -0E+4
|
| 66 | cpyx115 copy 0.0000 -> 0.0000
|
| 67 | cpyx116 copy -0.0000 -> -0.0000
|
| 68 | cpyx117 copy 0E-141 -> 0E-141
|
| 69 | cpyx118 copy -0E-141 -> -0E-141
|
| 70 |
|
| 71 | -- full coefficients, alternating bits
|
| 72 | cpyx121 copy 268268268 -> 268268268
|
| 73 | cpyx122 copy -268268268 -> -268268268
|
| 74 | cpyx123 copy 134134134 -> 134134134
|
| 75 | cpyx124 copy -134134134 -> -134134134
|
| 76 |
|
| 77 | -- Nmax, Nmin, Ntiny
|
| 78 | cpyx131 copy 9.99999999E+999 -> 9.99999999E+999
|
| 79 | cpyx132 copy 1E-999 -> 1E-999
|
| 80 | cpyx133 copy 1.00000000E-999 -> 1.00000000E-999
|
| 81 | cpyx134 copy 1E-1007 -> 1E-1007
|
| 82 |
|
| 83 | cpyx135 copy -1E-1007 -> -1E-1007
|
| 84 | cpyx136 copy -1.00000000E-999 -> -1.00000000E-999
|
| 85 | cpyx137 copy -1E-999 -> -1E-999
|
| 86 | cpyx138 copy -9.99999999E+999 -> -9.99999999E+999
|