diff --git a/Lib/test/decimaltestdata/abs.decTest b/Lib/test/decimaltestdata/abs.decTest index ed4c46e7d8c..39f2dca5a14 100644 --- a/Lib/test/decimaltestdata/abs.decTest +++ b/Lib/test/decimaltestdata/abs.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This set of tests primarily tests the existence of the operator. -- Additon, subtraction, rounding, and more overflows are tested diff --git a/Lib/test/decimaltestdata/add.decTest b/Lib/test/decimaltestdata/add.decTest index 3460aa4cd25..8db222a1b95 100644 --- a/Lib/test/decimaltestdata/add.decTest +++ b/Lib/test/decimaltestdata/add.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 9 rounding: half_up @@ -1122,6 +1122,15 @@ addx1116 add -1e-3 +1e-383 -> -0.0009999999999999999 Rounded Inexact addx1117 add -1e-4 +1e-383 -> -0.00009999999999999999 Rounded Inexact addx1118 add -1e-5 +1e-383 -> -0.000009999999999999999 Rounded Inexact addx1119 add -1e-6 +1e-383 -> -9.999999999999999E-7 Rounded Inexact +addx1120 add +1e-383 -1e+2 -> -99.99999999999999 Rounded Inexact +addx1121 add +1e-383 -1e+1 -> -9.999999999999999 Rounded Inexact +addx1123 add +1e-383 -1 -> -0.9999999999999999 Rounded Inexact +addx1124 add +1e-383 -1e-1 -> -0.09999999999999999 Rounded Inexact +addx1125 add +1e-383 -1e-2 -> -0.009999999999999999 Rounded Inexact +addx1126 add +1e-383 -1e-3 -> -0.0009999999999999999 Rounded Inexact +addx1127 add +1e-383 -1e-4 -> -0.00009999999999999999 Rounded Inexact +addx1128 add +1e-383 -1e-5 -> -0.000009999999999999999 Rounded Inexact +addx1129 add +1e-383 -1e-6 -> -9.999999999999999E-7 Rounded Inexact rounding: down precision: 7 @@ -1658,17 +1667,19 @@ addx6056 add '1.3' '-2.07' -> '-0.77' addx6057 add '1E+2' '1E+4' -> '1.01E+4' -- from above -addx6061 add 1 '0.1' -> '1.1' -addx6062 add 1 '0.01' -> '1.01' -addx6063 add 1 '0.001' -> '1.001' -addx6064 add 1 '0.0001' -> '1.0001' -addx6065 add 1 '0.00001' -> '1.00001' -addx6066 add 1 '0.000001' -> '1.000001' -addx6067 add 1 '0.0000001' -> '1.0000001' -addx6068 add 1 '0.00000001' -> '1.00000001' +addx6060 add 1 '0.1' -> '1.1' +addx6061 add 1 '0.01' -> '1.01' +addx6062 add 1 '0.001' -> '1.001' +addx6063 add 1 '0.0001' -> '1.0001' +addx6064 add 1 '0.00001' -> '1.00001' +addx6065 add 1 '0.000001' -> '1.000001' +addx6066 add 1 '0.0000001' -> '1.0000001' +addx6067 add 1 '0.00000001' -> '1.00000001' -- cancellation to integer -addx6069 add 99999999999999123456789 -99999999999999E+9 -> 123456789 +addx6068 add 99999999999999123456789 -99999999999999E+9 -> 123456789 +-- similar from FMA fun +addx6069 add "-1234567890123455.234567890123454" "1234567890123456" -> 0.765432109876546 -- some funny zeros [in case of bad signum] addx6070 add 1 0 -> 1 diff --git a/Lib/test/decimaltestdata/and.decTest b/Lib/test/decimaltestdata/and.decTest index 18ba8817cf8..90490a51ebe 100644 --- a/Lib/test/decimaltestdata/and.decTest +++ b/Lib/test/decimaltestdata/and.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/base.decTest b/Lib/test/decimaltestdata/base.decTest index de0b8138bce..58ce91c4b5a 100644 --- a/Lib/test/decimaltestdata/base.decTest +++ b/Lib/test/decimaltestdata/base.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 -- This file tests base conversions from string to a decimal number diff --git a/Lib/test/decimaltestdata/clamp.decTest b/Lib/test/decimaltestdata/clamp.decTest index eca0cfb2776..48e27c0ce76 100644 --- a/Lib/test/decimaltestdata/clamp.decTest +++ b/Lib/test/decimaltestdata/clamp.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This set of tests uses the same limits as the 8-byte concrete -- representation, but applies clamping without using format-specific diff --git a/Lib/test/decimaltestdata/class.decTest b/Lib/test/decimaltestdata/class.decTest index 77a22e3a598..61ad548a10e 100644 --- a/Lib/test/decimaltestdata/class.decTest +++ b/Lib/test/decimaltestdata/class.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- [New 2006.11.27] diff --git a/Lib/test/decimaltestdata/compare.decTest b/Lib/test/decimaltestdata/compare.decTest index 2d5e664076d..979cc52264c 100644 --- a/Lib/test/decimaltestdata/compare.decTest +++ b/Lib/test/decimaltestdata/compare.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- Note that we cannot assume add/subtract tests cover paths adequately, -- here, because the code might be quite different (comparison cannot diff --git a/Lib/test/decimaltestdata/comparetotal.decTest b/Lib/test/decimaltestdata/comparetotal.decTest index 737293f9c14..ef2914fcc0c 100644 --- a/Lib/test/decimaltestdata/comparetotal.decTest +++ b/Lib/test/decimaltestdata/comparetotal.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- Note that we cannot assume add/subtract tests cover paths adequately, -- here, because the code might be quite different (comparison cannot diff --git a/Lib/test/decimaltestdata/comparetotmag.decTest b/Lib/test/decimaltestdata/comparetotmag.decTest index a12e614cea6..4a51d7fc34a 100644 --- a/Lib/test/decimaltestdata/comparetotmag.decTest +++ b/Lib/test/decimaltestdata/comparetotmag.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- Note that it cannot be assumed that add/subtract tests cover paths -- for this operation adequately, here, because the code might be diff --git a/Lib/test/decimaltestdata/copy.decTest b/Lib/test/decimaltestdata/copy.decTest index 5d4065d9618..e6edac5fd6e 100644 --- a/Lib/test/decimaltestdata/copy.decTest +++ b/Lib/test/decimaltestdata/copy.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/copyabs.decTest b/Lib/test/decimaltestdata/copyabs.decTest index 7457552c8bb..447988887c7 100644 --- a/Lib/test/decimaltestdata/copyabs.decTest +++ b/Lib/test/decimaltestdata/copyabs.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/copynegate.decTest b/Lib/test/decimaltestdata/copynegate.decTest index 3e502be4c1b..7cf124c4d57 100644 --- a/Lib/test/decimaltestdata/copynegate.decTest +++ b/Lib/test/decimaltestdata/copynegate.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/copysign.decTest b/Lib/test/decimaltestdata/copysign.decTest index 6b20fda580b..ed6089363b7 100644 --- a/Lib/test/decimaltestdata/copysign.decTest +++ b/Lib/test/decimaltestdata/copysign.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/ddAbs.decTest b/Lib/test/decimaltestdata/ddAbs.decTest index 4da662c8f1e..58b7902295c 100644 --- a/Lib/test/decimaltestdata/ddAbs.decTest +++ b/Lib/test/decimaltestdata/ddAbs.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 16 maxExponent: 384 diff --git a/Lib/test/decimaltestdata/ddAdd.decTest b/Lib/test/decimaltestdata/ddAdd.decTest index 49d89d4e63a..38d511b01a3 100644 --- a/Lib/test/decimaltestdata/ddAdd.decTest +++ b/Lib/test/decimaltestdata/ddAdd.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This set of tests are for decDoubles only; all arguments are -- representable in a decDouble @@ -1029,6 +1029,16 @@ ddadd71706 add 130E-2 -12E-1 -> 0.10 ddadd71707 add 130E-2 -1E0 -> 0.30 ddadd71708 add 1E2 -1E4 -> -9.9E+3 +-- query from Vincent Kulandaisamy +rounding: ceiling +ddadd71801 add 7.8822773805862E+277 -5.1757503820663E-21 -> 7.882277380586200E+277 Inexact Rounded +ddadd71802 add 7.882277380586200E+277 12.341 -> 7.882277380586201E+277 Inexact Rounded +ddadd71803 add 7.882277380586201E+277 2.7270545046613E-31 -> 7.882277380586202E+277 Inexact Rounded + +ddadd71811 add 12.341 -5.1757503820663E-21 -> 12.34100000000000 Inexact Rounded +ddadd71812 add 12.34100000000000 2.7270545046613E-31 -> 12.34100000000001 Inexact Rounded +ddadd71813 add 12.34100000000001 7.8822773805862E+277 -> 7.882277380586201E+277 Inexact Rounded + -- Gappy coefficients; check residue handling even with full coefficient gap rounding: half_even diff --git a/Lib/test/decimaltestdata/ddAnd.decTest b/Lib/test/decimaltestdata/ddAnd.decTest index e5fa38d13ed..850da17ea2b 100644 --- a/Lib/test/decimaltestdata/ddAnd.decTest +++ b/Lib/test/decimaltestdata/ddAnd.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 16 maxExponent: 384 diff --git a/Lib/test/decimaltestdata/ddBase.decTest b/Lib/test/decimaltestdata/ddBase.decTest index 431bce1f85a..ddc8185685a 100644 --- a/Lib/test/decimaltestdata/ddBase.decTest +++ b/Lib/test/decimaltestdata/ddBase.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This file tests base conversions from string to a decimal number -- and back to a string (in Scientific form) diff --git a/Lib/test/decimaltestdata/ddCanonical.decTest b/Lib/test/decimaltestdata/ddCanonical.decTest index 308b9ffab7f..4d659b04814 100644 --- a/Lib/test/decimaltestdata/ddCanonical.decTest +++ b/Lib/test/decimaltestdata/ddCanonical.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This file tests that copy operations leave uncanonical operands -- unchanged, and vice versa diff --git a/Lib/test/decimaltestdata/ddClass.decTest b/Lib/test/decimaltestdata/ddClass.decTest index 0b1d1f39fe3..8a38f4a3f4f 100644 --- a/Lib/test/decimaltestdata/ddClass.decTest +++ b/Lib/test/decimaltestdata/ddClass.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- [New 2006.11.27] precision: 16 diff --git a/Lib/test/decimaltestdata/ddCompare.decTest b/Lib/test/decimaltestdata/ddCompare.decTest index b225d0db822..5f6fba52360 100644 --- a/Lib/test/decimaltestdata/ddCompare.decTest +++ b/Lib/test/decimaltestdata/ddCompare.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- Note that we cannot assume add/subtract tests cover paths adequately, -- here, because the code might be quite different (comparison cannot diff --git a/Lib/test/decimaltestdata/ddCompareSig.decTest b/Lib/test/decimaltestdata/ddCompareSig.decTest index 388a656e93c..b4895daa081 100644 --- a/Lib/test/decimaltestdata/ddCompareSig.decTest +++ b/Lib/test/decimaltestdata/ddCompareSig.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- Note that we cannot assume add/subtract tests cover paths adequately, -- here, because the code might be quite different (comparison cannot diff --git a/Lib/test/decimaltestdata/ddCompareTotal.decTest b/Lib/test/decimaltestdata/ddCompareTotal.decTest index a8bf477e567..b86b8dfa300 100644 --- a/Lib/test/decimaltestdata/ddCompareTotal.decTest +++ b/Lib/test/decimaltestdata/ddCompareTotal.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- Note that we cannot assume add/subtract tests cover paths adequately, -- here, because the code might be quite different (comparison cannot diff --git a/Lib/test/decimaltestdata/ddCompareTotalMag.decTest b/Lib/test/decimaltestdata/ddCompareTotalMag.decTest index b19cf6428cd..e93a7496bcb 100644 --- a/Lib/test/decimaltestdata/ddCompareTotalMag.decTest +++ b/Lib/test/decimaltestdata/ddCompareTotalMag.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- Note that we cannot assume add/subtract tests cover paths adequately, -- here, because the code might be quite different (comparison cannot diff --git a/Lib/test/decimaltestdata/ddCopy.decTest b/Lib/test/decimaltestdata/ddCopy.decTest index 49c68240bce..9d82db71c0e 100644 --- a/Lib/test/decimaltestdata/ddCopy.decTest +++ b/Lib/test/decimaltestdata/ddCopy.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decDoubles. precision: 16 diff --git a/Lib/test/decimaltestdata/ddCopyAbs.decTest b/Lib/test/decimaltestdata/ddCopyAbs.decTest index b65f063e091..c60cc380f33 100644 --- a/Lib/test/decimaltestdata/ddCopyAbs.decTest +++ b/Lib/test/decimaltestdata/ddCopyAbs.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decDoubles. precision: 16 diff --git a/Lib/test/decimaltestdata/ddCopyNegate.decTest b/Lib/test/decimaltestdata/ddCopyNegate.decTest index b111c9b285d..c2c60985a7e 100644 --- a/Lib/test/decimaltestdata/ddCopyNegate.decTest +++ b/Lib/test/decimaltestdata/ddCopyNegate.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decDoubles. precision: 16 diff --git a/Lib/test/decimaltestdata/ddCopySign.decTest b/Lib/test/decimaltestdata/ddCopySign.decTest index 7c834163ff8..36b060e120b 100644 --- a/Lib/test/decimaltestdata/ddCopySign.decTest +++ b/Lib/test/decimaltestdata/ddCopySign.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decDoubles. precision: 16 diff --git a/Lib/test/decimaltestdata/ddDivide.decTest b/Lib/test/decimaltestdata/ddDivide.decTest index 1a953f74131..90698941bbf 100644 --- a/Lib/test/decimaltestdata/ddDivide.decTest +++ b/Lib/test/decimaltestdata/ddDivide.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 16 maxExponent: 384 diff --git a/Lib/test/decimaltestdata/ddDivideInt.decTest b/Lib/test/decimaltestdata/ddDivideInt.decTest index 782fe8d12f1..71168415a25 100644 --- a/Lib/test/decimaltestdata/ddDivideInt.decTest +++ b/Lib/test/decimaltestdata/ddDivideInt.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 16 maxExponent: 384 diff --git a/Lib/test/decimaltestdata/ddEncode.decTest b/Lib/test/decimaltestdata/ddEncode.decTest index 16264fc98da..3fa434c55f4 100644 --- a/Lib/test/decimaltestdata/ddEncode.decTest +++ b/Lib/test/decimaltestdata/ddEncode.decTest @@ -18,7 +18,7 @@ -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -- [Previously called decimal64.decTest] -version: 2.56 +version: 2.57 -- This set of tests is for the eight-byte concrete representation. -- Its characteristics are: @@ -485,3 +485,6 @@ decd828 apply #2238000115afb55a -> 4294967294 decd829 apply #2238000115afb55b -> 4294967295 decd830 apply #2238000115afb57a -> 4294967296 decd831 apply #2238000115afb57b -> 4294967297 + +-- for narrowing +decd840 apply #2870000000000000 -> 2.000000000000000E-99 diff --git a/Lib/test/decimaltestdata/ddFMA.decTest b/Lib/test/decimaltestdata/ddFMA.decTest index 946d6801106..bc44b6abe6c 100644 --- a/Lib/test/decimaltestdata/ddFMA.decTest +++ b/Lib/test/decimaltestdata/ddFMA.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 16 maxExponent: 384 @@ -1663,6 +1663,34 @@ ddfma375087 fma 1 12345678 1E-33 -> 12345678.00000001 Inexac ddfma375088 fma 1 12345678 1E-34 -> 12345678.00000001 Inexact Rounded ddfma375089 fma 1 12345678 1E-35 -> 12345678.00000001 Inexact Rounded +-- desctructive subtraction (from remainder tests) + +-- +++ some of these will be off-by-one remainder vs remainderNear + +ddfma4000 fma -1234567890123454 1.000000000000001 1234567890123456 -> 0.765432109876546 +ddfma4001 fma -1234567890123443 1.00000000000001 1234567890123456 -> 0.65432109876557 +ddfma4002 fma -1234567890123332 1.0000000000001 1234567890123456 -> 0.5432109876668 +ddfma4003 fma -308641972530863 4.000000000000001 1234567890123455 -> 2.691358027469137 +ddfma4004 fma -308641972530863 4.000000000000001 1234567890123456 -> 3.691358027469137 +ddfma4005 fma -246913578024696 4.9999999999999 1234567890123456 -> 0.6913578024696 +ddfma4006 fma -246913578024691 4.99999999999999 1234567890123456 -> 3.46913578024691 +ddfma4007 fma -246913578024691 4.999999999999999 1234567890123456 -> 1.246913578024691 +ddfma4008 fma -246913578024691 5.000000000000001 1234567890123456 -> 0.753086421975309 +ddfma4009 fma -246913578024690 5.00000000000001 1234567890123456 -> 3.53086421975310 +ddfma4010 fma -246913578024686 5.0000000000001 1234567890123456 -> 1.3086421975314 +ddfma4011 fma -1234567890123455 1.000000000000001 1234567890123456 -> -0.234567890123455 +ddfma4012 fma -1234567890123444 1.00000000000001 1234567890123456 -> -0.34567890123444 +ddfma4013 fma -1234567890123333 1.0000000000001 1234567890123456 -> -0.4567890123333 +ddfma4014 fma -308641972530864 4.000000000000001 1234567890123455 -> -1.308641972530864 +ddfma4015 fma -308641972530864 4.000000000000001 1234567890123456 -> -0.308641972530864 +ddfma4016 fma -246913578024696 4.9999999999999 1234567890123456 -> 0.6913578024696 +ddfma4017 fma -246913578024692 4.99999999999999 1234567890123456 -> -1.53086421975308 +ddfma4018 fma -246913578024691 4.999999999999999 1234567890123456 -> 1.246913578024691 +ddfma4019 fma -246913578024691 5.000000000000001 1234567890123456 -> 0.753086421975309 +ddfma4020 fma -246913578024691 5.00000000000001 1234567890123456 -> -1.46913578024691 +ddfma4021 fma -246913578024686 5.0000000000001 1234567890123456 -> 1.3086421975314 + + -- Null tests ddfma39990 fma 1 10 # -> NaN Invalid_operation ddfma39991 fma 1 # 10 -> NaN Invalid_operation diff --git a/Lib/test/decimaltestdata/ddInvert.decTest b/Lib/test/decimaltestdata/ddInvert.decTest index 2697f59f13c..b4ae74468d5 100644 --- a/Lib/test/decimaltestdata/ddInvert.decTest +++ b/Lib/test/decimaltestdata/ddInvert.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 16 maxExponent: 384 diff --git a/Lib/test/decimaltestdata/ddLogB.decTest b/Lib/test/decimaltestdata/ddLogB.decTest index f18fd5ef17c..99a38434fd2 100644 --- a/Lib/test/decimaltestdata/ddLogB.decTest +++ b/Lib/test/decimaltestdata/ddLogB.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 16 maxExponent: 384 diff --git a/Lib/test/decimaltestdata/ddMax.decTest b/Lib/test/decimaltestdata/ddMax.decTest index 5fe600fcece..515f79a5b03 100644 --- a/Lib/test/decimaltestdata/ddMax.decTest +++ b/Lib/test/decimaltestdata/ddMax.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- we assume that base comparison is tested in compare.decTest, so -- these mainly cover special cases and rounding diff --git a/Lib/test/decimaltestdata/ddMaxMag.decTest b/Lib/test/decimaltestdata/ddMaxMag.decTest index dbabc990e06..c43c4604a8e 100644 --- a/Lib/test/decimaltestdata/ddMaxMag.decTest +++ b/Lib/test/decimaltestdata/ddMaxMag.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- we assume that base comparison is tested in compare.decTest, so -- these mainly cover special cases and rounding diff --git a/Lib/test/decimaltestdata/ddMin.decTest b/Lib/test/decimaltestdata/ddMin.decTest index 4ba27f71fb3..c77a71e2089 100644 --- a/Lib/test/decimaltestdata/ddMin.decTest +++ b/Lib/test/decimaltestdata/ddMin.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- we assume that base comparison is tested in compare.decTest, so -- these mainly cover special cases and rounding diff --git a/Lib/test/decimaltestdata/ddMinMag.decTest b/Lib/test/decimaltestdata/ddMinMag.decTest index cc5ccec0997..9291abce233 100644 --- a/Lib/test/decimaltestdata/ddMinMag.decTest +++ b/Lib/test/decimaltestdata/ddMinMag.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- we assume that base comparison is tested in compare.decTest, so -- these mainly cover special cases and rounding diff --git a/Lib/test/decimaltestdata/ddMinus.decTest b/Lib/test/decimaltestdata/ddMinus.decTest index 9fe196b828d..07dfa7abfae 100644 --- a/Lib/test/decimaltestdata/ddMinus.decTest +++ b/Lib/test/decimaltestdata/ddMinus.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decDoubles. precision: 16 diff --git a/Lib/test/decimaltestdata/ddMultiply.decTest b/Lib/test/decimaltestdata/ddMultiply.decTest index 01e0ffef3a7..f506ea25d4e 100644 --- a/Lib/test/decimaltestdata/ddMultiply.decTest +++ b/Lib/test/decimaltestdata/ddMultiply.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This set of tests are for decDoubles only; all arguments are -- representable in a decDouble @@ -454,9 +454,92 @@ ddmul908 multiply 9.999999999999999E-383 0.09999999999999999 -> 1.00000000 -- hugest ddmul909 multiply 9999999999999999 9999999999999999 -> 9.999999999999998E+31 Inexact Rounded +-- power-of-ten edge cases +ddmul1001 multiply 1 10 -> 10 +ddmul1002 multiply 1 100 -> 100 +ddmul1003 multiply 1 1000 -> 1000 +ddmul1004 multiply 1 10000 -> 10000 +ddmul1005 multiply 1 100000 -> 100000 +ddmul1006 multiply 1 1000000 -> 1000000 +ddmul1007 multiply 1 10000000 -> 10000000 +ddmul1008 multiply 1 100000000 -> 100000000 +ddmul1009 multiply 1 1000000000 -> 1000000000 +ddmul1010 multiply 1 10000000000 -> 10000000000 +ddmul1011 multiply 1 100000000000 -> 100000000000 +ddmul1012 multiply 1 1000000000000 -> 1000000000000 +ddmul1013 multiply 1 10000000000000 -> 10000000000000 +ddmul1014 multiply 1 100000000000000 -> 100000000000000 +ddmul1015 multiply 1 1000000000000000 -> 1000000000000000 +ddmul1021 multiply 10 1 -> 10 +ddmul1022 multiply 10 10 -> 100 +ddmul1023 multiply 10 100 -> 1000 +ddmul1024 multiply 10 1000 -> 10000 +ddmul1025 multiply 10 10000 -> 100000 +ddmul1026 multiply 10 100000 -> 1000000 +ddmul1027 multiply 10 1000000 -> 10000000 +ddmul1028 multiply 10 10000000 -> 100000000 +ddmul1029 multiply 10 100000000 -> 1000000000 +ddmul1030 multiply 10 1000000000 -> 10000000000 +ddmul1031 multiply 10 10000000000 -> 100000000000 +ddmul1032 multiply 10 100000000000 -> 1000000000000 +ddmul1033 multiply 10 1000000000000 -> 10000000000000 +ddmul1034 multiply 10 10000000000000 -> 100000000000000 +ddmul1035 multiply 10 100000000000000 -> 1000000000000000 +ddmul1041 multiply 100 0.1 -> 10.0 +ddmul1042 multiply 100 1 -> 100 +ddmul1043 multiply 100 10 -> 1000 +ddmul1044 multiply 100 100 -> 10000 +ddmul1045 multiply 100 1000 -> 100000 +ddmul1046 multiply 100 10000 -> 1000000 +ddmul1047 multiply 100 100000 -> 10000000 +ddmul1048 multiply 100 1000000 -> 100000000 +ddmul1049 multiply 100 10000000 -> 1000000000 +ddmul1050 multiply 100 100000000 -> 10000000000 +ddmul1051 multiply 100 1000000000 -> 100000000000 +ddmul1052 multiply 100 10000000000 -> 1000000000000 +ddmul1053 multiply 100 100000000000 -> 10000000000000 +ddmul1054 multiply 100 1000000000000 -> 100000000000000 +ddmul1055 multiply 100 10000000000000 -> 1000000000000000 +ddmul1061 multiply 1000 0.01 -> 10.00 +ddmul1062 multiply 1000 0.1 -> 100.0 +ddmul1063 multiply 1000 1 -> 1000 +ddmul1064 multiply 1000 10 -> 10000 +ddmul1065 multiply 1000 100 -> 100000 +ddmul1066 multiply 1000 1000 -> 1000000 +ddmul1067 multiply 1000 10000 -> 10000000 +ddmul1068 multiply 1000 100000 -> 100000000 +ddmul1069 multiply 1000 1000000 -> 1000000000 +ddmul1070 multiply 1000 10000000 -> 10000000000 +ddmul1071 multiply 1000 100000000 -> 100000000000 +ddmul1072 multiply 1000 1000000000 -> 1000000000000 +ddmul1073 multiply 1000 10000000000 -> 10000000000000 +ddmul1074 multiply 1000 100000000000 -> 100000000000000 +ddmul1075 multiply 1000 1000000000000 -> 1000000000000000 +ddmul1081 multiply 10000 0.001 -> 10.000 +ddmul1082 multiply 10000 0.01 -> 100.00 +ddmul1083 multiply 10000 0.1 -> 1000.0 +ddmul1084 multiply 10000 1 -> 10000 +ddmul1085 multiply 10000 10 -> 100000 +ddmul1086 multiply 10000 100 -> 1000000 +ddmul1087 multiply 10000 1000 -> 10000000 +ddmul1088 multiply 10000 10000 -> 100000000 +ddmul1089 multiply 10000 100000 -> 1000000000 +ddmul1090 multiply 10000 1000000 -> 10000000000 +ddmul1091 multiply 10000 10000000 -> 100000000000 +ddmul1092 multiply 10000 100000000 -> 1000000000000 +ddmul1093 multiply 10000 1000000000 -> 10000000000000 +ddmul1094 multiply 10000 10000000000 -> 100000000000000 +ddmul1095 multiply 10000 100000000000 -> 1000000000000000 + +ddmul1097 multiply 10000 99999999999 -> 999999999990000 +ddmul1098 multiply 10000 99999999999 -> 999999999990000 + + + + -- Null tests -ddmul990 multiply 10 # -> NaN Invalid_operation -ddmul991 multiply # 10 -> NaN Invalid_operation +ddmul9990 multiply 10 # -> NaN Invalid_operation +ddmul9991 multiply # 10 -> NaN Invalid_operation diff --git a/Lib/test/decimaltestdata/ddNextMinus.decTest b/Lib/test/decimaltestdata/ddNextMinus.decTest index 97c3b09a6c1..b9b0de57073 100644 --- a/Lib/test/decimaltestdata/ddNextMinus.decTest +++ b/Lib/test/decimaltestdata/ddNextMinus.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decDoubles. precision: 16 diff --git a/Lib/test/decimaltestdata/ddNextPlus.decTest b/Lib/test/decimaltestdata/ddNextPlus.decTest index d01f3c39a08..2bb2641aa81 100644 --- a/Lib/test/decimaltestdata/ddNextPlus.decTest +++ b/Lib/test/decimaltestdata/ddNextPlus.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decDoubles. precision: 16 diff --git a/Lib/test/decimaltestdata/ddNextToward.decTest b/Lib/test/decimaltestdata/ddNextToward.decTest index e00751bf487..80e4ac66cb6 100644 --- a/Lib/test/decimaltestdata/ddNextToward.decTest +++ b/Lib/test/decimaltestdata/ddNextToward.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decDoubles. precision: 16 diff --git a/Lib/test/decimaltestdata/ddOr.decTest b/Lib/test/decimaltestdata/ddOr.decTest index 3a8cdd642be..903ced0d34c 100644 --- a/Lib/test/decimaltestdata/ddOr.decTest +++ b/Lib/test/decimaltestdata/ddOr.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 16 maxExponent: 384 diff --git a/Lib/test/decimaltestdata/ddPlus.decTest b/Lib/test/decimaltestdata/ddPlus.decTest index 962a656acec..0a2b838cbf8 100644 --- a/Lib/test/decimaltestdata/ddPlus.decTest +++ b/Lib/test/decimaltestdata/ddPlus.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decDoubles. precision: 16 diff --git a/Lib/test/decimaltestdata/ddQuantize.decTest b/Lib/test/decimaltestdata/ddQuantize.decTest index 234db927b36..8cd52873131 100644 --- a/Lib/test/decimaltestdata/ddQuantize.decTest +++ b/Lib/test/decimaltestdata/ddQuantize.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- Most of the tests here assume a "regular pattern", where the -- sign and coefficient are +1. diff --git a/Lib/test/decimaltestdata/ddReduce.decTest b/Lib/test/decimaltestdata/ddReduce.decTest index 71c82e1aaa4..545beebfb4e 100644 --- a/Lib/test/decimaltestdata/ddReduce.decTest +++ b/Lib/test/decimaltestdata/ddReduce.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 16 maxExponent: 384 diff --git a/Lib/test/decimaltestdata/ddRemainder.decTest b/Lib/test/decimaltestdata/ddRemainder.decTest index c7ea7626de4..d805a483804 100644 --- a/Lib/test/decimaltestdata/ddRemainder.decTest +++ b/Lib/test/decimaltestdata/ddRemainder.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 16 maxExponent: 384 @@ -581,6 +581,19 @@ ddrem1056 remainder 1e-277 -1e+311 -> 1E-277 ddrem1057 remainder -1e-277 1e+311 -> -1E-277 ddrem1058 remainder -1e-277 -1e+311 -> -1E-277 +-- destructive subtract +ddrem1101 remainder 1234567890123456 1.000000000000001 -> 0.765432109876546 +ddrem1102 remainder 1234567890123456 1.00000000000001 -> 0.65432109876557 +ddrem1103 remainder 1234567890123456 1.0000000000001 -> 0.5432109876668 +ddrem1104 remainder 1234567890123455 4.000000000000001 -> 2.691358027469137 +ddrem1105 remainder 1234567890123456 4.000000000000001 -> 3.691358027469137 +ddrem1106 remainder 1234567890123456 4.9999999999999 -> 0.6913578024696 +ddrem1107 remainder 1234567890123456 4.99999999999999 -> 3.46913578024691 +ddrem1108 remainder 1234567890123456 4.999999999999999 -> 1.246913578024691 +ddrem1109 remainder 1234567890123456 5.000000000000001 -> 0.753086421975309 +ddrem1110 remainder 1234567890123456 5.00000000000001 -> 3.53086421975310 +ddrem1111 remainder 1234567890123456 5.0000000000001 -> 1.3086421975314 + -- Null tests ddrem1000 remainder 10 # -> NaN Invalid_operation ddrem1001 remainder # 10 -> NaN Invalid_operation diff --git a/Lib/test/decimaltestdata/ddRemainderNear.decTest b/Lib/test/decimaltestdata/ddRemainderNear.decTest index 1f3bafd98d3..dfcd3ebfa8c 100644 --- a/Lib/test/decimaltestdata/ddRemainderNear.decTest +++ b/Lib/test/decimaltestdata/ddRemainderNear.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 16 maxExponent: 384 @@ -599,6 +599,7 @@ ddrmn969 remaindernear 123e1 9876543210987654 -> 1230 ddrmn980 remaindernear 123e1 1000E299 -> 1.23E+3 -- 123E+1 internally + -- overflow and underflow tests [from divide] ddrmn1051 remaindernear 1e+277 1e-311 -> NaN Division_impossible ddrmn1052 remaindernear 1e+277 -1e-311 -> NaN Division_impossible @@ -609,6 +610,19 @@ ddrmn1056 remaindernear 1e-277 -1e+311 -> 1E-277 ddrmn1057 remaindernear -1e-277 1e+311 -> -1E-277 ddrmn1058 remaindernear -1e-277 -1e+311 -> -1E-277 +-- destructive subtract +ddrmn1100 remainderNear 1234567890123456 1.000000000000001 -> -0.234567890123455 +ddrmn1101 remainderNear 1234567890123456 1.00000000000001 -> -0.34567890123444 +ddrmn1102 remainderNear 1234567890123456 1.0000000000001 -> -0.4567890123333 +ddrmn1103 remainderNear 1234567890123455 4.000000000000001 -> -1.308641972530864 +ddrmn1104 remainderNear 1234567890123456 4.000000000000001 -> -0.308641972530864 +ddrmn1115 remainderNear 1234567890123456 4.9999999999999 -> 0.6913578024696 +ddrmn1116 remainderNear 1234567890123456 4.99999999999999 -> -1.53086421975308 +ddrmn1117 remainderNear 1234567890123456 4.999999999999999 -> 1.246913578024691 +ddrmn1118 remainderNear 1234567890123456 5.000000000000001 -> 0.753086421975309 +ddrmn1119 remainderNear 1234567890123456 5.00000000000001 -> -1.46913578024691 +ddrmn1110 remainderNear 1234567890123456 5.0000000000001 -> 1.3086421975314 + -- Null tests ddrmn1000 remaindernear 10 # -> NaN Invalid_operation ddrmn1001 remaindernear # 10 -> NaN Invalid_operation diff --git a/Lib/test/decimaltestdata/ddRotate.decTest b/Lib/test/decimaltestdata/ddRotate.decTest index 473f2f68bf7..e6294b3b102 100644 --- a/Lib/test/decimaltestdata/ddRotate.decTest +++ b/Lib/test/decimaltestdata/ddRotate.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 16 maxExponent: 384 diff --git a/Lib/test/decimaltestdata/ddSameQuantum.decTest b/Lib/test/decimaltestdata/ddSameQuantum.decTest index a396cd146e0..6f7db15b9d0 100644 --- a/Lib/test/decimaltestdata/ddSameQuantum.decTest +++ b/Lib/test/decimaltestdata/ddSameQuantum.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decDoubles. precision: 16 diff --git a/Lib/test/decimaltestdata/ddScaleB.decTest b/Lib/test/decimaltestdata/ddScaleB.decTest index 4091f869435..d0b92b51c92 100644 --- a/Lib/test/decimaltestdata/ddScaleB.decTest +++ b/Lib/test/decimaltestdata/ddScaleB.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 16 maxExponent: 384 diff --git a/Lib/test/decimaltestdata/ddShift.decTest b/Lib/test/decimaltestdata/ddShift.decTest index 2cbe06a126f..f2e80b36a4b 100644 --- a/Lib/test/decimaltestdata/ddShift.decTest +++ b/Lib/test/decimaltestdata/ddShift.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 16 maxExponent: 384 diff --git a/Lib/test/decimaltestdata/ddSubtract.decTest b/Lib/test/decimaltestdata/ddSubtract.decTest index 89895e90639..b10f5e4e68e 100644 --- a/Lib/test/decimaltestdata/ddSubtract.decTest +++ b/Lib/test/decimaltestdata/ddSubtract.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This set of tests are for decDoubles only; all arguments are -- representable in a decDouble diff --git a/Lib/test/decimaltestdata/ddToIntegral.decTest b/Lib/test/decimaltestdata/ddToIntegral.decTest index 1e3e573cba1..438d3471228 100644 --- a/Lib/test/decimaltestdata/ddToIntegral.decTest +++ b/Lib/test/decimaltestdata/ddToIntegral.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This set of tests tests the extended specification 'round-to-integral -- value-exact' operations (from IEEE 854, later modified in 754r). diff --git a/Lib/test/decimaltestdata/ddXor.decTest b/Lib/test/decimaltestdata/ddXor.decTest index 783fc2bf9a9..78e975054a0 100644 --- a/Lib/test/decimaltestdata/ddXor.decTest +++ b/Lib/test/decimaltestdata/ddXor.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 precision: 16 maxExponent: 384 diff --git a/Lib/test/decimaltestdata/decDouble.decTest b/Lib/test/decimaltestdata/decDouble.decTest index d5205b77abf..bdbf6787670 100644 --- a/Lib/test/decimaltestdata/decDouble.decTest +++ b/Lib/test/decimaltestdata/decDouble.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- decDouble tests dectest: ddAbs diff --git a/Lib/test/decimaltestdata/decQuad.decTest b/Lib/test/decimaltestdata/decQuad.decTest index 4d100695e1c..e9ec66356cf 100644 --- a/Lib/test/decimaltestdata/decQuad.decTest +++ b/Lib/test/decimaltestdata/decQuad.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- decQuad tests dectest: dqAbs diff --git a/Lib/test/decimaltestdata/decSingle.decTest b/Lib/test/decimaltestdata/decSingle.decTest index c661fe4c739..aae9b370de7 100644 --- a/Lib/test/decimaltestdata/decSingle.decTest +++ b/Lib/test/decimaltestdata/decSingle.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- decSingle tests dectest: dsBase diff --git a/Lib/test/decimaltestdata/divide.decTest b/Lib/test/decimaltestdata/divide.decTest index 1cb82b4ff3f..ae2bc0853a2 100644 --- a/Lib/test/decimaltestdata/divide.decTest +++ b/Lib/test/decimaltestdata/divide.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/divideint.decTest b/Lib/test/decimaltestdata/divideint.decTest index dfa17ca983d..1c940f56013 100644 --- a/Lib/test/decimaltestdata/divideint.decTest +++ b/Lib/test/decimaltestdata/divideint.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/dqAbs.decTest b/Lib/test/decimaltestdata/dqAbs.decTest index 01d1f308912..df010acf7b3 100644 --- a/Lib/test/decimaltestdata/dqAbs.decTest +++ b/Lib/test/decimaltestdata/dqAbs.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 clamp: 1 diff --git a/Lib/test/decimaltestdata/dqAdd.decTest b/Lib/test/decimaltestdata/dqAdd.decTest index 72238d33f91..256bc984554 100644 --- a/Lib/test/decimaltestdata/dqAdd.decTest +++ b/Lib/test/decimaltestdata/dqAdd.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This set of tests are for decQuads only; all arguments are -- representable in a decQuad diff --git a/Lib/test/decimaltestdata/dqAnd.decTest b/Lib/test/decimaltestdata/dqAnd.decTest index be3fb34d275..e00d44d75de 100644 --- a/Lib/test/decimaltestdata/dqAnd.decTest +++ b/Lib/test/decimaltestdata/dqAnd.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 clamp: 1 diff --git a/Lib/test/decimaltestdata/dqBase.decTest b/Lib/test/decimaltestdata/dqBase.decTest index 6cf2f7f4ead..3f2569beff1 100644 --- a/Lib/test/decimaltestdata/dqBase.decTest +++ b/Lib/test/decimaltestdata/dqBase.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This file tests base conversions from string to a decimal number -- and back to a string (in Scientific form) diff --git a/Lib/test/decimaltestdata/dqCanonical.decTest b/Lib/test/decimaltestdata/dqCanonical.decTest index a6b801ac1f5..e13c3478e04 100644 --- a/Lib/test/decimaltestdata/dqCanonical.decTest +++ b/Lib/test/decimaltestdata/dqCanonical.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This file tests that copy operations leave uncanonical operands -- unchanged, and vice versa diff --git a/Lib/test/decimaltestdata/dqClass.decTest b/Lib/test/decimaltestdata/dqClass.decTest index 185fbfc4930..a4703f75d57 100644 --- a/Lib/test/decimaltestdata/dqClass.decTest +++ b/Lib/test/decimaltestdata/dqClass.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- [New 2006.11.27] diff --git a/Lib/test/decimaltestdata/dqCompare.decTest b/Lib/test/decimaltestdata/dqCompare.decTest index 8947280376e..7fccdf163ee 100644 --- a/Lib/test/decimaltestdata/dqCompare.decTest +++ b/Lib/test/decimaltestdata/dqCompare.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- Note that we cannot assume add/subtract tests cover paths adequately, -- here, because the code might be quite different (comparison cannot diff --git a/Lib/test/decimaltestdata/dqCompareSig.decTest b/Lib/test/decimaltestdata/dqCompareSig.decTest index 43833eac904..36d5e9b0461 100644 --- a/Lib/test/decimaltestdata/dqCompareSig.decTest +++ b/Lib/test/decimaltestdata/dqCompareSig.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- Note that we cannot assume add/subtract tests cover paths adequately, -- here, because the code might be quite different (comparison cannot diff --git a/Lib/test/decimaltestdata/dqCompareTotal.decTest b/Lib/test/decimaltestdata/dqCompareTotal.decTest index d4a7c5ad838..f5cec0600b7 100644 --- a/Lib/test/decimaltestdata/dqCompareTotal.decTest +++ b/Lib/test/decimaltestdata/dqCompareTotal.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- Note that we cannot assume add/subtract tests cover paths adequately, -- here, because the code might be quite different (comparison cannot diff --git a/Lib/test/decimaltestdata/dqCompareTotalMag.decTest b/Lib/test/decimaltestdata/dqCompareTotalMag.decTest index 9461d6b1939..76c10899fe9 100644 --- a/Lib/test/decimaltestdata/dqCompareTotalMag.decTest +++ b/Lib/test/decimaltestdata/dqCompareTotalMag.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- Note that we cannot assume add/subtract tests cover paths adequately, -- here, because the code might be quite different (comparison cannot diff --git a/Lib/test/decimaltestdata/dqCopy.decTest b/Lib/test/decimaltestdata/dqCopy.decTest index b8337765bc5..b7688015c59 100644 --- a/Lib/test/decimaltestdata/dqCopy.decTest +++ b/Lib/test/decimaltestdata/dqCopy.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decQuads. extended: 1 diff --git a/Lib/test/decimaltestdata/dqCopyAbs.decTest b/Lib/test/decimaltestdata/dqCopyAbs.decTest index 91f4a68759d..427e6dd2eee 100644 --- a/Lib/test/decimaltestdata/dqCopyAbs.decTest +++ b/Lib/test/decimaltestdata/dqCopyAbs.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decQuads. extended: 1 diff --git a/Lib/test/decimaltestdata/dqCopyNegate.decTest b/Lib/test/decimaltestdata/dqCopyNegate.decTest index 22ac89c44cc..34a6f3c25d7 100644 --- a/Lib/test/decimaltestdata/dqCopyNegate.decTest +++ b/Lib/test/decimaltestdata/dqCopyNegate.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decQuads. extended: 1 diff --git a/Lib/test/decimaltestdata/dqCopySign.decTest b/Lib/test/decimaltestdata/dqCopySign.decTest index 8f275cdc6fa..902c9370690 100644 --- a/Lib/test/decimaltestdata/dqCopySign.decTest +++ b/Lib/test/decimaltestdata/dqCopySign.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decQuads. extended: 1 diff --git a/Lib/test/decimaltestdata/dqDivide.decTest b/Lib/test/decimaltestdata/dqDivide.decTest index a84e1d09a4a..1ea6d3194dc 100644 --- a/Lib/test/decimaltestdata/dqDivide.decTest +++ b/Lib/test/decimaltestdata/dqDivide.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 clamp: 1 diff --git a/Lib/test/decimaltestdata/dqDivideInt.decTest b/Lib/test/decimaltestdata/dqDivideInt.decTest index 953c1e0118d..b5eec63d02a 100644 --- a/Lib/test/decimaltestdata/dqDivideInt.decTest +++ b/Lib/test/decimaltestdata/dqDivideInt.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 clamp: 1 diff --git a/Lib/test/decimaltestdata/dqEncode.decTest b/Lib/test/decimaltestdata/dqEncode.decTest index ed3f328d0e9..fcb512bcde0 100644 --- a/Lib/test/decimaltestdata/dqEncode.decTest +++ b/Lib/test/decimaltestdata/dqEncode.decTest @@ -18,7 +18,7 @@ -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -- [Previously called decimal128.decTest] -version: 2.56 +version: 2.57 -- This set of tests is for the sixteen-byte concrete representation. -- Its characteristics are: @@ -468,3 +468,10 @@ decq828 apply #22080000000000000000000115afb55a -> 4294967294 decq829 apply #22080000000000000000000115afb55b -> 4294967295 decq830 apply #22080000000000000000000115afb57a -> 4294967296 decq831 apply #22080000000000000000000115afb57b -> 4294967297 + +-- VG testcase +decq840 apply #2080000000000000F294000000172636 -> 8.81125000000001349436E-1548 +decq841 apply #20800000000000008000000000000000 -> 8.000000000000000000E-1550 +decq842 apply #1EF98490000000010F6E4E0000000000 -> 7.049000000000010795488000000000000E-3097 +decq843 multiply #20800000000000008000000000000000 #2080000000000000F294000000172636 -> #1EF98490000000010F6E4E0000000000 Rounded + diff --git a/Lib/test/decimaltestdata/dqFMA.decTest b/Lib/test/decimaltestdata/dqFMA.decTest index 37d7749c2a5..f68fdf92480 100644 --- a/Lib/test/decimaltestdata/dqFMA.decTest +++ b/Lib/test/decimaltestdata/dqFMA.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 clamp: 1 @@ -1754,6 +1754,31 @@ dqadd375087 fma 1 12398765432112345678945678 1E-33 -> 123987 dqadd375088 fma 1 12398765432112345678945678 1E-34 -> 12398765432112345678945678.00000001 Inexact Rounded dqadd375089 fma 1 12398765432112345678945678 1E-35 -> 12398765432112345678945678.00000001 Inexact Rounded +-- Destructive subtract (from remainder tests) + +-- +++ some of these will be off-by-one remainder vs remainderNear + +dqfma4000 fma -1234567890123456789012345678901233 1.000000000000000000000000000000001 1234567890123456789012345678901234 -> -0.234567890123456789012345678901233 +dqfma4001 fma -1234567890123456789012345678901222 1.00000000000000000000000000000001 1234567890123456789012345678901234 -> -0.34567890123456789012345678901222 +dqfma4002 fma -1234567890123456789012345678901111 1.0000000000000000000000000000001 1234567890123456789012345678901234 -> -0.4567890123456789012345678901111 +dqfma4003 fma -308641972530864197253086419725314 4.000000000000000000000000000000001 1234567890123456789012345678901255 -> -1.308641972530864197253086419725314 +dqfma4004 fma -308641972530864197253086419725308 4.000000000000000000000000000000001 1234567890123456789012345678901234 -> 1.691358027469135802746913580274692 +dqfma4005 fma -246913578024691357802469135780252 4.9999999999999999999999999999999 1234567890123456789012345678901234 -> -1.3086421975308642197530864219748 +dqfma4006 fma -246913578024691357802469135780247 4.99999999999999999999999999999999 1234567890123456789012345678901234 -> 1.46913578024691357802469135780247 +dqfma4007 fma -246913578024691357802469135780247 4.999999999999999999999999999999999 1234567890123456789012345678901234 -> -0.753086421975308642197530864219753 +dqfma4008 fma -246913578024691357802469135780247 5.000000000000000000000000000000001 1234567890123456789012345678901234 -> -1.246913578024691357802469135780247 +dqfma4009 fma -246913578024691357802469135780246 5.00000000000000000000000000000001 1234567890123456789012345678901234 -> 1.53086421975308642197530864219754 +dqfma4010 fma -246913578024691357802469135780242 5.0000000000000000000000000000001 1234567890123456789012345678901234 -> -0.6913578024691357802469135780242 +dqfma4011 fma -1234567890123456789012345678901232 1.000000000000000000000000000000001 1234567890123456789012345678901234 -> 0.765432109876543210987654321098768 +dqfma4012 fma -1234567890123456789012345678901221 1.00000000000000000000000000000001 1234567890123456789012345678901234 -> 0.65432109876543210987654321098779 +dqfma4013 fma -1234567890123456789012345678901110 1.0000000000000000000000000000001 1234567890123456789012345678901234 -> 0.5432109876543210987654321098890 +dqfma4014 fma -308641972530864197253086419725313 4.000000000000000000000000000000001 1234567890123456789012345678901255 -> 2.691358027469135802746913580274687 +dqfma4015 fma -308641972530864197253086419725308 4.000000000000000000000000000000001 1234567890123456789012345678901234 -> 1.691358027469135802746913580274692 +dqfma4016 fma -246913578024691357802469135780251 4.9999999999999999999999999999999 1234567890123456789012345678901234 -> 3.6913578024691357802469135780251 +dqfma4017 fma -246913578024691357802469135780247 4.99999999999999999999999999999999 1234567890123456789012345678901234 -> 1.46913578024691357802469135780247 +dqfma4018 fma -246913578024691357802469135780246 4.999999999999999999999999999999999 1234567890123456789012345678901234 -> 4.246913578024691357802469135780246 +dqfma4019 fma -246913578024691357802469135780241 5.0000000000000000000000000000001 1234567890123456789012345678901234 -> 4.3086421975308642197530864219759 + -- Null tests dqadd39990 fma 1 10 # -> NaN Invalid_operation dqadd39991 fma 1 # 10 -> NaN Invalid_operation diff --git a/Lib/test/decimaltestdata/dqInvert.decTest b/Lib/test/decimaltestdata/dqInvert.decTest index 94ba93c76aa..19161c2f13e 100644 --- a/Lib/test/decimaltestdata/dqInvert.decTest +++ b/Lib/test/decimaltestdata/dqInvert.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 clamp: 1 diff --git a/Lib/test/decimaltestdata/dqLogB.decTest b/Lib/test/decimaltestdata/dqLogB.decTest index baa6d1e6b60..d6cf831411a 100644 --- a/Lib/test/decimaltestdata/dqLogB.decTest +++ b/Lib/test/decimaltestdata/dqLogB.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 clamp: 1 diff --git a/Lib/test/decimaltestdata/dqMax.decTest b/Lib/test/decimaltestdata/dqMax.decTest index a00ec1c3049..a3ba64c8911 100644 --- a/Lib/test/decimaltestdata/dqMax.decTest +++ b/Lib/test/decimaltestdata/dqMax.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- we assume that base comparison is tested in compare.decTest, so -- these mainly cover special cases and rounding diff --git a/Lib/test/decimaltestdata/dqMaxMag.decTest b/Lib/test/decimaltestdata/dqMaxMag.decTest index 53eb82c13b6..01b27935e77 100644 --- a/Lib/test/decimaltestdata/dqMaxMag.decTest +++ b/Lib/test/decimaltestdata/dqMaxMag.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- we assume that base comparison is tested in compare.decTest, so -- these mainly cover special cases and rounding diff --git a/Lib/test/decimaltestdata/dqMin.decTest b/Lib/test/decimaltestdata/dqMin.decTest index 9e34694d93e..1b82be2fd02 100644 --- a/Lib/test/decimaltestdata/dqMin.decTest +++ b/Lib/test/decimaltestdata/dqMin.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- we assume that base comparison is tested in compare.decTest, so -- these mainly cover special cases and rounding diff --git a/Lib/test/decimaltestdata/dqMinMag.decTest b/Lib/test/decimaltestdata/dqMinMag.decTest index 733acfdd12f..6d5e4b5266c 100644 --- a/Lib/test/decimaltestdata/dqMinMag.decTest +++ b/Lib/test/decimaltestdata/dqMinMag.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- we assume that base comparison is tested in compare.decTest, so -- these mainly cover special cases and rounding diff --git a/Lib/test/decimaltestdata/dqMinus.decTest b/Lib/test/decimaltestdata/dqMinus.decTest index 50ac85a3351..bf69938a172 100644 --- a/Lib/test/decimaltestdata/dqMinus.decTest +++ b/Lib/test/decimaltestdata/dqMinus.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decQuads. extended: 1 diff --git a/Lib/test/decimaltestdata/dqMultiply.decTest b/Lib/test/decimaltestdata/dqMultiply.decTest index a6f85e0fdc5..c87cc8fd712 100644 --- a/Lib/test/decimaltestdata/dqMultiply.decTest +++ b/Lib/test/decimaltestdata/dqMultiply.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This set of tests are for decQuads only; all arguments are -- representable in a decQuad @@ -456,18 +456,134 @@ dqmul908 multiply 9.999999999999999999999999999999999E-6143 0.0999999999999999 -- hugest dqmul909 multiply 9999999999999999999999999999999999 9999999999999999999999999999999999 -> 9.999999999999999999999999999999998E+67 Inexact Rounded +-- VG case +dqmul910 multiply 8.81125000000001349436E-1548 8.000000000000000000E-1550 -> 7.049000000000010795488000000000000E-3097 Rounded -- Examples from SQL proposal (Krishna Kulkarni) precision: 34 rounding: half_up maxExponent: 6144 minExponent: -6143 -dqmul1001 multiply 130E-2 120E-2 -> 1.5600 -dqmul1002 multiply 130E-2 12E-1 -> 1.560 -dqmul1003 multiply 130E-2 1E0 -> 1.30 -dqmul1004 multiply 1E2 1E4 -> 1E+6 +dqmul911 multiply 130E-2 120E-2 -> 1.5600 +dqmul912 multiply 130E-2 12E-1 -> 1.560 +dqmul913 multiply 130E-2 1E0 -> 1.30 +dqmul914 multiply 1E2 1E4 -> 1E+6 + +-- power-of-ten edge cases +dqmul1001 multiply 1 10 -> 10 +dqmul1002 multiply 1 100 -> 100 +dqmul1003 multiply 1 1000 -> 1000 +dqmul1004 multiply 1 10000 -> 10000 +dqmul1005 multiply 1 100000 -> 100000 +dqmul1006 multiply 1 1000000 -> 1000000 +dqmul1007 multiply 1 10000000 -> 10000000 +dqmul1008 multiply 1 100000000 -> 100000000 +dqmul1009 multiply 1 1000000000 -> 1000000000 +dqmul1010 multiply 1 10000000000 -> 10000000000 +dqmul1011 multiply 1 100000000000 -> 100000000000 +dqmul1012 multiply 1 1000000000000 -> 1000000000000 +dqmul1013 multiply 1 10000000000000 -> 10000000000000 +dqmul1014 multiply 1 100000000000000 -> 100000000000000 +dqmul1015 multiply 1 1000000000000000 -> 1000000000000000 + +dqmul1016 multiply 1 1000000000000000000 -> 1000000000000000000 +dqmul1017 multiply 1 100000000000000000000000000 -> 100000000000000000000000000 +dqmul1018 multiply 1 1000000000000000000000000000 -> 1000000000000000000000000000 +dqmul1019 multiply 1 10000000000000000000000000000 -> 10000000000000000000000000000 +dqmul1020 multiply 1 1000000000000000000000000000000000 -> 1000000000000000000000000000000000 + +dqmul1021 multiply 10 1 -> 10 +dqmul1022 multiply 10 10 -> 100 +dqmul1023 multiply 10 100 -> 1000 +dqmul1024 multiply 10 1000 -> 10000 +dqmul1025 multiply 10 10000 -> 100000 +dqmul1026 multiply 10 100000 -> 1000000 +dqmul1027 multiply 10 1000000 -> 10000000 +dqmul1028 multiply 10 10000000 -> 100000000 +dqmul1029 multiply 10 100000000 -> 1000000000 +dqmul1030 multiply 10 1000000000 -> 10000000000 +dqmul1031 multiply 10 10000000000 -> 100000000000 +dqmul1032 multiply 10 100000000000 -> 1000000000000 +dqmul1033 multiply 10 1000000000000 -> 10000000000000 +dqmul1034 multiply 10 10000000000000 -> 100000000000000 +dqmul1035 multiply 10 100000000000000 -> 1000000000000000 + +dqmul1036 multiply 10 100000000000000000 -> 1000000000000000000 +dqmul1037 multiply 10 10000000000000000000000000 -> 100000000000000000000000000 +dqmul1038 multiply 10 100000000000000000000000000 -> 1000000000000000000000000000 +dqmul1039 multiply 10 1000000000000000000000000000 -> 10000000000000000000000000000 +dqmul1040 multiply 10 100000000000000000000000000000000 -> 1000000000000000000000000000000000 + +dqmul1041 multiply 100 0.1 -> 10.0 +dqmul1042 multiply 100 1 -> 100 +dqmul1043 multiply 100 10 -> 1000 +dqmul1044 multiply 100 100 -> 10000 +dqmul1045 multiply 100 1000 -> 100000 +dqmul1046 multiply 100 10000 -> 1000000 +dqmul1047 multiply 100 100000 -> 10000000 +dqmul1048 multiply 100 1000000 -> 100000000 +dqmul1049 multiply 100 10000000 -> 1000000000 +dqmul1050 multiply 100 100000000 -> 10000000000 +dqmul1051 multiply 100 1000000000 -> 100000000000 +dqmul1052 multiply 100 10000000000 -> 1000000000000 +dqmul1053 multiply 100 100000000000 -> 10000000000000 +dqmul1054 multiply 100 1000000000000 -> 100000000000000 +dqmul1055 multiply 100 10000000000000 -> 1000000000000000 + +dqmul1056 multiply 100 10000000000000000 -> 1000000000000000000 +dqmul1057 multiply 100 1000000000000000000000000 -> 100000000000000000000000000 +dqmul1058 multiply 100 10000000000000000000000000 -> 1000000000000000000000000000 +dqmul1059 multiply 100 100000000000000000000000000 -> 10000000000000000000000000000 +dqmul1060 multiply 100 10000000000000000000000000000000 -> 1000000000000000000000000000000000 + +dqmul1061 multiply 1000 0.01 -> 10.00 +dqmul1062 multiply 1000 0.1 -> 100.0 +dqmul1063 multiply 1000 1 -> 1000 +dqmul1064 multiply 1000 10 -> 10000 +dqmul1065 multiply 1000 100 -> 100000 +dqmul1066 multiply 1000 1000 -> 1000000 +dqmul1067 multiply 1000 10000 -> 10000000 +dqmul1068 multiply 1000 100000 -> 100000000 +dqmul1069 multiply 1000 1000000 -> 1000000000 +dqmul1070 multiply 1000 10000000 -> 10000000000 +dqmul1071 multiply 1000 100000000 -> 100000000000 +dqmul1072 multiply 1000 1000000000 -> 1000000000000 +dqmul1073 multiply 1000 10000000000 -> 10000000000000 +dqmul1074 multiply 1000 100000000000 -> 100000000000000 +dqmul1075 multiply 1000 1000000000000 -> 1000000000000000 + +dqmul1076 multiply 1000 1000000000000000 -> 1000000000000000000 +dqmul1077 multiply 1000 100000000000000000000000 -> 100000000000000000000000000 +dqmul1078 multiply 1000 1000000000000000000000000 -> 1000000000000000000000000000 +dqmul1079 multiply 1000 10000000000000000000000000 -> 10000000000000000000000000000 +dqmul1080 multiply 1000 1000000000000000000000000000000 -> 1000000000000000000000000000000000 + +dqmul1081 multiply 10000 0.001 -> 10.000 +dqmul1082 multiply 10000 0.01 -> 100.00 +dqmul1083 multiply 10000 0.1 -> 1000.0 +dqmul1084 multiply 10000 1 -> 10000 +dqmul1085 multiply 10000 10 -> 100000 +dqmul1086 multiply 10000 100 -> 1000000 +dqmul1087 multiply 10000 1000 -> 10000000 +dqmul1088 multiply 10000 10000 -> 100000000 +dqmul1089 multiply 10000 100000 -> 1000000000 +dqmul1090 multiply 10000 1000000 -> 10000000000 +dqmul1091 multiply 10000 10000000 -> 100000000000 +dqmul1092 multiply 10000 100000000 -> 1000000000000 +dqmul1093 multiply 10000 1000000000 -> 10000000000000 +dqmul1094 multiply 10000 10000000000 -> 100000000000000 +dqmul1095 multiply 10000 100000000000 -> 1000000000000000 + +dqmul1096 multiply 10000 100000000000000 -> 1000000000000000000 +dqmul1097 multiply 10000 10000000000000000000000 -> 100000000000000000000000000 +dqmul1098 multiply 10000 100000000000000000000000 -> 1000000000000000000000000000 +dqmul1099 multiply 10000 1000000000000000000000000 -> 10000000000000000000000000000 +dqmul1100 multiply 10000 100000000000000000000000000000 -> 1000000000000000000000000000000000 + +dqmul1107 multiply 10000 99999999999 -> 999999999990000 +dqmul1108 multiply 10000 99999999999 -> 999999999990000 -- Null tests -dqmul990 multiply 10 # -> NaN Invalid_operation -dqmul991 multiply # 10 -> NaN Invalid_operation +dqmul9990 multiply 10 # -> NaN Invalid_operation +dqmul9991 multiply # 10 -> NaN Invalid_operation diff --git a/Lib/test/decimaltestdata/dqNextMinus.decTest b/Lib/test/decimaltestdata/dqNextMinus.decTest index 48808168756..e1e3b065681 100644 --- a/Lib/test/decimaltestdata/dqNextMinus.decTest +++ b/Lib/test/decimaltestdata/dqNextMinus.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decQuads. extended: 1 diff --git a/Lib/test/decimaltestdata/dqNextPlus.decTest b/Lib/test/decimaltestdata/dqNextPlus.decTest index 8c0ac45e26a..973c8eb3b83 100644 --- a/Lib/test/decimaltestdata/dqNextPlus.decTest +++ b/Lib/test/decimaltestdata/dqNextPlus.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decQuads. extended: 1 diff --git a/Lib/test/decimaltestdata/dqNextToward.decTest b/Lib/test/decimaltestdata/dqNextToward.decTest index e5349513b2c..0eb677095df 100644 --- a/Lib/test/decimaltestdata/dqNextToward.decTest +++ b/Lib/test/decimaltestdata/dqNextToward.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decQuads. extended: 1 diff --git a/Lib/test/decimaltestdata/dqOr.decTest b/Lib/test/decimaltestdata/dqOr.decTest index 60470ea45a7..093edcb21a6 100644 --- a/Lib/test/decimaltestdata/dqOr.decTest +++ b/Lib/test/decimaltestdata/dqOr.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 clamp: 1 diff --git a/Lib/test/decimaltestdata/dqPlus.decTest b/Lib/test/decimaltestdata/dqPlus.decTest index 5dc5a68c5d3..ad5b7be261d 100644 --- a/Lib/test/decimaltestdata/dqPlus.decTest +++ b/Lib/test/decimaltestdata/dqPlus.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decQuads. extended: 1 diff --git a/Lib/test/decimaltestdata/dqQuantize.decTest b/Lib/test/decimaltestdata/dqQuantize.decTest index aa8cf2e5388..4c3e1ea6f93 100644 --- a/Lib/test/decimaltestdata/dqQuantize.decTest +++ b/Lib/test/decimaltestdata/dqQuantize.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- Most of the tests here assume a "regular pattern", where the -- sign and coefficient are +1. diff --git a/Lib/test/decimaltestdata/dqReduce.decTest b/Lib/test/decimaltestdata/dqReduce.decTest index 183e9dcf2c2..c0690400a75 100644 --- a/Lib/test/decimaltestdata/dqReduce.decTest +++ b/Lib/test/decimaltestdata/dqReduce.decTest @@ -18,7 +18,7 @@ -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 clamp: 1 diff --git a/Lib/test/decimaltestdata/dqRemainder.decTest b/Lib/test/decimaltestdata/dqRemainder.decTest index e30fde7d247..14c358ce23e 100644 --- a/Lib/test/decimaltestdata/dqRemainder.decTest +++ b/Lib/test/decimaltestdata/dqRemainder.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 clamp: 1 @@ -580,6 +580,17 @@ dqrem1058 remainder -1e-277 -1e+311 -> -1E-277 -- Gyuris example dqrem1070 remainder 8.336804418094040989630006819881709E-6143 8.336804418094040989630006819889000E-6143 -> 8.336804418094040989630006819881709E-6143 +-- destructive subtract +dqrem1120 remainder 1234567890123456789012345678901234 1.000000000000000000000000000000001 -> 0.765432109876543210987654321098768 +dqrem1121 remainder 1234567890123456789012345678901234 1.00000000000000000000000000000001 -> 0.65432109876543210987654321098779 +dqrem1122 remainder 1234567890123456789012345678901234 1.0000000000000000000000000000001 -> 0.5432109876543210987654321098890 +dqrem1123 remainder 1234567890123456789012345678901255 4.000000000000000000000000000000001 -> 2.691358027469135802746913580274687 +dqrem1124 remainder 1234567890123456789012345678901234 4.000000000000000000000000000000001 -> 1.691358027469135802746913580274692 +dqrem1125 remainder 1234567890123456789012345678901234 4.9999999999999999999999999999999 -> 3.6913578024691357802469135780251 +dqrem1126 remainder 1234567890123456789012345678901234 4.99999999999999999999999999999999 -> 1.46913578024691357802469135780247 +dqrem1127 remainder 1234567890123456789012345678901234 4.999999999999999999999999999999999 -> 4.246913578024691357802469135780246 +dqrem1128 remainder 1234567890123456789012345678901234 5.0000000000000000000000000000001 -> 4.3086421975308642197530864219759 + -- Null tests dqrem1000 remainder 10 # -> NaN Invalid_operation dqrem1001 remainder # 10 -> NaN Invalid_operation diff --git a/Lib/test/decimaltestdata/dqRemainderNear.decTest b/Lib/test/decimaltestdata/dqRemainderNear.decTest index b62b79fbce2..9074ec49863 100644 --- a/Lib/test/decimaltestdata/dqRemainderNear.decTest +++ b/Lib/test/decimaltestdata/dqRemainderNear.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 clamp: 1 @@ -612,6 +612,19 @@ dqrmn1058 remaindernear -1e-277 -1e+311 -> -1E-277 -- Gyuris example dqrmn1070 remainder 8.336804418094040989630006819881709E-6143 8.336804418094040989630006819889000E-6143 -> 8.336804418094040989630006819881709E-6143 +-- destructive subtract +dqrmn1101 remaindernear 1234567890123456789012345678901234 1.000000000000000000000000000000001 -> -0.234567890123456789012345678901233 +dqrmn1102 remaindernear 1234567890123456789012345678901234 1.00000000000000000000000000000001 -> -0.34567890123456789012345678901222 +dqrmn1103 remaindernear 1234567890123456789012345678901234 1.0000000000000000000000000000001 -> -0.4567890123456789012345678901111 +dqrmn1104 remaindernear 1234567890123456789012345678901255 4.000000000000000000000000000000001 -> -1.308641972530864197253086419725314 +dqrmn1105 remaindernear 1234567890123456789012345678901234 4.000000000000000000000000000000001 -> 1.691358027469135802746913580274692 +dqrmn1106 remaindernear 1234567890123456789012345678901234 4.9999999999999999999999999999999 -> -1.3086421975308642197530864219748 +dqrmn1107 remaindernear 1234567890123456789012345678901234 4.99999999999999999999999999999999 -> 1.46913578024691357802469135780247 +dqrmn1108 remaindernear 1234567890123456789012345678901234 4.999999999999999999999999999999999 -> -0.753086421975308642197530864219753 +dqrmn1109 remaindernear 1234567890123456789012345678901234 5.000000000000000000000000000000001 -> -1.246913578024691357802469135780247 +dqrmn1110 remaindernear 1234567890123456789012345678901234 5.00000000000000000000000000000001 -> 1.53086421975308642197530864219754 +dqrmn1111 remaindernear 1234567890123456789012345678901234 5.0000000000000000000000000000001 -> -0.6913578024691357802469135780242 + -- Null tests dqrmn1000 remaindernear 10 # -> NaN Invalid_operation dqrmn1001 remaindernear # 10 -> NaN Invalid_operation diff --git a/Lib/test/decimaltestdata/dqRotate.decTest b/Lib/test/decimaltestdata/dqRotate.decTest index f21813c5658..671cd958452 100644 --- a/Lib/test/decimaltestdata/dqRotate.decTest +++ b/Lib/test/decimaltestdata/dqRotate.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 clamp: 1 diff --git a/Lib/test/decimaltestdata/dqSameQuantum.decTest b/Lib/test/decimaltestdata/dqSameQuantum.decTest index e7264cb396a..acf72666cbf 100644 --- a/Lib/test/decimaltestdata/dqSameQuantum.decTest +++ b/Lib/test/decimaltestdata/dqSameQuantum.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- All operands and results are decQuads. extended: 1 diff --git a/Lib/test/decimaltestdata/dqScaleB.decTest b/Lib/test/decimaltestdata/dqScaleB.decTest index 88a3f9debc0..7355cf05939 100644 --- a/Lib/test/decimaltestdata/dqScaleB.decTest +++ b/Lib/test/decimaltestdata/dqScaleB.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 clamp: 1 diff --git a/Lib/test/decimaltestdata/dqShift.decTest b/Lib/test/decimaltestdata/dqShift.decTest index e728ec5b40d..33df91f2875 100644 --- a/Lib/test/decimaltestdata/dqShift.decTest +++ b/Lib/test/decimaltestdata/dqShift.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 clamp: 1 diff --git a/Lib/test/decimaltestdata/dqSubtract.decTest b/Lib/test/decimaltestdata/dqSubtract.decTest index 923742c0e2c..d2df184b812 100644 --- a/Lib/test/decimaltestdata/dqSubtract.decTest +++ b/Lib/test/decimaltestdata/dqSubtract.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This set of tests are for decQuads only; all arguments are -- representable in a decQuad diff --git a/Lib/test/decimaltestdata/dqToIntegral.decTest b/Lib/test/decimaltestdata/dqToIntegral.decTest index ac50a4ad885..449dead51a3 100644 --- a/Lib/test/decimaltestdata/dqToIntegral.decTest +++ b/Lib/test/decimaltestdata/dqToIntegral.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This set of tests tests the extended specification 'round-to-integral -- value-exact' operations (from IEEE 854, later modified in 754r). diff --git a/Lib/test/decimaltestdata/dqXor.decTest b/Lib/test/decimaltestdata/dqXor.decTest index 61bdbe20d83..d9e9af670c1 100644 --- a/Lib/test/decimaltestdata/dqXor.decTest +++ b/Lib/test/decimaltestdata/dqXor.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 clamp: 1 diff --git a/Lib/test/decimaltestdata/dsBase.decTest b/Lib/test/decimaltestdata/dsBase.decTest index d0632fd9921..e2fb4ba25bc 100644 --- a/Lib/test/decimaltestdata/dsBase.decTest +++ b/Lib/test/decimaltestdata/dsBase.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This file tests base conversions from string to a decimal number -- and back to a string (in Scientific form) @@ -1058,4 +1058,5 @@ dsbas1106 toSci +1E-398 -> 0E-101 Inexact Rounded Subnormal Underflow Clamped dsbas1107 toSci +1E-383 -> 0E-101 Inexact Rounded Subnormal Underflow Clamped dsbas1108 toSci +9.999999999999999E+384 -> Infinity Overflow Inexact Rounded - +-- narrowing case +dsbas1110 toSci 2.000000000000000E-99 -> 2.00E-99 Rounded Subnormal diff --git a/Lib/test/decimaltestdata/dsEncode.decTest b/Lib/test/decimaltestdata/dsEncode.decTest index 185ddc7a77e..7e72d4b04af 100644 --- a/Lib/test/decimaltestdata/dsEncode.decTest +++ b/Lib/test/decimaltestdata/dsEncode.decTest @@ -18,7 +18,7 @@ -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -- [Previously called decimal32.decTest] -version: 2.56 +version: 2.57 -- This set of tests is for the four-byte concrete representation. -- Its characteristics are: @@ -367,3 +367,6 @@ decs785 apply #225001ff -> 999 decs786 apply #225002ff -> 999 decs787 apply #225003ff -> 999 +-- narrowing case +decs790 apply 2.00E-99 -> #00000100 Subnormal +decs791 apply #00000100 -> 2.00E-99 Subnormal diff --git a/Lib/test/decimaltestdata/exp.decTest b/Lib/test/decimaltestdata/exp.decTest index c07ed5a3f81..97256e48526 100644 --- a/Lib/test/decimaltestdata/exp.decTest +++ b/Lib/test/decimaltestdata/exp.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- Tests of the exponential funtion. Currently all testcases here -- show results which are correctly rounded (within <= 0.5 ulp). diff --git a/Lib/test/decimaltestdata/fma.decTest b/Lib/test/decimaltestdata/fma.decTest index aa4c0ba0e85..d7caa2611d9 100644 --- a/Lib/test/decimaltestdata/fma.decTest +++ b/Lib/test/decimaltestdata/fma.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/inexact.decTest b/Lib/test/decimaltestdata/inexact.decTest index b61c85a67bf..896e6c839c2 100644 --- a/Lib/test/decimaltestdata/inexact.decTest +++ b/Lib/test/decimaltestdata/inexact.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/invert.decTest b/Lib/test/decimaltestdata/invert.decTest index 19fdeebac86..7bccb1fffc3 100644 --- a/Lib/test/decimaltestdata/invert.decTest +++ b/Lib/test/decimaltestdata/invert.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/ln.decTest b/Lib/test/decimaltestdata/ln.decTest index 44ae4d25997..16e247e9af5 100644 --- a/Lib/test/decimaltestdata/ln.decTest +++ b/Lib/test/decimaltestdata/ln.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 16 diff --git a/Lib/test/decimaltestdata/log10.decTest b/Lib/test/decimaltestdata/log10.decTest index 9841acb42e3..bb033a808ea 100644 --- a/Lib/test/decimaltestdata/log10.decTest +++ b/Lib/test/decimaltestdata/log10.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This emphasises the testing of notable cases, as they will often -- have unusual paths (especially the 10**n results). diff --git a/Lib/test/decimaltestdata/logb.decTest b/Lib/test/decimaltestdata/logb.decTest index 577f7a43d50..a672206e539 100644 --- a/Lib/test/decimaltestdata/logb.decTest +++ b/Lib/test/decimaltestdata/logb.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This emphasises the testing of notable cases, as they will often -- have unusual paths (especially the 10**n results). diff --git a/Lib/test/decimaltestdata/max.decTest b/Lib/test/decimaltestdata/max.decTest index 88d0b5e1b1b..d7a6a944b4e 100644 --- a/Lib/test/decimaltestdata/max.decTest +++ b/Lib/test/decimaltestdata/max.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- we assume that base comparison is tested in compare.decTest, so -- these mainly cover special cases and rounding diff --git a/Lib/test/decimaltestdata/maxmag.decTest b/Lib/test/decimaltestdata/maxmag.decTest index b14d015e416..012976662e9 100644 --- a/Lib/test/decimaltestdata/maxmag.decTest +++ b/Lib/test/decimaltestdata/maxmag.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- we assume that base comparison is tested in compare.decTest, so -- these mainly cover special cases and rounding diff --git a/Lib/test/decimaltestdata/min.decTest b/Lib/test/decimaltestdata/min.decTest index 345e3ebd588..b69507984d3 100644 --- a/Lib/test/decimaltestdata/min.decTest +++ b/Lib/test/decimaltestdata/min.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- we assume that base comparison is tested in compare.decTest, so -- these mainly cover special cases and rounding diff --git a/Lib/test/decimaltestdata/minmag.decTest b/Lib/test/decimaltestdata/minmag.decTest index fa9d927ecbf..547ccffceaf 100644 --- a/Lib/test/decimaltestdata/minmag.decTest +++ b/Lib/test/decimaltestdata/minmag.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- we assume that base comparison is tested in compare.decTest, so -- these mainly cover special cases and rounding diff --git a/Lib/test/decimaltestdata/minus.decTest b/Lib/test/decimaltestdata/minus.decTest index e9afc3a091a..f9112860304 100644 --- a/Lib/test/decimaltestdata/minus.decTest +++ b/Lib/test/decimaltestdata/minus.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This set of tests primarily tests the existence of the operator. -- Subtraction, rounding, and more overflows are tested elsewhere. diff --git a/Lib/test/decimaltestdata/multiply.decTest b/Lib/test/decimaltestdata/multiply.decTest index 71f591ab7cd..a6c7ebe868a 100644 --- a/Lib/test/decimaltestdata/multiply.decTest +++ b/Lib/test/decimaltestdata/multiply.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/nextminus.decTest b/Lib/test/decimaltestdata/nextminus.decTest index 200580dc9ea..be33158022a 100644 --- a/Lib/test/decimaltestdata/nextminus.decTest +++ b/Lib/test/decimaltestdata/nextminus.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/nextplus.decTest b/Lib/test/decimaltestdata/nextplus.decTest index 01815ee0bbb..6cee16a0e50 100644 --- a/Lib/test/decimaltestdata/nextplus.decTest +++ b/Lib/test/decimaltestdata/nextplus.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/nexttoward.decTest b/Lib/test/decimaltestdata/nexttoward.decTest index cb60f57ae58..aa1891a82f7 100644 --- a/Lib/test/decimaltestdata/nexttoward.decTest +++ b/Lib/test/decimaltestdata/nexttoward.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/or.decTest b/Lib/test/decimaltestdata/or.decTest index 928939e77dd..ace901b6619 100644 --- a/Lib/test/decimaltestdata/or.decTest +++ b/Lib/test/decimaltestdata/or.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/plus.decTest b/Lib/test/decimaltestdata/plus.decTest index 9af4c0e990e..1df3dfe3fd4 100644 --- a/Lib/test/decimaltestdata/plus.decTest +++ b/Lib/test/decimaltestdata/plus.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This set of tests primarily tests the existence of the operator. -- Addition and rounding, and most overflows, are tested elsewhere. diff --git a/Lib/test/decimaltestdata/power.decTest b/Lib/test/decimaltestdata/power.decTest index 78c1e072fd1..69e8644e6c8 100644 --- a/Lib/test/decimaltestdata/power.decTest +++ b/Lib/test/decimaltestdata/power.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- In addition to the power operator testcases here, see also the file -- powersqrt.decTest which includes all the tests from diff --git a/Lib/test/decimaltestdata/powersqrt.decTest b/Lib/test/decimaltestdata/powersqrt.decTest index 36e5cbbbc36..6f79f6c7c66 100644 --- a/Lib/test/decimaltestdata/powersqrt.decTest +++ b/Lib/test/decimaltestdata/powersqrt.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- These testcases are taken from squareroot.decTest but are -- evaluated using the power operator. The differences in results diff --git a/Lib/test/decimaltestdata/quantize.decTest b/Lib/test/decimaltestdata/quantize.decTest index a60f1bf553f..1e5511ff0e0 100644 --- a/Lib/test/decimaltestdata/quantize.decTest +++ b/Lib/test/decimaltestdata/quantize.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- Most of the tests here assume a "regular pattern", where the -- sign and coefficient are +1. diff --git a/Lib/test/decimaltestdata/randomBound32.decTest b/Lib/test/decimaltestdata/randomBound32.decTest index 7f115adcfed..0d5881d8f64 100644 --- a/Lib/test/decimaltestdata/randomBound32.decTest +++ b/Lib/test/decimaltestdata/randomBound32.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.55 +version: 2.57 -- These testcases test calculations at precisions 31, 32, and 33, to -- exercise the boundaries around 2**5 diff --git a/Lib/test/decimaltestdata/randoms.decTest b/Lib/test/decimaltestdata/randoms.decTest index 1529aec60b2..a03b8d56437 100644 --- a/Lib/test/decimaltestdata/randoms.decTest +++ b/Lib/test/decimaltestdata/randoms.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 maxexponent: 999999999 diff --git a/Lib/test/decimaltestdata/reduce.decTest b/Lib/test/decimaltestdata/reduce.decTest index ddce0c9f921..189a687e97a 100644 --- a/Lib/test/decimaltestdata/reduce.decTest +++ b/Lib/test/decimaltestdata/reduce.decTest @@ -19,7 +19,7 @@ ------------------------------------------------------------------------ -- [This used to be called normalize.] -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/remainder.decTest b/Lib/test/decimaltestdata/remainder.decTest index 4c92d0c93b8..1a51c265c42 100644 --- a/Lib/test/decimaltestdata/remainder.decTest +++ b/Lib/test/decimaltestdata/remainder.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/remainderNear.decTest b/Lib/test/decimaltestdata/remainderNear.decTest index cfca91b14ad..fdc1bd87032 100644 --- a/Lib/test/decimaltestdata/remainderNear.decTest +++ b/Lib/test/decimaltestdata/remainderNear.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.55 +version: 2.57 extended: 1 precision: 9 @@ -413,6 +413,18 @@ rmnx605 remaindernear 7.7 8 -> -0.3 rmnx606 remaindernear 31.5 3 -> 1.5 -- i=10 rmnx607 remaindernear 34.5 3 -> -1.5 -- i=11 +-- zero signs +rmnx650 remaindernear 1 1 -> 0 +rmnx651 remaindernear -1 1 -> -0 +rmnx652 remaindernear 1 -1 -> 0 +rmnx653 remaindernear -1 -1 -> -0 +rmnx654 remaindernear 0 1 -> 0 +rmnx655 remaindernear -0 1 -> -0 +rmnx656 remaindernear 0 -1 -> 0 +rmnx657 remaindernear -0 -1 -> -0 +rmnx658 remaindernear 0.00 1 -> 0.00 +rmnx659 remaindernear -0.00 1 -> -0.00 + -- Specials rmnx680 remaindernear Inf -Inf -> NaN Invalid_operation rmnx681 remaindernear Inf -1000 -> NaN Invalid_operation diff --git a/Lib/test/decimaltestdata/rescale.decTest b/Lib/test/decimaltestdata/rescale.decTest index 30597db113c..882f5706a50 100644 --- a/Lib/test/decimaltestdata/rescale.decTest +++ b/Lib/test/decimaltestdata/rescale.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- [obsolete] Quantize.decTest has the improved version diff --git a/Lib/test/decimaltestdata/rotate.decTest b/Lib/test/decimaltestdata/rotate.decTest index c5ced5952b6..32dbd537c49 100644 --- a/Lib/test/decimaltestdata/rotate.decTest +++ b/Lib/test/decimaltestdata/rotate.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/rounding.decTest b/Lib/test/decimaltestdata/rounding.decTest index d24fbfb37fe..82ca1b0fffb 100644 --- a/Lib/test/decimaltestdata/rounding.decTest +++ b/Lib/test/decimaltestdata/rounding.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- These tests require that implementations take account of residues in -- order to get correct results for some rounding modes. Rather than diff --git a/Lib/test/decimaltestdata/samequantum.decTest b/Lib/test/decimaltestdata/samequantum.decTest index 0b1efff24c7..3fa6cff2037 100644 --- a/Lib/test/decimaltestdata/samequantum.decTest +++ b/Lib/test/decimaltestdata/samequantum.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/scaleb.decTest b/Lib/test/decimaltestdata/scaleb.decTest index 0761deaacc9..e77d938d9f8 100644 --- a/Lib/test/decimaltestdata/scaleb.decTest +++ b/Lib/test/decimaltestdata/scaleb.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/shift.decTest b/Lib/test/decimaltestdata/shift.decTest index c2a40cc9306..397024ef551 100644 --- a/Lib/test/decimaltestdata/shift.decTest +++ b/Lib/test/decimaltestdata/shift.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/squareroot.decTest b/Lib/test/decimaltestdata/squareroot.decTest index 2ccff5adf5a..8d7b26e0812 100644 --- a/Lib/test/decimaltestdata/squareroot.decTest +++ b/Lib/test/decimaltestdata/squareroot.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/subtract.decTest b/Lib/test/decimaltestdata/subtract.decTest index 338a09c0e38..a1eca3107e1 100644 --- a/Lib/test/decimaltestdata/subtract.decTest +++ b/Lib/test/decimaltestdata/subtract.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9 diff --git a/Lib/test/decimaltestdata/testall.decTest b/Lib/test/decimaltestdata/testall.decTest index 1cbc20e44f1..673aaa485fa 100644 --- a/Lib/test/decimaltestdata/testall.decTest +++ b/Lib/test/decimaltestdata/testall.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- core tests (using Extended: 1) -------------------------------------- dectest: base diff --git a/Lib/test/decimaltestdata/tointegral.decTest b/Lib/test/decimaltestdata/tointegral.decTest index ad25e6be038..340515cb174 100644 --- a/Lib/test/decimaltestdata/tointegral.decTest +++ b/Lib/test/decimaltestdata/tointegral.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This set of tests tests the extended specification 'round-to-integral -- value' operation (from IEEE 854, later modified in 754r). diff --git a/Lib/test/decimaltestdata/tointegralx.decTest b/Lib/test/decimaltestdata/tointegralx.decTest index d9bc9f36d08..381216dea6a 100644 --- a/Lib/test/decimaltestdata/tointegralx.decTest +++ b/Lib/test/decimaltestdata/tointegralx.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 -- This set of tests tests the extended specification 'round-to-integral -- value' operation (from IEEE 854, later modified in 754r). diff --git a/Lib/test/decimaltestdata/xor.decTest b/Lib/test/decimaltestdata/xor.decTest index 2ac1b371fef..1f3b03b4cb6 100644 --- a/Lib/test/decimaltestdata/xor.decTest +++ b/Lib/test/decimaltestdata/xor.decTest @@ -17,7 +17,7 @@ -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK -- -- mfc@uk.ibm.com -- ------------------------------------------------------------------------ -version: 2.56 +version: 2.57 extended: 1 precision: 9