• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1------------------------------------------------------------------------
2-- dqFMA.decTest -- decQuad Fused Multiply Add                        --
3-- Copyright (c) IBM Corporation, 1981, 2008.  All rights reserved.   --
4------------------------------------------------------------------------
5-- Please see the document "General Decimal Arithmetic Testcases"     --
6-- at http://www2.hursley.ibm.com/decimal for the description of      --
7-- these testcases.                                                   --
8--                                                                    --
9-- These testcases are experimental ('beta' versions), and they       --
10-- may contain errors.  They are offered on an as-is basis.  In       --
11-- particular, achieving the same results as the tests here is not    --
12-- a guarantee that an implementation complies with any Standard      --
13-- or specification.  The tests are not exhaustive.                   --
14--                                                                    --
15-- Please send comments, suggestions, and corrections to the author:  --
16--   Mike Cowlishaw, IBM Fellow                                       --
17--   IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK         --
18--   mfc@uk.ibm.com                                                   --
19------------------------------------------------------------------------
20version: 2.59
21
22extended:    1
23clamp:       1
24precision:   34
25maxExponent: 6144
26minExponent: -6143
27rounding:    half_even
28
29-- These tests comprise three parts:
30--   1. Sanity checks and other three-operand tests (especially those
31--      where the fused operation makes a difference)
32--   2. Multiply tests (third operand is neutral zero [0E+emax])
33--   3. Addition tests (first operand is 1)
34-- The multiply and addition tests are extensive because FMA may have
35-- its own dedicated multiplication or addition routine(s), and they
36-- also inherently check the left-to-right properties.
37
38-- Sanity checks
39dqfma0001 fma  1   1   1 ->   2
40dqfma0002 fma  1   1   2 ->   3
41dqfma0003 fma  2   2   3 ->   7
42dqfma0004 fma  9   9   9 ->  90
43dqfma0005 fma -1   1   1 ->   0
44dqfma0006 fma -1   1   2 ->   1
45dqfma0007 fma -2   2   3 ->  -1
46dqfma0008 fma -9   9   9 -> -72
47dqfma0011 fma  1  -1   1 ->   0
48dqfma0012 fma  1  -1   2 ->   1
49dqfma0013 fma  2  -2   3 ->  -1
50dqfma0014 fma  9  -9   9 -> -72
51dqfma0015 fma  1   1  -1 ->   0
52dqfma0016 fma  1   1  -2 ->  -1
53dqfma0017 fma  2   2  -3 ->   1
54dqfma0018 fma  9   9  -9 ->  72
55
56-- non-integer exacts
57dqfma0100  fma    25.2   63.6   -438  ->  1164.72
58dqfma0101  fma   0.301  0.380    334  ->  334.114380
59dqfma0102  fma    49.2   -4.8   23.3  ->  -212.86
60dqfma0103  fma    4.22  0.079  -94.6  ->  -94.26662
61dqfma0104  fma     903  0.797  0.887  ->  720.578
62dqfma0105  fma    6.13   -161   65.9  ->  -921.03
63dqfma0106  fma    28.2    727   5.45  ->  20506.85
64dqfma0107  fma       4    605    688  ->  3108
65dqfma0108  fma    93.3   0.19  0.226  ->  17.953
66dqfma0109  fma   0.169   -341   5.61  ->  -52.019
67dqfma0110  fma   -72.2     30  -51.2  ->  -2217.2
68dqfma0111  fma  -0.409     13   20.4  ->  15.083
69dqfma0112  fma     317   77.0   19.0  ->  24428.0
70dqfma0113  fma      47   6.58   1.62  ->  310.88
71dqfma0114  fma    1.36  0.984  0.493  ->  1.83124
72dqfma0115  fma    72.7    274   1.56  ->  19921.36
73dqfma0116  fma     335    847     83  ->  283828
74dqfma0117  fma     666  0.247   25.4  ->  189.902
75dqfma0118  fma   -3.87   3.06   78.0  ->  66.1578
76dqfma0119  fma   0.742    192   35.6  ->  178.064
77dqfma0120  fma   -91.6   5.29  0.153  ->  -484.411
78
79-- cases where result is different from separate multiply + add; each
80-- is preceded by the result of unfused multiply and add
81-- [this is about 20% of all similar  cases in general]
82--                                                                                                            ->  4.500119002100000209469729375698778E+38
83dqfma0202  fma       68537985861355864457.5694      6565875762972086605.85969       35892634447236753.172812  ->  4.500119002100000209469729375698779E+38 Inexact Rounded
84--                                                                                                            ->  5.996248469584594346858881620185514E+41
85dqfma0208  fma          89261822344727628571.9      6717595845654131383336.89      5061036497288796076266.11  ->  5.996248469584594346858881620185513E+41 Inexact Rounded
86--                                                                                                            ->  1.899242968678256924021594770874070E+34
87dqfma0210  fma       320506237232448685.495971       59257597764017967.984448      3205615239077711589912.85  ->  1.899242968678256924021594770874071E+34 Inexact Rounded
88--                                                                                                            ->  7.078596978842809537929699954860309E+37
89dqfma0215  fma        220247843259112263.17995       321392340287987979002.80        47533279819997167655440  ->  7.078596978842809537929699954860308E+37 Inexact Rounded
90--                                                                                                            ->  1.224955667581427559754106862350743E+37
91dqfma0226  fma       23880729790368880412.1449       512947333827064719.55407      217117438419590824502.963  ->  1.224955667581427559754106862350744E+37 Inexact Rounded
92--                                                                                                            ->  -2.530094043253148806272276368579144E+42
93dqfma0229  fma        2539892357016099706.4126      -996142232667504817717435       53682082598315949425.937  ->  -2.530094043253148806272276368579143E+42 Inexact Rounded
94--                                                                                                            ->  1.713387085759711954319391412788454E+37
95dqfma0233  fma        4546339491341624464.0804            3768717864169205581       83578980278690395184.620  ->  1.713387085759711954319391412788453E+37 Inexact Rounded
96--                                                                                                            ->  4.062275663405823716411579117771547E+35
97dqfma0235  fma        409242119433816131.42253      992633815166741501.477249        70179636544416756129546  ->  4.062275663405823716411579117771548E+35 Inexact Rounded
98--                                                                                                            ->  6.002604327732568490562249875306823E+47
99dqfma0258  fma        817941336593541742159684       733867339769310729266598      78563844650942419311830.8  ->  6.002604327732568490562249875306822E+47 Inexact Rounded
100--                                                                                                            ->  -2.027022514381452197510103395283874E+39
101dqfma0264  fma       387617310169161270.737532     -5229442703414956061216.62      57665666816652967150473.5  ->  -2.027022514381452197510103395283873E+39 Inexact Rounded
102--                                                                                                            ->  -7.856525039803554001144089842730361E+37
103dqfma0267  fma      -847655845720565274701.210        92685316564117739.83984      22780950041376424429.5686  ->  -7.856525039803554001144089842730360E+37 Inexact Rounded
104--                                                                                                            ->  1.695515562011520746125607502237559E+38
105dqfma0268  fma          21590290365127685.3675       7853139227576541379426.8       -3275859437236180.761544  ->  1.695515562011520746125607502237558E+38 Inexact Rounded
106--                                                                                                            ->  -8.448422935783289219748115038014710E+38
107dqfma0269  fma      -974320636272862697.971586      867109103641860247440.756        -9775170775902454762.98  ->  -8.448422935783289219748115038014709E+38 Inexact Rounded
108
109-- Cases where multiply would overflow or underflow if separate
110dqfma0300  fma   9e+6144    10   0         -> Infinity  Overflow Inexact Rounded
111dqfma0301  fma   1e+6144    10   0         -> Infinity  Overflow Inexact Rounded
112dqfma0302  fma   1e+6144    10   -1e+6144  -> 9.000000000000000000000000000000000E+6144 Clamped
113dqfma0303  fma   1e+6144    10   -9e+6144  -> 1.000000000000000000000000000000000E+6144 Clamped
114-- subnormal etc.
115dqfma0305  fma   1e-6176    0.1  0         -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped
116dqfma0306  fma   1e-6176    0.1  1         -> 1.000000000000000000000000000000000 Inexact Rounded
117dqfma0307  fma   1e-6176    0.1  1e-6176   -> 1E-6176 Underflow Subnormal Inexact Rounded
118
119-- Infinite combinations
120dqfma0800 fma  Inf   Inf   Inf    ->  Infinity
121dqfma0801 fma  Inf   Inf  -Inf    ->  NaN Invalid_operation
122dqfma0802 fma  Inf  -Inf   Inf    ->  NaN Invalid_operation
123dqfma0803 fma  Inf  -Inf  -Inf    -> -Infinity
124dqfma0804 fma -Inf   Inf   Inf    ->  NaN Invalid_operation
125dqfma0805 fma -Inf   Inf  -Inf    -> -Infinity
126dqfma0806 fma -Inf  -Inf   Inf    ->  Infinity
127dqfma0807 fma -Inf  -Inf  -Inf    ->  NaN Invalid_operation
128
129-- Triple NaN propagation
130dqfma0900 fma  NaN2  NaN3  NaN5   ->  NaN2
131dqfma0901 fma  0     NaN3  NaN5   ->  NaN3
132dqfma0902 fma  0     0     NaN5   ->  NaN5
133-- first sNaN wins (consider qNaN from earlier sNaN being
134-- overridden by an sNaN in third operand)
135dqfma0903 fma  sNaN1 sNaN2 sNaN3  ->  NaN1 Invalid_operation
136dqfma0904 fma  0     sNaN2 sNaN3  ->  NaN2 Invalid_operation
137dqfma0905 fma  0     0     sNaN3  ->  NaN3 Invalid_operation
138dqfma0906 fma  sNaN1 sNaN2 sNaN3  ->  NaN1 Invalid_operation
139dqfma0907 fma  NaN7  sNaN2 sNaN3  ->  NaN2 Invalid_operation
140dqfma0908 fma  NaN7  NaN5  sNaN3  ->  NaN3 Invalid_operation
141
142-- MULTIPLICATION TESTS ------------------------------------------------
143rounding:    half_even
144
145-- sanity checks
146dqfma2000 fma  2      2   0e+6144  -> 4
147dqfma2001 fma  2      3   0e+6144  -> 6
148dqfma2002 fma  5      1   0e+6144  -> 5
149dqfma2003 fma  5      2   0e+6144  -> 10
150dqfma2004 fma  1.20   2   0e+6144  -> 2.40
151dqfma2005 fma  1.20   0   0e+6144  -> 0.00
152dqfma2006 fma  1.20  -2   0e+6144  -> -2.40
153dqfma2007 fma  -1.20  2   0e+6144  -> -2.40
154dqfma2008 fma  -1.20  0   0e+6144  -> 0.00
155dqfma2009 fma  -1.20 -2   0e+6144  -> 2.40
156dqfma2010 fma  5.09 7.1   0e+6144  -> 36.139
157dqfma2011 fma  2.5    4   0e+6144  -> 10.0
158dqfma2012 fma  2.50   4   0e+6144  -> 10.00
159dqfma2013 fma  1.23456789 1.0000000000000000000000000000   0e+6144  -> 1.234567890000000000000000000000000 Rounded
160dqfma2015 fma  2.50   4   0e+6144  -> 10.00
161dqfma2016 fma   9.99999999999999999  9.99999999999999999   0e+6144  ->  99.99999999999999980000000000000000 Inexact Rounded
162dqfma2017 fma   9.99999999999999999 -9.99999999999999999   0e+6144  -> -99.99999999999999980000000000000000 Inexact Rounded
163dqfma2018 fma  -9.99999999999999999  9.99999999999999999   0e+6144  -> -99.99999999999999980000000000000000 Inexact Rounded
164dqfma2019 fma  -9.99999999999999999 -9.99999999999999999   0e+6144  ->  99.99999999999999980000000000000000 Inexact Rounded
165
166-- zeros, etc.
167dqfma2021 fma   0      0       0e+6144  ->  0
168dqfma2022 fma   0     -0       0e+6144  ->  0
169dqfma2023 fma  -0      0       0e+6144  ->  0
170dqfma2024 fma  -0     -0       0e+6144  ->  0
171dqfma2025 fma  -0.0   -0.0     0e+6144  ->  0.00
172dqfma2026 fma  -0.0   -0.0     0e+6144  ->  0.00
173dqfma2027 fma  -0.0   -0.0     0e+6144  ->  0.00
174dqfma2028 fma  -0.0   -0.0     0e+6144  ->  0.00
175dqfma2030 fma   5.00   1E-3    0e+6144  ->  0.00500
176dqfma2031 fma   00.00  0.000   0e+6144  ->  0.00000
177dqfma2032 fma   00.00  0E-3    0e+6144  ->  0.00000     -- rhs is 0
178dqfma2033 fma   0E-3   00.00   0e+6144  ->  0.00000     -- lhs is 0
179dqfma2034 fma  -5.00   1E-3    0e+6144  -> -0.00500
180dqfma2035 fma  -00.00  0.000   0e+6144  ->  0.00000
181dqfma2036 fma  -00.00  0E-3    0e+6144  ->  0.00000     -- rhs is 0
182dqfma2037 fma  -0E-3   00.00   0e+6144  ->  0.00000     -- lhs is 0
183dqfma2038 fma   5.00  -1E-3    0e+6144  -> -0.00500
184dqfma2039 fma   00.00 -0.000   0e+6144  ->  0.00000
185dqfma2040 fma   00.00 -0E-3    0e+6144  ->  0.00000     -- rhs is 0
186dqfma2041 fma   0E-3  -00.00   0e+6144  ->  0.00000     -- lhs is 0
187dqfma2042 fma  -5.00  -1E-3    0e+6144  ->  0.00500
188dqfma2043 fma  -00.00 -0.000   0e+6144  ->  0.00000
189dqfma2044 fma  -00.00 -0E-3    0e+6144  ->  0.00000     -- rhs is 0
190dqfma2045 fma  -0E-3  -00.00   0e+6144  ->  0.00000     -- lhs is 0
191
192-- examples from decarith
193dqfma2050 fma  1.20 3          0e+6144  -> 3.60
194dqfma2051 fma  7    3          0e+6144  -> 21
195dqfma2052 fma  0.9  0.8        0e+6144  -> 0.72
196dqfma2053 fma  0.9  -0         0e+6144  -> 0.0
197dqfma2054 fma  654321 654321   0e+6144  -> 428135971041
198
199dqfma2060 fma  123.45 1e7    0e+6144  ->  1.2345E+9
200dqfma2061 fma  123.45 1e8    0e+6144  ->  1.2345E+10
201dqfma2062 fma  123.45 1e+9   0e+6144  ->  1.2345E+11
202dqfma2063 fma  123.45 1e10   0e+6144  ->  1.2345E+12
203dqfma2064 fma  123.45 1e11   0e+6144  ->  1.2345E+13
204dqfma2065 fma  123.45 1e12   0e+6144  ->  1.2345E+14
205dqfma2066 fma  123.45 1e13   0e+6144  ->  1.2345E+15
206
207
208-- test some intermediate lengths
209--                    1234567890123456
210dqfma2080 fma  0.1 1230123456456789       0e+6144  -> 123012345645678.9
211dqfma2084 fma  0.1 1230123456456789       0e+6144  -> 123012345645678.9
212dqfma2090 fma  1230123456456789     0.1   0e+6144  -> 123012345645678.9
213dqfma2094 fma  1230123456456789     0.1   0e+6144  -> 123012345645678.9
214
215-- test some more edge cases and carries
216dqfma2101 fma  9 9     0e+6144  -> 81
217dqfma2102 fma  9 90     0e+6144  -> 810
218dqfma2103 fma  9 900     0e+6144  -> 8100
219dqfma2104 fma  9 9000     0e+6144  -> 81000
220dqfma2105 fma  9 90000     0e+6144  -> 810000
221dqfma2106 fma  9 900000     0e+6144  -> 8100000
222dqfma2107 fma  9 9000000     0e+6144  -> 81000000
223dqfma2108 fma  9 90000000     0e+6144  -> 810000000
224dqfma2109 fma  9 900000000     0e+6144  -> 8100000000
225dqfma2110 fma  9 9000000000     0e+6144  -> 81000000000
226dqfma2111 fma  9 90000000000     0e+6144  -> 810000000000
227dqfma2112 fma  9 900000000000     0e+6144  -> 8100000000000
228dqfma2113 fma  9 9000000000000     0e+6144  -> 81000000000000
229dqfma2114 fma  9 90000000000000     0e+6144  -> 810000000000000
230dqfma2115 fma  9 900000000000000     0e+6144  -> 8100000000000000
231--dqfma2116 fma  9 9000000000000000     0e+6144  -> 81000000000000000
232--dqfma2117 fma  9 90000000000000000     0e+6144  -> 810000000000000000
233--dqfma2118 fma  9 900000000000000000     0e+6144  -> 8100000000000000000
234--dqfma2119 fma  9 9000000000000000000     0e+6144  -> 81000000000000000000
235--dqfma2120 fma  9 90000000000000000000     0e+6144  -> 810000000000000000000
236--dqfma2121 fma  9 900000000000000000000     0e+6144  -> 8100000000000000000000
237--dqfma2122 fma  9 9000000000000000000000     0e+6144  -> 81000000000000000000000
238--dqfma2123 fma  9 90000000000000000000000     0e+6144  -> 810000000000000000000000
239-- test some more edge cases without carries
240dqfma2131 fma  3 3     0e+6144  -> 9
241dqfma2132 fma  3 30     0e+6144  -> 90
242dqfma2133 fma  3 300     0e+6144  -> 900
243dqfma2134 fma  3 3000     0e+6144  -> 9000
244dqfma2135 fma  3 30000     0e+6144  -> 90000
245dqfma2136 fma  3 300000     0e+6144  -> 900000
246dqfma2137 fma  3 3000000     0e+6144  -> 9000000
247dqfma2138 fma  3 30000000     0e+6144  -> 90000000
248dqfma2139 fma  3 300000000     0e+6144  -> 900000000
249dqfma2140 fma  3 3000000000     0e+6144  -> 9000000000
250dqfma2141 fma  3 30000000000     0e+6144  -> 90000000000
251dqfma2142 fma  3 300000000000     0e+6144  -> 900000000000
252dqfma2143 fma  3 3000000000000     0e+6144  -> 9000000000000
253dqfma2144 fma  3 30000000000000     0e+6144  -> 90000000000000
254dqfma2145 fma  3 300000000000000     0e+6144  -> 900000000000000
255dqfma2146 fma  3 3000000000000000     0e+6144  -> 9000000000000000
256dqfma2147 fma  3 30000000000000000     0e+6144  -> 90000000000000000
257dqfma2148 fma  3 300000000000000000     0e+6144  -> 900000000000000000
258dqfma2149 fma  3 3000000000000000000     0e+6144  -> 9000000000000000000
259dqfma2150 fma  3 30000000000000000000     0e+6144  -> 90000000000000000000
260dqfma2151 fma  3 300000000000000000000     0e+6144  -> 900000000000000000000
261dqfma2152 fma  3 3000000000000000000000     0e+6144  -> 9000000000000000000000
262dqfma2153 fma  3 30000000000000000000000     0e+6144  -> 90000000000000000000000
263
264dqfma2263 fma  30269.587755640502150977251770554 4.8046009735990873395936309640543   0e+6144  -> 145433.2908011933696719165119928296 Inexact Rounded
265
266-- test some edge cases with exact rounding
267dqfma2301 fma  900000000000000000 9     0e+6144  -> 8100000000000000000
268dqfma2302 fma  900000000000000000 90     0e+6144  -> 81000000000000000000
269dqfma2303 fma  900000000000000000 900     0e+6144  -> 810000000000000000000
270dqfma2304 fma  900000000000000000 9000     0e+6144  -> 8100000000000000000000
271dqfma2305 fma  900000000000000000 90000     0e+6144  -> 81000000000000000000000
272dqfma2306 fma  900000000000000000 900000     0e+6144  -> 810000000000000000000000
273dqfma2307 fma  900000000000000000 9000000     0e+6144  -> 8100000000000000000000000
274dqfma2308 fma  900000000000000000 90000000     0e+6144  -> 81000000000000000000000000
275dqfma2309 fma  900000000000000000 900000000     0e+6144  -> 810000000000000000000000000
276dqfma2310 fma  900000000000000000 9000000000     0e+6144  -> 8100000000000000000000000000
277dqfma2311 fma  900000000000000000 90000000000     0e+6144  -> 81000000000000000000000000000
278dqfma2312 fma  900000000000000000 900000000000     0e+6144  -> 810000000000000000000000000000
279dqfma2313 fma  900000000000000000 9000000000000     0e+6144  -> 8100000000000000000000000000000
280dqfma2314 fma  900000000000000000 90000000000000     0e+6144  -> 81000000000000000000000000000000
281dqfma2315 fma  900000000000000000 900000000000000     0e+6144  -> 810000000000000000000000000000000
282dqfma2316 fma  900000000000000000 9000000000000000     0e+6144  -> 8100000000000000000000000000000000
283dqfma2317 fma  9000000000000000000 9000000000000000     0e+6144  -> 8.100000000000000000000000000000000E+34  Rounded
284dqfma2318 fma  90000000000000000000 9000000000000000     0e+6144  -> 8.100000000000000000000000000000000E+35  Rounded
285dqfma2319 fma  900000000000000000000 9000000000000000     0e+6144  -> 8.100000000000000000000000000000000E+36  Rounded
286dqfma2320 fma  9000000000000000000000 9000000000000000     0e+6144  -> 8.100000000000000000000000000000000E+37  Rounded
287dqfma2321 fma  90000000000000000000000 9000000000000000     0e+6144  -> 8.100000000000000000000000000000000E+38  Rounded
288dqfma2322 fma  900000000000000000000000 9000000000000000     0e+6144  -> 8.100000000000000000000000000000000E+39  Rounded
289dqfma2323 fma  9000000000000000000000000 9000000000000000     0e+6144  -> 8.100000000000000000000000000000000E+40  Rounded
290
291-- tryzeros cases
292dqfma2504  fma   0E-4260 1000E-4260    0e+6144  -> 0E-6176 Clamped
293dqfma2505  fma   100E+4260 0E+4260     0e+6144  -> 0E+6111 Clamped
294
295-- mixed with zeros
296dqfma2541 fma   0    -1       0e+6144  ->  0
297dqfma2542 fma  -0    -1       0e+6144  ->  0
298dqfma2543 fma   0     1       0e+6144  ->  0
299dqfma2544 fma  -0     1       0e+6144  ->  0
300dqfma2545 fma  -1     0       0e+6144  ->  0
301dqfma2546 fma  -1    -0       0e+6144  ->  0
302dqfma2547 fma   1     0       0e+6144  ->  0
303dqfma2548 fma   1    -0       0e+6144  ->  0
304
305dqfma2551 fma   0.0  -1       0e+6144  ->  0.0
306dqfma2552 fma  -0.0  -1       0e+6144  ->  0.0
307dqfma2553 fma   0.0   1       0e+6144  ->  0.0
308dqfma2554 fma  -0.0   1       0e+6144  ->  0.0
309dqfma2555 fma  -1.0   0       0e+6144  ->  0.0
310dqfma2556 fma  -1.0  -0       0e+6144  ->  0.0
311dqfma2557 fma   1.0   0       0e+6144  ->  0.0
312dqfma2558 fma   1.0  -0       0e+6144  ->  0.0
313
314dqfma2561 fma   0    -1.0     0e+6144  ->  0.0
315dqfma2562 fma  -0    -1.0     0e+6144  ->  0.0
316dqfma2563 fma   0     1.0     0e+6144  ->  0.0
317dqfma2564 fma  -0     1.0     0e+6144  ->  0.0
318dqfma2565 fma  -1     0.0     0e+6144  ->  0.0
319dqfma2566 fma  -1    -0.0     0e+6144  ->  0.0
320dqfma2567 fma   1     0.0     0e+6144  ->  0.0
321dqfma2568 fma   1    -0.0     0e+6144  ->  0.0
322
323dqfma2571 fma   0.0  -1.0     0e+6144  ->  0.00
324dqfma2572 fma  -0.0  -1.0     0e+6144  ->  0.00
325dqfma2573 fma   0.0   1.0     0e+6144  ->  0.00
326dqfma2574 fma  -0.0   1.0     0e+6144  ->  0.00
327dqfma2575 fma  -1.0   0.0     0e+6144  ->  0.00
328dqfma2576 fma  -1.0  -0.0     0e+6144  ->  0.00
329dqfma2577 fma   1.0   0.0     0e+6144  ->  0.00
330dqfma2578 fma   1.0  -0.0     0e+6144  ->  0.00
331dqfma2579 fma   1.0   0.0     0e+6144  ->  0.00
332dqfma2530 fma  -1.0  -0.0     0e+6144  ->  0.00
333dqfma2531 fma  -1.0   0.0     0e+6144  ->  0.00
334dqfma2532 fma   1.0  -0.0    -0e+6144  -> -0.00
335dqfma2533 fma   1.0   0.0    -0e+6144  ->  0.00
336dqfma2534 fma  -1.0  -0.0    -0e+6144  ->  0.00
337dqfma2535 fma  -1.0   0.0    -0e+6144  -> -0.00
338
339
340-- Specials
341dqfma2580 fma   Inf  -Inf     0e+6144  -> -Infinity
342dqfma2581 fma   Inf  -1000    0e+6144  -> -Infinity
343dqfma2582 fma   Inf  -1       0e+6144  -> -Infinity
344dqfma2583 fma   Inf  -0       0e+6144  ->  NaN  Invalid_operation
345dqfma2584 fma   Inf   0       0e+6144  ->  NaN  Invalid_operation
346dqfma2585 fma   Inf   1       0e+6144  ->  Infinity
347dqfma2586 fma   Inf   1000    0e+6144  ->  Infinity
348dqfma2587 fma   Inf   Inf     0e+6144  ->  Infinity
349dqfma2588 fma  -1000  Inf     0e+6144  -> -Infinity
350dqfma2589 fma  -Inf   Inf     0e+6144  -> -Infinity
351dqfma2590 fma  -1     Inf     0e+6144  -> -Infinity
352dqfma2591 fma  -0     Inf     0e+6144  ->  NaN  Invalid_operation
353dqfma2592 fma   0     Inf     0e+6144  ->  NaN  Invalid_operation
354dqfma2593 fma   1     Inf     0e+6144  ->  Infinity
355dqfma2594 fma   1000  Inf     0e+6144  ->  Infinity
356dqfma2595 fma   Inf   Inf     0e+6144  ->  Infinity
357
358dqfma2600 fma  -Inf  -Inf     0e+6144  ->  Infinity
359dqfma2601 fma  -Inf  -1000    0e+6144  ->  Infinity
360dqfma2602 fma  -Inf  -1       0e+6144  ->  Infinity
361dqfma2603 fma  -Inf  -0       0e+6144  ->  NaN  Invalid_operation
362dqfma2604 fma  -Inf   0       0e+6144  ->  NaN  Invalid_operation
363dqfma2605 fma  -Inf   1       0e+6144  -> -Infinity
364dqfma2606 fma  -Inf   1000    0e+6144  -> -Infinity
365dqfma2607 fma  -Inf   Inf     0e+6144  -> -Infinity
366dqfma2608 fma  -1000  Inf     0e+6144  -> -Infinity
367dqfma2609 fma  -Inf  -Inf     0e+6144  ->  Infinity
368dqfma2610 fma  -1    -Inf     0e+6144  ->  Infinity
369dqfma2611 fma  -0    -Inf     0e+6144  ->  NaN  Invalid_operation
370dqfma2612 fma   0    -Inf     0e+6144  ->  NaN  Invalid_operation
371dqfma2613 fma   1    -Inf     0e+6144  -> -Infinity
372dqfma2614 fma   1000 -Inf     0e+6144  -> -Infinity
373dqfma2615 fma   Inf  -Inf     0e+6144  -> -Infinity
374
375dqfma2621 fma   NaN -Inf      0e+6144  ->  NaN
376dqfma2622 fma   NaN -1000     0e+6144  ->  NaN
377dqfma2623 fma   NaN -1        0e+6144  ->  NaN
378dqfma2624 fma   NaN -0        0e+6144  ->  NaN
379dqfma2625 fma   NaN  0        0e+6144  ->  NaN
380dqfma2626 fma   NaN  1        0e+6144  ->  NaN
381dqfma2627 fma   NaN  1000     0e+6144  ->  NaN
382dqfma2628 fma   NaN  Inf      0e+6144  ->  NaN
383dqfma2629 fma   NaN  NaN      0e+6144  ->  NaN
384dqfma2630 fma  -Inf  NaN      0e+6144  ->  NaN
385dqfma2631 fma  -1000 NaN      0e+6144  ->  NaN
386dqfma2632 fma  -1    NaN      0e+6144  ->  NaN
387dqfma2633 fma  -0    NaN      0e+6144  ->  NaN
388dqfma2634 fma   0    NaN      0e+6144  ->  NaN
389dqfma2635 fma   1    NaN      0e+6144  ->  NaN
390dqfma2636 fma   1000 NaN      0e+6144  ->  NaN
391dqfma2637 fma   Inf  NaN      0e+6144  ->  NaN
392
393dqfma2641 fma   sNaN -Inf     0e+6144  ->  NaN  Invalid_operation
394dqfma2642 fma   sNaN -1000    0e+6144  ->  NaN  Invalid_operation
395dqfma2643 fma   sNaN -1       0e+6144  ->  NaN  Invalid_operation
396dqfma2644 fma   sNaN -0       0e+6144  ->  NaN  Invalid_operation
397dqfma2645 fma   sNaN  0       0e+6144  ->  NaN  Invalid_operation
398dqfma2646 fma   sNaN  1       0e+6144  ->  NaN  Invalid_operation
399dqfma2647 fma   sNaN  1000    0e+6144  ->  NaN  Invalid_operation
400dqfma2648 fma   sNaN  NaN     0e+6144  ->  NaN  Invalid_operation
401dqfma2649 fma   sNaN sNaN     0e+6144  ->  NaN  Invalid_operation
402dqfma2650 fma   NaN  sNaN     0e+6144  ->  NaN  Invalid_operation
403dqfma2651 fma  -Inf  sNaN     0e+6144  ->  NaN  Invalid_operation
404dqfma2652 fma  -1000 sNaN     0e+6144  ->  NaN  Invalid_operation
405dqfma2653 fma  -1    sNaN     0e+6144  ->  NaN  Invalid_operation
406dqfma2654 fma  -0    sNaN     0e+6144  ->  NaN  Invalid_operation
407dqfma2655 fma   0    sNaN     0e+6144  ->  NaN  Invalid_operation
408dqfma2656 fma   1    sNaN     0e+6144  ->  NaN  Invalid_operation
409dqfma2657 fma   1000 sNaN     0e+6144  ->  NaN  Invalid_operation
410dqfma2658 fma   Inf  sNaN     0e+6144  ->  NaN  Invalid_operation
411dqfma2659 fma   NaN  sNaN     0e+6144  ->  NaN  Invalid_operation
412
413-- propagating NaNs
414dqfma2661 fma   NaN9 -Inf     0e+6144  ->  NaN9
415dqfma2662 fma   NaN8  999     0e+6144  ->  NaN8
416dqfma2663 fma   NaN71 Inf     0e+6144  ->  NaN71
417dqfma2664 fma   NaN6  NaN5    0e+6144  ->  NaN6
418dqfma2665 fma  -Inf   NaN4    0e+6144  ->  NaN4
419dqfma2666 fma  -999   NaN33   0e+6144  ->  NaN33
420dqfma2667 fma   Inf   NaN2    0e+6144  ->  NaN2
421
422dqfma2671 fma   sNaN99 -Inf      0e+6144  ->  NaN99 Invalid_operation
423dqfma2672 fma   sNaN98 -11       0e+6144  ->  NaN98 Invalid_operation
424dqfma2673 fma   sNaN97  NaN      0e+6144  ->  NaN97 Invalid_operation
425dqfma2674 fma   sNaN16 sNaN94    0e+6144  ->  NaN16 Invalid_operation
426dqfma2675 fma   NaN95  sNaN93    0e+6144  ->  NaN93 Invalid_operation
427dqfma2676 fma  -Inf    sNaN92    0e+6144  ->  NaN92 Invalid_operation
428dqfma2677 fma   088    sNaN91    0e+6144  ->  NaN91 Invalid_operation
429dqfma2678 fma   Inf    sNaN90    0e+6144  ->  NaN90 Invalid_operation
430dqfma2679 fma   NaN    sNaN89    0e+6144  ->  NaN89 Invalid_operation
431
432dqfma2681 fma  -NaN9 -Inf     0e+6144  -> -NaN9
433dqfma2682 fma  -NaN8  999     0e+6144  -> -NaN8
434dqfma2683 fma  -NaN71 Inf     0e+6144  -> -NaN71
435dqfma2684 fma  -NaN6 -NaN5    0e+6144  -> -NaN6
436dqfma2685 fma  -Inf  -NaN4    0e+6144  -> -NaN4
437dqfma2686 fma  -999  -NaN33   0e+6144  -> -NaN33
438dqfma2687 fma   Inf  -NaN2    0e+6144  -> -NaN2
439
440dqfma2691 fma  -sNaN99 -Inf      0e+6144  -> -NaN99 Invalid_operation
441dqfma2692 fma  -sNaN98 -11       0e+6144  -> -NaN98 Invalid_operation
442dqfma2693 fma  -sNaN97  NaN      0e+6144  -> -NaN97 Invalid_operation
443dqfma2694 fma  -sNaN16 -sNaN94   0e+6144  -> -NaN16 Invalid_operation
444dqfma2695 fma  -NaN95  -sNaN93   0e+6144  -> -NaN93 Invalid_operation
445dqfma2696 fma  -Inf    -sNaN92   0e+6144  -> -NaN92 Invalid_operation
446dqfma2697 fma   088    -sNaN91   0e+6144  -> -NaN91 Invalid_operation
447dqfma2698 fma   Inf    -sNaN90   0e+6144  -> -NaN90 Invalid_operation
448dqfma2699 fma  -NaN    -sNaN89   0e+6144  -> -NaN89 Invalid_operation
449
450dqfma2701 fma  -NaN  -Inf     0e+6144  -> -NaN
451dqfma2702 fma  -NaN   999     0e+6144  -> -NaN
452dqfma2703 fma  -NaN   Inf     0e+6144  -> -NaN
453dqfma2704 fma  -NaN  -NaN     0e+6144  -> -NaN
454dqfma2705 fma  -Inf  -NaN0    0e+6144  -> -NaN
455dqfma2706 fma  -999  -NaN     0e+6144  -> -NaN
456dqfma2707 fma   Inf  -NaN     0e+6144  -> -NaN
457
458dqfma2711 fma  -sNaN   -Inf      0e+6144  -> -NaN Invalid_operation
459dqfma2712 fma  -sNaN   -11       0e+6144  -> -NaN Invalid_operation
460dqfma2713 fma  -sNaN00  NaN      0e+6144  -> -NaN Invalid_operation
461dqfma2714 fma  -sNaN   -sNaN     0e+6144  -> -NaN Invalid_operation
462dqfma2715 fma  -NaN    -sNaN     0e+6144  -> -NaN Invalid_operation
463dqfma2716 fma  -Inf    -sNaN     0e+6144  -> -NaN Invalid_operation
464dqfma2717 fma   088    -sNaN     0e+6144  -> -NaN Invalid_operation
465dqfma2718 fma   Inf    -sNaN     0e+6144  -> -NaN Invalid_operation
466dqfma2719 fma  -NaN    -sNaN     0e+6144  -> -NaN Invalid_operation
467
468-- overflow and underflow tests .. note subnormal results
469-- signs
470dqfma2751 fma   1e+4277  1e+3311   0e+6144  ->  Infinity Overflow Inexact Rounded
471dqfma2752 fma   1e+4277 -1e+3311   0e+6144  -> -Infinity Overflow Inexact Rounded
472dqfma2753 fma  -1e+4277  1e+3311   0e+6144  -> -Infinity Overflow Inexact Rounded
473dqfma2754 fma  -1e+4277 -1e+3311   0e+6144  ->  Infinity Overflow Inexact Rounded
474dqfma2755 fma   1e-4277  1e-3311   0e+6144  ->  0E-6176 Underflow Subnormal Inexact Rounded Clamped
475dqfma2756 fma   1e-4277 -1e-3311   0e+6144  -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped
476dqfma2757 fma  -1e-4277  1e-3311   0e+6144  -> -0E-6176 Underflow Subnormal Inexact Rounded Clamped
477dqfma2758 fma  -1e-4277 -1e-3311   0e+6144  ->  0E-6176 Underflow Subnormal Inexact Rounded Clamped
478
479-- 'subnormal' boundary (all hard underflow or overflow in base arithmetic)
480dqfma2760 fma  1e-6069 1e-101   0e+6144  -> 1E-6170 Subnormal
481dqfma2761 fma  1e-6069 1e-102   0e+6144  -> 1E-6171 Subnormal
482dqfma2762 fma  1e-6069 1e-103   0e+6144  -> 1E-6172 Subnormal
483dqfma2763 fma  1e-6069 1e-104   0e+6144  -> 1E-6173 Subnormal
484dqfma2764 fma  1e-6069 1e-105   0e+6144  -> 1E-6174 Subnormal
485dqfma2765 fma  1e-6069 1e-106   0e+6144  -> 1E-6175 Subnormal
486dqfma2766 fma  1e-6069 1e-107   0e+6144  -> 1E-6176 Subnormal
487dqfma2767 fma  1e-6069 1e-108   0e+6144  -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped
488dqfma2768 fma  1e-6069 1e-109   0e+6144  -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped
489dqfma2769 fma  1e-6069 1e-110   0e+6144  -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped
490-- [no equivalent of 'subnormal' for overflow]
491dqfma2770 fma  1e+40 1e+6101   0e+6144  -> 1.000000000000000000000000000000E+6141 Clamped
492dqfma2771 fma  1e+40 1e+6102   0e+6144  -> 1.0000000000000000000000000000000E+6142  Clamped
493dqfma2772 fma  1e+40 1e+6103   0e+6144  -> 1.00000000000000000000000000000000E+6143  Clamped
494dqfma2773 fma  1e+40 1e+6104   0e+6144  -> 1.000000000000000000000000000000000E+6144  Clamped
495dqfma2774 fma  1e+40 1e+6105   0e+6144  -> Infinity Overflow Inexact Rounded
496dqfma2775 fma  1e+40 1e+6106   0e+6144  -> Infinity Overflow Inexact Rounded
497dqfma2776 fma  1e+40 1e+6107   0e+6144  -> Infinity Overflow Inexact Rounded
498dqfma2777 fma  1e+40 1e+6108   0e+6144  -> Infinity Overflow Inexact Rounded
499dqfma2778 fma  1e+40 1e+6109   0e+6144  -> Infinity Overflow Inexact Rounded
500dqfma2779 fma  1e+40 1e+6110   0e+6144  -> Infinity Overflow Inexact Rounded
501
502dqfma2801 fma   1.0000E-6172  1       0e+6144  -> 1.0000E-6172 Subnormal
503dqfma2802 fma   1.000E-6172   1e-1    0e+6144  -> 1.000E-6173  Subnormal
504dqfma2803 fma   1.00E-6172    1e-2    0e+6144  -> 1.00E-6174   Subnormal
505dqfma2804 fma   1.0E-6172     1e-3    0e+6144  -> 1.0E-6175    Subnormal
506dqfma2805 fma   1.0E-6172     1e-4    0e+6144  -> 1E-6176     Subnormal Rounded
507dqfma2806 fma   1.3E-6172     1e-4    0e+6144  -> 1E-6176     Underflow Subnormal Inexact Rounded
508dqfma2807 fma   1.5E-6172     1e-4    0e+6144  -> 2E-6176     Underflow Subnormal Inexact Rounded
509dqfma2808 fma   1.7E-6172     1e-4    0e+6144  -> 2E-6176     Underflow Subnormal Inexact Rounded
510dqfma2809 fma   2.3E-6172     1e-4    0e+6144  -> 2E-6176     Underflow Subnormal Inexact Rounded
511dqfma2810 fma   2.5E-6172     1e-4    0e+6144  -> 2E-6176     Underflow Subnormal Inexact Rounded
512dqfma2811 fma   2.7E-6172     1e-4    0e+6144  -> 3E-6176     Underflow Subnormal Inexact Rounded
513dqfma2812 fma   1.49E-6172    1e-4    0e+6144  -> 1E-6176     Underflow Subnormal Inexact Rounded
514dqfma2813 fma   1.50E-6172    1e-4    0e+6144  -> 2E-6176     Underflow Subnormal Inexact Rounded
515dqfma2814 fma   1.51E-6172    1e-4    0e+6144  -> 2E-6176     Underflow Subnormal Inexact Rounded
516dqfma2815 fma   2.49E-6172    1e-4    0e+6144  -> 2E-6176     Underflow Subnormal Inexact Rounded
517dqfma2816 fma   2.50E-6172    1e-4    0e+6144  -> 2E-6176     Underflow Subnormal Inexact Rounded
518dqfma2817 fma   2.51E-6172    1e-4    0e+6144  -> 3E-6176     Underflow Subnormal Inexact Rounded
519
520dqfma2818 fma   1E-6172       1e-4    0e+6144  -> 1E-6176     Subnormal
521dqfma2819 fma   3E-6172       1e-5    0e+6144  -> 0E-6176     Underflow Subnormal Inexact Rounded Clamped
522dqfma2820 fma   5E-6172       1e-5    0e+6144  -> 0E-6176     Underflow Subnormal Inexact Rounded Clamped
523dqfma2821 fma   7E-6172       1e-5    0e+6144  -> 1E-6176     Underflow Subnormal Inexact Rounded
524dqfma2822 fma   9E-6172       1e-5    0e+6144  -> 1E-6176     Underflow Subnormal Inexact Rounded
525dqfma2823 fma   9.9E-6172     1e-5    0e+6144  -> 1E-6176     Underflow Subnormal Inexact Rounded
526
527dqfma2824 fma   1E-6172      -1e-4    0e+6144  -> -1E-6176    Subnormal
528dqfma2825 fma   3E-6172      -1e-5    0e+6144  -> -0E-6176    Underflow Subnormal Inexact Rounded Clamped
529dqfma2826 fma  -5E-6172       1e-5    0e+6144  -> -0E-6176    Underflow Subnormal Inexact Rounded Clamped
530dqfma2827 fma   7E-6172      -1e-5    0e+6144  -> -1E-6176    Underflow Subnormal Inexact Rounded
531dqfma2828 fma  -9E-6172       1e-5    0e+6144  -> -1E-6176    Underflow Subnormal Inexact Rounded
532dqfma2829 fma   9.9E-6172    -1e-5    0e+6144  -> -1E-6176    Underflow Subnormal Inexact Rounded
533dqfma2830 fma   3.0E-6172    -1e-5    0e+6144  -> -0E-6176    Underflow Subnormal Inexact Rounded Clamped
534
535dqfma2831 fma   1.0E-5977     1e-200   0e+6144  -> 0E-6176 Underflow Subnormal Inexact Rounded Clamped
536dqfma2832 fma   1.0E-5977     1e-199   0e+6144  -> 1E-6176    Subnormal Rounded
537dqfma2833 fma   1.0E-5977     1e-198   0e+6144  -> 1.0E-6175    Subnormal
538dqfma2834 fma   2.0E-5977     2e-198   0e+6144  -> 4.0E-6175    Subnormal
539dqfma2835 fma   4.0E-5977     4e-198   0e+6144  -> 1.60E-6174   Subnormal
540dqfma2836 fma  10.0E-5977    10e-198   0e+6144  -> 1.000E-6173  Subnormal
541dqfma2837 fma  30.0E-5977    30e-198   0e+6144  -> 9.000E-6173  Subnormal
542dqfma2838 fma  40.0E-5982    40e-166   0e+6144  -> 1.6000E-6145 Subnormal
543dqfma2839 fma  40.0E-5982    40e-165   0e+6144  -> 1.6000E-6144 Subnormal
544dqfma2840 fma  40.0E-5982    40e-164   0e+6144  -> 1.6000E-6143
545
546-- Long operand overflow may be a different path
547dqfma2870 fma  100  9.999E+6143       0e+6144  ->  Infinity Inexact Overflow Rounded
548dqfma2871 fma  100 -9.999E+6143       0e+6144  -> -Infinity Inexact Overflow Rounded
549dqfma2872 fma       9.999E+6143 100   0e+6144  ->  Infinity Inexact Overflow Rounded
550dqfma2873 fma      -9.999E+6143 100   0e+6144  -> -Infinity Inexact Overflow Rounded
551
552-- check for double-rounded subnormals
553dqfma2881 fma   1.2347E-6133 1.2347E-40    0e+6144  ->  1.524E-6173 Inexact Rounded Subnormal Underflow
554dqfma2882 fma   1.234E-6133 1.234E-40      0e+6144  ->  1.523E-6173 Inexact Rounded Subnormal Underflow
555dqfma2883 fma   1.23E-6133  1.23E-40       0e+6144  ->  1.513E-6173 Inexact Rounded Subnormal Underflow
556dqfma2884 fma   1.2E-6133   1.2E-40        0e+6144  ->  1.44E-6173  Subnormal
557dqfma2885 fma   1.2E-6133   1.2E-41        0e+6144  ->  1.44E-6174  Subnormal
558dqfma2886 fma   1.2E-6133   1.2E-42        0e+6144  ->  1.4E-6175   Subnormal Inexact Rounded Underflow
559dqfma2887 fma   1.2E-6133   1.3E-42        0e+6144  ->  1.6E-6175   Subnormal Inexact Rounded Underflow
560dqfma2888 fma   1.3E-6133   1.3E-42        0e+6144  ->  1.7E-6175   Subnormal Inexact Rounded Underflow
561dqfma2889 fma   1.3E-6133   1.3E-43        0e+6144  ->    2E-6176   Subnormal Inexact Rounded Underflow
562dqfma2890 fma   1.3E-6134   1.3E-43        0e+6144  ->    0E-6176   Clamped Subnormal Inexact Rounded Underflow
563
564dqfma2891 fma   1.2345E-39    1.234E-6133   0e+6144  ->  1.5234E-6172 Inexact Rounded Subnormal Underflow
565dqfma2892 fma   1.23456E-39   1.234E-6133   0e+6144  ->  1.5234E-6172 Inexact Rounded Subnormal Underflow
566dqfma2893 fma   1.2345E-40   1.234E-6133   0e+6144  ->  1.523E-6173  Inexact Rounded Subnormal Underflow
567dqfma2894 fma   1.23456E-40  1.234E-6133   0e+6144  ->  1.523E-6173  Inexact Rounded Subnormal Underflow
568dqfma2895 fma   1.2345E-41   1.234E-6133   0e+6144  ->  1.52E-6174   Inexact Rounded Subnormal Underflow
569dqfma2896 fma   1.23456E-41  1.234E-6133   0e+6144  ->  1.52E-6174   Inexact Rounded Subnormal Underflow
570
571-- Now explore the case where we get a normal result with Underflow
572-- prove operands are exact
573dqfma2906 fma   9.999999999999999999999999999999999E-6143  1                         0e+6144  -> 9.999999999999999999999999999999999E-6143
574dqfma2907 fma                        1  0.09999999999999999999999999999999999       0e+6144  -> 0.09999999999999999999999999999999999
575-- the next rounds to Nmin
576dqfma2908 fma   9.999999999999999999999999999999999E-6143  0.09999999999999999999999999999999999       0e+6144  -> 1.000000000000000000000000000000000E-6143 Underflow Inexact Subnormal Rounded
577
578-- hugest
579dqfma2909 fma  9999999999999999999999999999999999 9999999999999999999999999999999999   0e+6144  -> 9.999999999999999999999999999999998E+67 Inexact Rounded
580
581-- Examples from SQL proposal (Krishna Kulkarni)
582precision:   34
583rounding:    half_up
584maxExponent: 6144
585minExponent: -6143
586dqfma21001  fma  130E-2  120E-2   0e+6144  -> 1.5600
587dqfma21002  fma  130E-2  12E-1    0e+6144  -> 1.560
588dqfma21003  fma  130E-2  1E0      0e+6144  -> 1.30
589dqfma21004  fma  1E2     1E4      0e+6144  -> 1E+6
590
591-- Null tests
592dqfma2990 fma  10  #   0e+6144  -> NaN Invalid_operation
593dqfma2991 fma   # 10   0e+6144  -> NaN Invalid_operation
594
595
596-- ADDITION TESTS ------------------------------------------------------
597rounding:    half_even
598
599-- [first group are 'quick confidence check']
600dqadd3001 fma  1  1       1       ->  2
601dqadd3002 fma  1  2       3       ->  5
602dqadd3003 fma  1  '5.75'  '3.3'   ->  9.05
603dqadd3004 fma  1  '5'     '-3'    ->  2
604dqadd3005 fma  1  '-5'    '-3'    ->  -8
605dqadd3006 fma  1  '-7'    '2.5'   ->  -4.5
606dqadd3007 fma  1  '0.7'   '0.3'   ->  1.0
607dqadd3008 fma  1  '1.25'  '1.25'  ->  2.50
608dqadd3009 fma  1  '1.23456789'  '1.00000000' -> '2.23456789'
609dqadd3010 fma  1  '1.23456789'  '1.00000011' -> '2.23456800'
610
611--             1234567890123456      1234567890123456
612dqadd3011 fma  1  '0.4444444444444444444444444444444446'  '0.5555555555555555555555555555555555' -> '1.000000000000000000000000000000000' Inexact Rounded
613dqadd3012 fma  1  '0.4444444444444444444444444444444445'  '0.5555555555555555555555555555555555' -> '1.000000000000000000000000000000000' Rounded
614dqadd3013 fma  1  '0.4444444444444444444444444444444444'  '0.5555555555555555555555555555555555' -> '0.9999999999999999999999999999999999'
615dqadd3014 fma  1    '4444444444444444444444444444444444' '0.49'   -> '4444444444444444444444444444444444' Inexact Rounded
616dqadd3015 fma  1    '4444444444444444444444444444444444' '0.499'  -> '4444444444444444444444444444444444' Inexact Rounded
617dqadd3016 fma  1    '4444444444444444444444444444444444' '0.4999' -> '4444444444444444444444444444444444' Inexact Rounded
618dqadd3017 fma  1    '4444444444444444444444444444444444' '0.5000' -> '4444444444444444444444444444444444' Inexact Rounded
619dqadd3018 fma  1    '4444444444444444444444444444444444' '0.5001' -> '4444444444444444444444444444444445' Inexact Rounded
620dqadd3019 fma  1    '4444444444444444444444444444444444' '0.501'  -> '4444444444444444444444444444444445' Inexact Rounded
621dqadd3020 fma  1    '4444444444444444444444444444444444' '0.51'   -> '4444444444444444444444444444444445' Inexact Rounded
622
623dqadd3021 fma  1  0 1 -> 1
624dqadd3022 fma  1  1 1 -> 2
625dqadd3023 fma  1  2 1 -> 3
626dqadd3024 fma  1  3 1 -> 4
627dqadd3025 fma  1  4 1 -> 5
628dqadd3026 fma  1  5 1 -> 6
629dqadd3027 fma  1  6 1 -> 7
630dqadd3028 fma  1  7 1 -> 8
631dqadd3029 fma  1  8 1 -> 9
632dqadd3030 fma  1  9 1 -> 10
633
634-- some carrying effects
635dqadd3031 fma  1  '0.9998'  '0.0000' -> '0.9998'
636dqadd3032 fma  1  '0.9998'  '0.0001' -> '0.9999'
637dqadd3033 fma  1  '0.9998'  '0.0002' -> '1.0000'
638dqadd3034 fma  1  '0.9998'  '0.0003' -> '1.0001'
639
640dqadd3035 fma  1  '70'  '10000e+34' -> '1.000000000000000000000000000000000E+38' Inexact Rounded
641dqadd3036 fma  1  '700'  '10000e+34' -> '1.000000000000000000000000000000000E+38' Inexact Rounded
642dqadd3037 fma  1  '7000'  '10000e+34' -> '1.000000000000000000000000000000000E+38' Inexact Rounded
643dqadd3038 fma  1  '70000'  '10000e+34' -> '1.000000000000000000000000000000001E+38' Inexact Rounded
644dqadd3039 fma  1  '700000'  '10000e+34' -> '1.000000000000000000000000000000007E+38' Rounded
645
646-- symmetry:
647dqadd3040 fma  1  '10000e+34'  '70' -> '1.000000000000000000000000000000000E+38' Inexact Rounded
648dqadd3041 fma  1  '10000e+34'  '700' -> '1.000000000000000000000000000000000E+38' Inexact Rounded
649dqadd3042 fma  1  '10000e+34'  '7000' -> '1.000000000000000000000000000000000E+38' Inexact Rounded
650dqadd3044 fma  1  '10000e+34'  '70000' -> '1.000000000000000000000000000000001E+38' Inexact Rounded
651dqadd3045 fma  1  '10000e+34'  '700000' -> '1.000000000000000000000000000000007E+38' Rounded
652
653-- same, without rounding
654dqadd3046 fma  1  '10000e+9'  '7' -> '10000000000007'
655dqadd3047 fma  1  '10000e+9'  '70' -> '10000000000070'
656dqadd3048 fma  1  '10000e+9'  '700' -> '10000000000700'
657dqadd3049 fma  1  '10000e+9'  '7000' -> '10000000007000'
658dqadd3050 fma  1  '10000e+9'  '70000' -> '10000000070000'
659dqadd3051 fma  1  '10000e+9'  '700000' -> '10000000700000'
660dqadd3052 fma  1  '10000e+9'  '7000000' -> '10000007000000'
661
662-- examples from decarith
663dqadd3053 fma  1  '12' '7.00' -> '19.00'
664dqadd3054 fma  1  '1.3' '-1.07' -> '0.23'
665dqadd3055 fma  1  '1.3' '-1.30' -> '0.00'
666dqadd3056 fma  1  '1.3' '-2.07' -> '-0.77'
667dqadd3057 fma  1  '1E+2' '1E+4' -> '1.01E+4'
668
669-- leading zero preservation
670dqadd3061 fma  1  1 '0.0001' -> '1.0001'
671dqadd3062 fma  1  1 '0.00001' -> '1.00001'
672dqadd3063 fma  1  1 '0.000001' -> '1.000001'
673dqadd3064 fma  1  1 '0.0000001' -> '1.0000001'
674dqadd3065 fma  1  1 '0.00000001' -> '1.00000001'
675
676-- some funny zeros [in case of bad signum]
677dqadd3070 fma  1  1  0    -> 1
678dqadd3071 fma  1  1 0.    -> 1
679dqadd3072 fma  1  1  .0   -> 1.0
680dqadd3073 fma  1  1 0.0   -> 1.0
681dqadd3074 fma  1  1 0.00  -> 1.00
682dqadd3075 fma  1   0  1   -> 1
683dqadd3076 fma  1  0.  1   -> 1
684dqadd3077 fma  1   .0 1   -> 1.0
685dqadd3078 fma  1  0.0 1   -> 1.0
686dqadd3079 fma  1  0.00 1  -> 1.00
687
688-- some carries
689dqadd3080 fma  1  999999998 1  -> 999999999
690dqadd3081 fma  1  999999999 1  -> 1000000000
691dqadd3082 fma  1   99999999 1  -> 100000000
692dqadd3083 fma  1    9999999 1  -> 10000000
693dqadd3084 fma  1     999999 1  -> 1000000
694dqadd3085 fma  1      99999 1  -> 100000
695dqadd3086 fma  1       9999 1  -> 10000
696dqadd3087 fma  1        999 1  -> 1000
697dqadd3088 fma  1         99 1  -> 100
698dqadd3089 fma  1          9 1  -> 10
699
700
701-- more LHS swaps
702dqadd3090 fma  1  '-56267E-10'   0 ->  '-0.0000056267'
703dqadd3091 fma  1  '-56267E-6'    0 ->  '-0.056267'
704dqadd3092 fma  1  '-56267E-5'    0 ->  '-0.56267'
705dqadd3093 fma  1  '-56267E-4'    0 ->  '-5.6267'
706dqadd3094 fma  1  '-56267E-3'    0 ->  '-56.267'
707dqadd3095 fma  1  '-56267E-2'    0 ->  '-562.67'
708dqadd3096 fma  1  '-56267E-1'    0 ->  '-5626.7'
709dqadd3097 fma  1  '-56267E-0'    0 ->  '-56267'
710dqadd3098 fma  1  '-5E-10'       0 ->  '-5E-10'
711dqadd3099 fma  1  '-5E-7'        0 ->  '-5E-7'
712dqadd3100 fma  1  '-5E-6'        0 ->  '-0.000005'
713dqadd3101 fma  1  '-5E-5'        0 ->  '-0.00005'
714dqadd3102 fma  1  '-5E-4'        0 ->  '-0.0005'
715dqadd3103 fma  1  '-5E-1'        0 ->  '-0.5'
716dqadd3104 fma  1  '-5E0'         0 ->  '-5'
717dqadd3105 fma  1  '-5E1'         0 ->  '-50'
718dqadd3106 fma  1  '-5E5'         0 ->  '-500000'
719dqadd3107 fma  1  '-5E33'        0 ->  '-5000000000000000000000000000000000'
720dqadd3108 fma  1  '-5E34'        0 ->  '-5.000000000000000000000000000000000E+34'  Rounded
721dqadd3109 fma  1  '-5E35'        0 ->  '-5.000000000000000000000000000000000E+35'  Rounded
722dqadd3110 fma  1  '-5E36'        0 ->  '-5.000000000000000000000000000000000E+36'  Rounded
723dqadd3111 fma  1  '-5E100'       0 ->  '-5.000000000000000000000000000000000E+100' Rounded
724
725-- more RHS swaps
726dqadd3113 fma  1  0  '-56267E-10' ->  '-0.0000056267'
727dqadd3114 fma  1  0  '-56267E-6'  ->  '-0.056267'
728dqadd3116 fma  1  0  '-56267E-5'  ->  '-0.56267'
729dqadd3117 fma  1  0  '-56267E-4'  ->  '-5.6267'
730dqadd3119 fma  1  0  '-56267E-3'  ->  '-56.267'
731dqadd3120 fma  1  0  '-56267E-2'  ->  '-562.67'
732dqadd3121 fma  1  0  '-56267E-1'  ->  '-5626.7'
733dqadd3122 fma  1  0  '-56267E-0'  ->  '-56267'
734dqadd3123 fma  1  0  '-5E-10'     ->  '-5E-10'
735dqadd3124 fma  1  0  '-5E-7'      ->  '-5E-7'
736dqadd3125 fma  1  0  '-5E-6'      ->  '-0.000005'
737dqadd3126 fma  1  0  '-5E-5'      ->  '-0.00005'
738dqadd3127 fma  1  0  '-5E-4'      ->  '-0.0005'
739dqadd3128 fma  1  0  '-5E-1'      ->  '-0.5'
740dqadd3129 fma  1  0  '-5E0'       ->  '-5'
741dqadd3130 fma  1  0  '-5E1'       ->  '-50'
742dqadd3131 fma  1  0  '-5E5'       ->  '-500000'
743dqadd3132 fma  1  0  '-5E33'      ->  '-5000000000000000000000000000000000'
744dqadd3133 fma  1  0  '-5E34'      ->  '-5.000000000000000000000000000000000E+34'   Rounded
745dqadd3134 fma  1  0  '-5E35'      ->  '-5.000000000000000000000000000000000E+35'   Rounded
746dqadd3135 fma  1  0  '-5E36'      ->  '-5.000000000000000000000000000000000E+36'   Rounded
747dqadd3136 fma  1  0  '-5E100'     ->  '-5.000000000000000000000000000000000E+100'  Rounded
748
749-- related
750dqadd3137 fma  1   1  '0E-39'      ->  '1.000000000000000000000000000000000'  Rounded
751dqadd3138 fma  1  -1  '0E-39'      ->  '-1.000000000000000000000000000000000' Rounded
752dqadd3139 fma  1  '0E-39' 1        ->  '1.000000000000000000000000000000000'  Rounded
753dqadd3140 fma  1  '0E-39' -1       ->  '-1.000000000000000000000000000000000' Rounded
754dqadd3141 fma  1  1E+29   0.0000   ->  '100000000000000000000000000000.0000'
755dqadd3142 fma  1  1E+29   0.00000  ->  '100000000000000000000000000000.0000'  Rounded
756dqadd3143 fma  1  0.000   1E+30    ->  '1000000000000000000000000000000.000'
757dqadd3144 fma  1  0.0000  1E+30    ->  '1000000000000000000000000000000.000'  Rounded
758
759-- [some of the next group are really constructor tests]
760dqadd3146 fma  1  '00.0'  0       ->  '0.0'
761dqadd3147 fma  1  '0.00'  0       ->  '0.00'
762dqadd3148 fma  1   0      '0.00'  ->  '0.00'
763dqadd3149 fma  1   0      '00.0'  ->  '0.0'
764dqadd3150 fma  1  '00.0'  '0.00'  ->  '0.00'
765dqadd3151 fma  1  '0.00'  '00.0'  ->  '0.00'
766dqadd3152 fma  1  '3'     '.3'    ->  '3.3'
767dqadd3153 fma  1  '3.'    '.3'    ->  '3.3'
768dqadd3154 fma  1  '3.0'   '.3'    ->  '3.3'
769dqadd3155 fma  1  '3.00'  '.3'    ->  '3.30'
770dqadd3156 fma  1  '3'     '3'     ->  '6'
771dqadd3157 fma  1  '3'     '+3'    ->  '6'
772dqadd3158 fma  1  '3'     '-3'    ->  '0'
773dqadd3159 fma  1  '0.3'   '-0.3'  ->  '0.0'
774dqadd3160 fma  1  '0.03'  '-0.03' ->  '0.00'
775
776-- try borderline precision, with carries, etc.
777dqadd3161 fma  1  '1E+12' '-1'    -> '999999999999'
778dqadd3162 fma  1  '1E+12'  '1.11' -> '1000000000001.11'
779dqadd3163 fma  1  '1.11'  '1E+12' -> '1000000000001.11'
780dqadd3164 fma  1  '-1'    '1E+12' -> '999999999999'
781dqadd3165 fma  1  '7E+12' '-1'    -> '6999999999999'
782dqadd3166 fma  1  '7E+12'  '1.11' -> '7000000000001.11'
783dqadd3167 fma  1  '1.11'  '7E+12' -> '7000000000001.11'
784dqadd3168 fma  1  '-1'    '7E+12' -> '6999999999999'
785
786rounding: half_up
787dqadd3170 fma  1  '4.444444444444444444444444444444444'  '0.5555555555555555555555555555555567' -> '5.000000000000000000000000000000001' Inexact Rounded
788dqadd3171 fma  1  '4.444444444444444444444444444444444'  '0.5555555555555555555555555555555566' -> '5.000000000000000000000000000000001' Inexact Rounded
789dqadd3172 fma  1  '4.444444444444444444444444444444444'  '0.5555555555555555555555555555555565' -> '5.000000000000000000000000000000001' Inexact Rounded
790dqadd3173 fma  1  '4.444444444444444444444444444444444'  '0.5555555555555555555555555555555564' -> '5.000000000000000000000000000000000' Inexact Rounded
791dqadd3174 fma  1  '4.444444444444444444444444444444444'  '0.5555555555555555555555555555555553' -> '4.999999999999999999999999999999999' Inexact Rounded
792dqadd3175 fma  1  '4.444444444444444444444444444444444'  '0.5555555555555555555555555555555552' -> '4.999999999999999999999999999999999' Inexact Rounded
793dqadd3176 fma  1  '4.444444444444444444444444444444444'  '0.5555555555555555555555555555555551' -> '4.999999999999999999999999999999999' Inexact Rounded
794dqadd3177 fma  1  '4.444444444444444444444444444444444'  '0.5555555555555555555555555555555550' -> '4.999999999999999999999999999999999' Rounded
795dqadd3178 fma  1  '4.444444444444444444444444444444444'  '0.5555555555555555555555555555555545' -> '4.999999999999999999999999999999999' Inexact Rounded
796dqadd3179 fma  1  '4.444444444444444444444444444444444'  '0.5555555555555555555555555555555544' -> '4.999999999999999999999999999999998' Inexact Rounded
797dqadd3180 fma  1  '4.444444444444444444444444444444444'  '0.5555555555555555555555555555555543' -> '4.999999999999999999999999999999998' Inexact Rounded
798dqadd3181 fma  1  '4.444444444444444444444444444444444'  '0.5555555555555555555555555555555542' -> '4.999999999999999999999999999999998' Inexact Rounded
799dqadd3182 fma  1  '4.444444444444444444444444444444444'  '0.5555555555555555555555555555555541' -> '4.999999999999999999999999999999998' Inexact Rounded
800dqadd3183 fma  1  '4.444444444444444444444444444444444'  '0.5555555555555555555555555555555540' -> '4.999999999999999999999999999999998' Rounded
801
802-- and some more, including residue effects and different roundings
803rounding: half_up
804dqadd3200 fma  1  '1231234567890123456784560123456789' 0             -> '1231234567890123456784560123456789'
805dqadd3201 fma  1  '1231234567890123456784560123456789' 0.000000001   -> '1231234567890123456784560123456789' Inexact Rounded
806dqadd3202 fma  1  '1231234567890123456784560123456789' 0.000001      -> '1231234567890123456784560123456789' Inexact Rounded
807dqadd3203 fma  1  '1231234567890123456784560123456789' 0.1           -> '1231234567890123456784560123456789' Inexact Rounded
808dqadd3204 fma  1  '1231234567890123456784560123456789' 0.4           -> '1231234567890123456784560123456789' Inexact Rounded
809dqadd3205 fma  1  '1231234567890123456784560123456789' 0.49          -> '1231234567890123456784560123456789' Inexact Rounded
810dqadd3206 fma  1  '1231234567890123456784560123456789' 0.499999      -> '1231234567890123456784560123456789' Inexact Rounded
811dqadd3207 fma  1  '1231234567890123456784560123456789' 0.499999999   -> '1231234567890123456784560123456789' Inexact Rounded
812dqadd3208 fma  1  '1231234567890123456784560123456789' 0.5           -> '1231234567890123456784560123456790' Inexact Rounded
813dqadd3209 fma  1  '1231234567890123456784560123456789' 0.500000001   -> '1231234567890123456784560123456790' Inexact Rounded
814dqadd3210 fma  1  '1231234567890123456784560123456789' 0.500001      -> '1231234567890123456784560123456790' Inexact Rounded
815dqadd3211 fma  1  '1231234567890123456784560123456789' 0.51          -> '1231234567890123456784560123456790' Inexact Rounded
816dqadd3212 fma  1  '1231234567890123456784560123456789' 0.6           -> '1231234567890123456784560123456790' Inexact Rounded
817dqadd3213 fma  1  '1231234567890123456784560123456789' 0.9           -> '1231234567890123456784560123456790' Inexact Rounded
818dqadd3214 fma  1  '1231234567890123456784560123456789' 0.99999       -> '1231234567890123456784560123456790' Inexact Rounded
819dqadd3215 fma  1  '1231234567890123456784560123456789' 0.999999999   -> '1231234567890123456784560123456790' Inexact Rounded
820dqadd3216 fma  1  '1231234567890123456784560123456789' 1             -> '1231234567890123456784560123456790'
821dqadd3217 fma  1  '1231234567890123456784560123456789' 1.000000001   -> '1231234567890123456784560123456790' Inexact Rounded
822dqadd3218 fma  1  '1231234567890123456784560123456789' 1.00001       -> '1231234567890123456784560123456790' Inexact Rounded
823dqadd3219 fma  1  '1231234567890123456784560123456789' 1.1           -> '1231234567890123456784560123456790' Inexact Rounded
824
825rounding: half_even
826dqadd3220 fma  1  '1231234567890123456784560123456789' 0             -> '1231234567890123456784560123456789'
827dqadd3221 fma  1  '1231234567890123456784560123456789' 0.000000001   -> '1231234567890123456784560123456789' Inexact Rounded
828dqadd3222 fma  1  '1231234567890123456784560123456789' 0.000001      -> '1231234567890123456784560123456789' Inexact Rounded
829dqadd3223 fma  1  '1231234567890123456784560123456789' 0.1           -> '1231234567890123456784560123456789' Inexact Rounded
830dqadd3224 fma  1  '1231234567890123456784560123456789' 0.4           -> '1231234567890123456784560123456789' Inexact Rounded
831dqadd3225 fma  1  '1231234567890123456784560123456789' 0.49          -> '1231234567890123456784560123456789' Inexact Rounded
832dqadd3226 fma  1  '1231234567890123456784560123456789' 0.499999      -> '1231234567890123456784560123456789' Inexact Rounded
833dqadd3227 fma  1  '1231234567890123456784560123456789' 0.499999999   -> '1231234567890123456784560123456789' Inexact Rounded
834dqadd3228 fma  1  '1231234567890123456784560123456789' 0.5           -> '1231234567890123456784560123456790' Inexact Rounded
835dqadd3229 fma  1  '1231234567890123456784560123456789' 0.500000001   -> '1231234567890123456784560123456790' Inexact Rounded
836dqadd3230 fma  1  '1231234567890123456784560123456789' 0.500001      -> '1231234567890123456784560123456790' Inexact Rounded
837dqadd3231 fma  1  '1231234567890123456784560123456789' 0.51          -> '1231234567890123456784560123456790' Inexact Rounded
838dqadd3232 fma  1  '1231234567890123456784560123456789' 0.6           -> '1231234567890123456784560123456790' Inexact Rounded
839dqadd3233 fma  1  '1231234567890123456784560123456789' 0.9           -> '1231234567890123456784560123456790' Inexact Rounded
840dqadd3234 fma  1  '1231234567890123456784560123456789' 0.99999       -> '1231234567890123456784560123456790' Inexact Rounded
841dqadd3235 fma  1  '1231234567890123456784560123456789' 0.999999999   -> '1231234567890123456784560123456790' Inexact Rounded
842dqadd3236 fma  1  '1231234567890123456784560123456789' 1             -> '1231234567890123456784560123456790'
843dqadd3237 fma  1  '1231234567890123456784560123456789' 1.00000001    -> '1231234567890123456784560123456790' Inexact Rounded
844dqadd3238 fma  1  '1231234567890123456784560123456789' 1.00001       -> '1231234567890123456784560123456790' Inexact Rounded
845dqadd3239 fma  1  '1231234567890123456784560123456789' 1.1           -> '1231234567890123456784560123456790' Inexact Rounded
846-- critical few with even bottom digit...
847dqadd3240 fma  1  '1231234567890123456784560123456788' 0.499999999   -> '1231234567890123456784560123456788' Inexact Rounded
848dqadd3241 fma  1  '1231234567890123456784560123456788' 0.5           -> '1231234567890123456784560123456788' Inexact Rounded
849dqadd3242 fma  1  '1231234567890123456784560123456788' 0.500000001   -> '1231234567890123456784560123456789' Inexact Rounded
850
851rounding: down
852dqadd3250 fma  1  '1231234567890123456784560123456789' 0             -> '1231234567890123456784560123456789'
853dqadd3251 fma  1  '1231234567890123456784560123456789' 0.000000001   -> '1231234567890123456784560123456789' Inexact Rounded
854dqadd3252 fma  1  '1231234567890123456784560123456789' 0.000001      -> '1231234567890123456784560123456789' Inexact Rounded
855dqadd3253 fma  1  '1231234567890123456784560123456789' 0.1           -> '1231234567890123456784560123456789' Inexact Rounded
856dqadd3254 fma  1  '1231234567890123456784560123456789' 0.4           -> '1231234567890123456784560123456789' Inexact Rounded
857dqadd3255 fma  1  '1231234567890123456784560123456789' 0.49          -> '1231234567890123456784560123456789' Inexact Rounded
858dqadd3256 fma  1  '1231234567890123456784560123456789' 0.499999      -> '1231234567890123456784560123456789' Inexact Rounded
859dqadd3257 fma  1  '1231234567890123456784560123456789' 0.499999999   -> '1231234567890123456784560123456789' Inexact Rounded
860dqadd3258 fma  1  '1231234567890123456784560123456789' 0.5           -> '1231234567890123456784560123456789' Inexact Rounded
861dqadd3259 fma  1  '1231234567890123456784560123456789' 0.500000001   -> '1231234567890123456784560123456789' Inexact Rounded
862dqadd3260 fma  1  '1231234567890123456784560123456789' 0.500001      -> '1231234567890123456784560123456789' Inexact Rounded
863dqadd3261 fma  1  '1231234567890123456784560123456789' 0.51          -> '1231234567890123456784560123456789' Inexact Rounded
864dqadd3262 fma  1  '1231234567890123456784560123456789' 0.6           -> '1231234567890123456784560123456789' Inexact Rounded
865dqadd3263 fma  1  '1231234567890123456784560123456789' 0.9           -> '1231234567890123456784560123456789' Inexact Rounded
866dqadd3264 fma  1  '1231234567890123456784560123456789' 0.99999       -> '1231234567890123456784560123456789' Inexact Rounded
867dqadd3265 fma  1  '1231234567890123456784560123456789' 0.999999999   -> '1231234567890123456784560123456789' Inexact Rounded
868dqadd3266 fma  1  '1231234567890123456784560123456789' 1             -> '1231234567890123456784560123456790'
869dqadd3267 fma  1  '1231234567890123456784560123456789' 1.00000001    -> '1231234567890123456784560123456790' Inexact Rounded
870dqadd3268 fma  1  '1231234567890123456784560123456789' 1.00001       -> '1231234567890123456784560123456790' Inexact Rounded
871dqadd3269 fma  1  '1231234567890123456784560123456789' 1.1           -> '1231234567890123456784560123456790' Inexact Rounded
872
873-- 1 in last place tests
874rounding: half_up
875dqadd3301 fma  1   -1   1      ->   0
876dqadd3302 fma  1    0   1      ->   1
877dqadd3303 fma  1    1   1      ->   2
878dqadd3304 fma  1   12   1      ->  13
879dqadd3305 fma  1   98   1      ->  99
880dqadd3306 fma  1   99   1      -> 100
881dqadd3307 fma  1  100   1      -> 101
882dqadd3308 fma  1  101   1      -> 102
883dqadd3309 fma  1   -1  -1      ->  -2
884dqadd3310 fma  1    0  -1      ->  -1
885dqadd3311 fma  1    1  -1      ->   0
886dqadd3312 fma  1   12  -1      ->  11
887dqadd3313 fma  1   98  -1      ->  97
888dqadd3314 fma  1   99  -1      ->  98
889dqadd3315 fma  1  100  -1      ->  99
890dqadd3316 fma  1  101  -1      -> 100
891
892dqadd3321 fma  1  -0.01  0.01    ->  0.00
893dqadd3322 fma  1   0.00  0.01    ->  0.01
894dqadd3323 fma  1   0.01  0.01    ->  0.02
895dqadd3324 fma  1   0.12  0.01    ->  0.13
896dqadd3325 fma  1   0.98  0.01    ->  0.99
897dqadd3326 fma  1   0.99  0.01    ->  1.00
898dqadd3327 fma  1   1.00  0.01    ->  1.01
899dqadd3328 fma  1   1.01  0.01    ->  1.02
900dqadd3329 fma  1  -0.01 -0.01    -> -0.02
901dqadd3330 fma  1   0.00 -0.01    -> -0.01
902dqadd3331 fma  1   0.01 -0.01    ->  0.00
903dqadd3332 fma  1   0.12 -0.01    ->  0.11
904dqadd3333 fma  1   0.98 -0.01    ->  0.97
905dqadd3334 fma  1   0.99 -0.01    ->  0.98
906dqadd3335 fma  1   1.00 -0.01    ->  0.99
907dqadd3336 fma  1   1.01 -0.01    ->  1.00
908
909-- some more cases where adding 0 affects the coefficient
910dqadd3340 fma  1  1E+3    0    ->         1000
911dqadd3341 fma  1  1E+33   0    ->    1000000000000000000000000000000000
912dqadd3342 fma  1  1E+34   0    ->   1.000000000000000000000000000000000E+34  Rounded
913dqadd3343 fma  1  1E+35   0    ->   1.000000000000000000000000000000000E+35  Rounded
914-- which simply follow from these cases ...
915dqadd3344 fma  1  1E+3    1    ->         1001
916dqadd3345 fma  1  1E+33   1    ->    1000000000000000000000000000000001
917dqadd3346 fma  1  1E+34   1    ->   1.000000000000000000000000000000000E+34  Inexact Rounded
918dqadd3347 fma  1  1E+35   1    ->   1.000000000000000000000000000000000E+35  Inexact Rounded
919dqadd3348 fma  1  1E+3    7    ->         1007
920dqadd3349 fma  1  1E+33   7    ->    1000000000000000000000000000000007
921dqadd3350 fma  1  1E+34   7    ->   1.000000000000000000000000000000001E+34  Inexact Rounded
922dqadd3351 fma  1  1E+35   7    ->   1.000000000000000000000000000000000E+35  Inexact Rounded
923
924-- tryzeros cases
925rounding:    half_up
926dqadd3360  fma  1  0E+50 10000E+1  -> 1.0000E+5
927dqadd3361  fma  1  0E-50 10000E+1  -> 100000.0000000000000000000000000000 Rounded
928dqadd3362  fma  1  10000E+1 0E-50  -> 100000.0000000000000000000000000000 Rounded
929dqadd3363  fma  1  10000E+1 10000E-50  -> 100000.0000000000000000000000000000 Rounded Inexact
930dqadd3364  fma  1  9.999999999999999999999999999999999E+6144 -9.999999999999999999999999999999999E+6144 -> 0E+6111
931--            1 234567890123456789012345678901234
932
933-- a curiosity from JSR 13 testing
934rounding:    half_down
935dqadd3370 fma  1   999999999999999999999999999999999 815 -> 1000000000000000000000000000000814
936dqadd3371 fma  1  9999999999999999999999999999999999 815 -> 1.000000000000000000000000000000081E+34 Rounded Inexact
937rounding:    half_up
938dqadd3372 fma  1   999999999999999999999999999999999 815 -> 1000000000000000000000000000000814
939dqadd3373 fma  1  9999999999999999999999999999999999 815 -> 1.000000000000000000000000000000081E+34 Rounded Inexact
940rounding:    half_even
941dqadd3374 fma  1   999999999999999999999999999999999 815 -> 1000000000000000000000000000000814
942dqadd3375 fma  1  9999999999999999999999999999999999 815 -> 1.000000000000000000000000000000081E+34 Rounded Inexact
943
944-- ulp replacement tests
945dqadd3400 fma  1    1   77e-32      ->  1.00000000000000000000000000000077
946dqadd3401 fma  1    1   77e-33      ->  1.000000000000000000000000000000077
947dqadd3402 fma  1    1   77e-34      ->  1.000000000000000000000000000000008 Inexact Rounded
948dqadd3403 fma  1    1   77e-35      ->  1.000000000000000000000000000000001 Inexact Rounded
949dqadd3404 fma  1    1   77e-36      ->  1.000000000000000000000000000000000 Inexact Rounded
950dqadd3405 fma  1    1   77e-37      ->  1.000000000000000000000000000000000 Inexact Rounded
951dqadd3406 fma  1    1   77e-299     ->  1.000000000000000000000000000000000 Inexact Rounded
952
953dqadd3410 fma  1   10   77e-32      ->  10.00000000000000000000000000000077
954dqadd3411 fma  1   10   77e-33      ->  10.00000000000000000000000000000008 Inexact Rounded
955dqadd3412 fma  1   10   77e-34      ->  10.00000000000000000000000000000001 Inexact Rounded
956dqadd3413 fma  1   10   77e-35      ->  10.00000000000000000000000000000000 Inexact Rounded
957dqadd3414 fma  1   10   77e-36      ->  10.00000000000000000000000000000000 Inexact Rounded
958dqadd3415 fma  1   10   77e-37      ->  10.00000000000000000000000000000000 Inexact Rounded
959dqadd3416 fma  1   10   77e-299     ->  10.00000000000000000000000000000000 Inexact Rounded
960
961dqadd3420 fma  1   77e-32       1   ->  1.00000000000000000000000000000077
962dqadd3421 fma  1   77e-33       1   ->  1.000000000000000000000000000000077
963dqadd3422 fma  1   77e-34       1   ->  1.000000000000000000000000000000008 Inexact Rounded
964dqadd3423 fma  1   77e-35       1   ->  1.000000000000000000000000000000001 Inexact Rounded
965dqadd3424 fma  1   77e-36       1   ->  1.000000000000000000000000000000000 Inexact Rounded
966dqadd3425 fma  1   77e-37       1   ->  1.000000000000000000000000000000000 Inexact Rounded
967dqadd3426 fma  1   77e-299      1   ->  1.000000000000000000000000000000000 Inexact Rounded
968
969dqadd3430 fma  1   77e-32      10   ->  10.00000000000000000000000000000077
970dqadd3431 fma  1   77e-33      10   ->  10.00000000000000000000000000000008 Inexact Rounded
971dqadd3432 fma  1   77e-34      10   ->  10.00000000000000000000000000000001 Inexact Rounded
972dqadd3433 fma  1   77e-35      10   ->  10.00000000000000000000000000000000 Inexact Rounded
973dqadd3434 fma  1   77e-36      10   ->  10.00000000000000000000000000000000 Inexact Rounded
974dqadd3435 fma  1   77e-37      10   ->  10.00000000000000000000000000000000 Inexact Rounded
975dqadd3436 fma  1   77e-299     10   ->  10.00000000000000000000000000000000 Inexact Rounded
976
977-- negative ulps
978dqadd36440 fma  1    1   -77e-32      ->  0.99999999999999999999999999999923
979dqadd36441 fma  1    1   -77e-33      ->  0.999999999999999999999999999999923
980dqadd36442 fma  1    1   -77e-34      ->  0.9999999999999999999999999999999923
981dqadd36443 fma  1    1   -77e-35      ->  0.9999999999999999999999999999999992 Inexact Rounded
982dqadd36444 fma  1    1   -77e-36      ->  0.9999999999999999999999999999999999 Inexact Rounded
983dqadd36445 fma  1    1   -77e-37      ->  1.000000000000000000000000000000000 Inexact Rounded
984dqadd36446 fma  1    1   -77e-99      ->  1.000000000000000000000000000000000 Inexact Rounded
985
986dqadd36450 fma  1   10   -77e-32      ->   9.99999999999999999999999999999923
987dqadd36451 fma  1   10   -77e-33      ->   9.999999999999999999999999999999923
988dqadd36452 fma  1   10   -77e-34      ->   9.999999999999999999999999999999992 Inexact Rounded
989dqadd36453 fma  1   10   -77e-35      ->   9.999999999999999999999999999999999 Inexact Rounded
990dqadd36454 fma  1   10   -77e-36      ->  10.00000000000000000000000000000000 Inexact Rounded
991dqadd36455 fma  1   10   -77e-37      ->  10.00000000000000000000000000000000 Inexact Rounded
992dqadd36456 fma  1   10   -77e-99      ->  10.00000000000000000000000000000000 Inexact Rounded
993
994dqadd36460 fma  1   -77e-32       1   ->  0.99999999999999999999999999999923
995dqadd36461 fma  1   -77e-33       1   ->  0.999999999999999999999999999999923
996dqadd36462 fma  1   -77e-34       1   ->  0.9999999999999999999999999999999923
997dqadd36463 fma  1   -77e-35       1   ->  0.9999999999999999999999999999999992 Inexact Rounded
998dqadd36464 fma  1   -77e-36       1   ->  0.9999999999999999999999999999999999 Inexact Rounded
999dqadd36465 fma  1   -77e-37       1   ->  1.000000000000000000000000000000000 Inexact Rounded
1000dqadd36466 fma  1   -77e-99       1   ->  1.000000000000000000000000000000000 Inexact Rounded
1001
1002dqadd36470 fma  1   -77e-32      10   ->   9.99999999999999999999999999999923
1003dqadd36471 fma  1   -77e-33      10   ->   9.999999999999999999999999999999923
1004dqadd36472 fma  1   -77e-34      10   ->   9.999999999999999999999999999999992 Inexact Rounded
1005dqadd36473 fma  1   -77e-35      10   ->   9.999999999999999999999999999999999 Inexact Rounded
1006dqadd36474 fma  1   -77e-36      10   ->  10.00000000000000000000000000000000 Inexact Rounded
1007dqadd36475 fma  1   -77e-37      10   ->  10.00000000000000000000000000000000 Inexact Rounded
1008dqadd36476 fma  1   -77e-99      10   ->  10.00000000000000000000000000000000 Inexact Rounded
1009
1010-- negative ulps
1011dqadd36480 fma  1   -1    77e-32      ->  -0.99999999999999999999999999999923
1012dqadd36481 fma  1   -1    77e-33      ->  -0.999999999999999999999999999999923
1013dqadd36482 fma  1   -1    77e-34      ->  -0.9999999999999999999999999999999923
1014dqadd36483 fma  1   -1    77e-35      ->  -0.9999999999999999999999999999999992 Inexact Rounded
1015dqadd36484 fma  1   -1    77e-36      ->  -0.9999999999999999999999999999999999 Inexact Rounded
1016dqadd36485 fma  1   -1    77e-37      ->  -1.000000000000000000000000000000000 Inexact Rounded
1017dqadd36486 fma  1   -1    77e-99      ->  -1.000000000000000000000000000000000 Inexact Rounded
1018
1019dqadd36490 fma  1  -10    77e-32      ->   -9.99999999999999999999999999999923
1020dqadd36491 fma  1  -10    77e-33      ->   -9.999999999999999999999999999999923
1021dqadd36492 fma  1  -10    77e-34      ->   -9.999999999999999999999999999999992 Inexact Rounded
1022dqadd36493 fma  1  -10    77e-35      ->   -9.999999999999999999999999999999999 Inexact Rounded
1023dqadd36494 fma  1  -10    77e-36      ->  -10.00000000000000000000000000000000 Inexact Rounded
1024dqadd36495 fma  1  -10    77e-37      ->  -10.00000000000000000000000000000000 Inexact Rounded
1025dqadd36496 fma  1  -10    77e-99      ->  -10.00000000000000000000000000000000 Inexact Rounded
1026
1027dqadd36500 fma  1    77e-32      -1   ->  -0.99999999999999999999999999999923
1028dqadd36501 fma  1    77e-33      -1   ->  -0.999999999999999999999999999999923
1029dqadd36502 fma  1    77e-34      -1   ->  -0.9999999999999999999999999999999923
1030dqadd36503 fma  1    77e-35      -1   ->  -0.9999999999999999999999999999999992 Inexact Rounded
1031dqadd36504 fma  1    77e-36      -1   ->  -0.9999999999999999999999999999999999 Inexact Rounded
1032dqadd36505 fma  1    77e-37      -1   ->  -1.000000000000000000000000000000000 Inexact Rounded
1033dqadd36506 fma  1    77e-99      -1   ->  -1.000000000000000000000000000000000 Inexact Rounded
1034
1035dqadd36510 fma  1    77e-32      -10  ->   -9.99999999999999999999999999999923
1036dqadd36511 fma  1    77e-33      -10  ->   -9.999999999999999999999999999999923
1037dqadd36512 fma  1    77e-34      -10  ->   -9.999999999999999999999999999999992 Inexact Rounded
1038dqadd36513 fma  1    77e-35      -10  ->   -9.999999999999999999999999999999999 Inexact Rounded
1039dqadd36514 fma  1    77e-36      -10  ->  -10.00000000000000000000000000000000 Inexact Rounded
1040dqadd36515 fma  1    77e-37      -10  ->  -10.00000000000000000000000000000000 Inexact Rounded
1041dqadd36516 fma  1    77e-99      -10  ->  -10.00000000000000000000000000000000 Inexact Rounded
1042
1043-- and some more residue effects and different roundings
1044rounding: half_up
1045dqadd36540 fma  1  '9876543219876543216543210123456789' 0             -> '9876543219876543216543210123456789'
1046dqadd36541 fma  1  '9876543219876543216543210123456789' 0.000000001   -> '9876543219876543216543210123456789' Inexact Rounded
1047dqadd36542 fma  1  '9876543219876543216543210123456789' 0.000001      -> '9876543219876543216543210123456789' Inexact Rounded
1048dqadd36543 fma  1  '9876543219876543216543210123456789' 0.1           -> '9876543219876543216543210123456789' Inexact Rounded
1049dqadd36544 fma  1  '9876543219876543216543210123456789' 0.4           -> '9876543219876543216543210123456789' Inexact Rounded
1050dqadd36545 fma  1  '9876543219876543216543210123456789' 0.49          -> '9876543219876543216543210123456789' Inexact Rounded
1051dqadd36546 fma  1  '9876543219876543216543210123456789' 0.499999      -> '9876543219876543216543210123456789' Inexact Rounded
1052dqadd36547 fma  1  '9876543219876543216543210123456789' 0.499999999   -> '9876543219876543216543210123456789' Inexact Rounded
1053dqadd36548 fma  1  '9876543219876543216543210123456789' 0.5           -> '9876543219876543216543210123456790' Inexact Rounded
1054dqadd36549 fma  1  '9876543219876543216543210123456789' 0.500000001   -> '9876543219876543216543210123456790' Inexact Rounded
1055dqadd36550 fma  1  '9876543219876543216543210123456789' 0.500001      -> '9876543219876543216543210123456790' Inexact Rounded
1056dqadd36551 fma  1  '9876543219876543216543210123456789' 0.51          -> '9876543219876543216543210123456790' Inexact Rounded
1057dqadd36552 fma  1  '9876543219876543216543210123456789' 0.6           -> '9876543219876543216543210123456790' Inexact Rounded
1058dqadd36553 fma  1  '9876543219876543216543210123456789' 0.9           -> '9876543219876543216543210123456790' Inexact Rounded
1059dqadd36554 fma  1  '9876543219876543216543210123456789' 0.99999       -> '9876543219876543216543210123456790' Inexact Rounded
1060dqadd36555 fma  1  '9876543219876543216543210123456789' 0.999999999   -> '9876543219876543216543210123456790' Inexact Rounded
1061dqadd36556 fma  1  '9876543219876543216543210123456789' 1             -> '9876543219876543216543210123456790'
1062dqadd36557 fma  1  '9876543219876543216543210123456789' 1.000000001   -> '9876543219876543216543210123456790' Inexact Rounded
1063dqadd36558 fma  1  '9876543219876543216543210123456789' 1.00001       -> '9876543219876543216543210123456790' Inexact Rounded
1064dqadd36559 fma  1  '9876543219876543216543210123456789' 1.1           -> '9876543219876543216543210123456790' Inexact Rounded
1065
1066rounding: half_even
1067dqadd36560 fma  1  '9876543219876543216543210123456789' 0             -> '9876543219876543216543210123456789'
1068dqadd36561 fma  1  '9876543219876543216543210123456789' 0.000000001   -> '9876543219876543216543210123456789' Inexact Rounded
1069dqadd36562 fma  1  '9876543219876543216543210123456789' 0.000001      -> '9876543219876543216543210123456789' Inexact Rounded
1070dqadd36563 fma  1  '9876543219876543216543210123456789' 0.1           -> '9876543219876543216543210123456789' Inexact Rounded
1071dqadd36564 fma  1  '9876543219876543216543210123456789' 0.4           -> '9876543219876543216543210123456789' Inexact Rounded
1072dqadd36565 fma  1  '9876543219876543216543210123456789' 0.49          -> '9876543219876543216543210123456789' Inexact Rounded
1073dqadd36566 fma  1  '9876543219876543216543210123456789' 0.499999      -> '9876543219876543216543210123456789' Inexact Rounded
1074dqadd36567 fma  1  '9876543219876543216543210123456789' 0.499999999   -> '9876543219876543216543210123456789' Inexact Rounded
1075dqadd36568 fma  1  '9876543219876543216543210123456789' 0.5           -> '9876543219876543216543210123456790' Inexact Rounded
1076dqadd36569 fma  1  '9876543219876543216543210123456789' 0.500000001   -> '9876543219876543216543210123456790' Inexact Rounded
1077dqadd36570 fma  1  '9876543219876543216543210123456789' 0.500001      -> '9876543219876543216543210123456790' Inexact Rounded
1078dqadd36571 fma  1  '9876543219876543216543210123456789' 0.51          -> '9876543219876543216543210123456790' Inexact Rounded
1079dqadd36572 fma  1  '9876543219876543216543210123456789' 0.6           -> '9876543219876543216543210123456790' Inexact Rounded
1080dqadd36573 fma  1  '9876543219876543216543210123456789' 0.9           -> '9876543219876543216543210123456790' Inexact Rounded
1081dqadd36574 fma  1  '9876543219876543216543210123456789' 0.99999       -> '9876543219876543216543210123456790' Inexact Rounded
1082dqadd36575 fma  1  '9876543219876543216543210123456789' 0.999999999   -> '9876543219876543216543210123456790' Inexact Rounded
1083dqadd36576 fma  1  '9876543219876543216543210123456789' 1             -> '9876543219876543216543210123456790'
1084dqadd36577 fma  1  '9876543219876543216543210123456789' 1.00000001    -> '9876543219876543216543210123456790' Inexact Rounded
1085dqadd36578 fma  1  '9876543219876543216543210123456789' 1.00001       -> '9876543219876543216543210123456790' Inexact Rounded
1086dqadd36579 fma  1  '9876543219876543216543210123456789' 1.1           -> '9876543219876543216543210123456790' Inexact Rounded
1087
1088-- critical few with even bottom digit...
1089dqadd37540 fma  1  '9876543219876543216543210123456788' 0.499999999   -> '9876543219876543216543210123456788' Inexact Rounded
1090dqadd37541 fma  1  '9876543219876543216543210123456788' 0.5           -> '9876543219876543216543210123456788' Inexact Rounded
1091dqadd37542 fma  1  '9876543219876543216543210123456788' 0.500000001   -> '9876543219876543216543210123456789' Inexact Rounded
1092
1093rounding: down
1094dqadd37550 fma  1  '9876543219876543216543210123456789' 0             -> '9876543219876543216543210123456789'
1095dqadd37551 fma  1  '9876543219876543216543210123456789' 0.000000001   -> '9876543219876543216543210123456789' Inexact Rounded
1096dqadd37552 fma  1  '9876543219876543216543210123456789' 0.000001      -> '9876543219876543216543210123456789' Inexact Rounded
1097dqadd37553 fma  1  '9876543219876543216543210123456789' 0.1           -> '9876543219876543216543210123456789' Inexact Rounded
1098dqadd37554 fma  1  '9876543219876543216543210123456789' 0.4           -> '9876543219876543216543210123456789' Inexact Rounded
1099dqadd37555 fma  1  '9876543219876543216543210123456789' 0.49          -> '9876543219876543216543210123456789' Inexact Rounded
1100dqadd37556 fma  1  '9876543219876543216543210123456789' 0.499999      -> '9876543219876543216543210123456789' Inexact Rounded
1101dqadd37557 fma  1  '9876543219876543216543210123456789' 0.499999999   -> '9876543219876543216543210123456789' Inexact Rounded
1102dqadd37558 fma  1  '9876543219876543216543210123456789' 0.5           -> '9876543219876543216543210123456789' Inexact Rounded
1103dqadd37559 fma  1  '9876543219876543216543210123456789' 0.500000001   -> '9876543219876543216543210123456789' Inexact Rounded
1104dqadd37560 fma  1  '9876543219876543216543210123456789' 0.500001      -> '9876543219876543216543210123456789' Inexact Rounded
1105dqadd37561 fma  1  '9876543219876543216543210123456789' 0.51          -> '9876543219876543216543210123456789' Inexact Rounded
1106dqadd37562 fma  1  '9876543219876543216543210123456789' 0.6           -> '9876543219876543216543210123456789' Inexact Rounded
1107dqadd37563 fma  1  '9876543219876543216543210123456789' 0.9           -> '9876543219876543216543210123456789' Inexact Rounded
1108dqadd37564 fma  1  '9876543219876543216543210123456789' 0.99999       -> '9876543219876543216543210123456789' Inexact Rounded
1109dqadd37565 fma  1  '9876543219876543216543210123456789' 0.999999999   -> '9876543219876543216543210123456789' Inexact Rounded
1110dqadd37566 fma  1  '9876543219876543216543210123456789' 1             -> '9876543219876543216543210123456790'
1111dqadd37567 fma  1  '9876543219876543216543210123456789' 1.00000001    -> '9876543219876543216543210123456790' Inexact Rounded
1112dqadd37568 fma  1  '9876543219876543216543210123456789' 1.00001       -> '9876543219876543216543210123456790' Inexact Rounded
1113dqadd37569 fma  1  '9876543219876543216543210123456789' 1.1           -> '9876543219876543216543210123456790' Inexact Rounded
1114
1115-- more zeros, etc.
1116rounding: half_even
1117
1118dqadd37701 fma  1  5.00 1.00E-3 -> 5.00100
1119dqadd37702 fma  1  00.00 0.000  -> 0.000
1120dqadd37703 fma  1  00.00 0E-3   -> 0.000
1121dqadd37704 fma  1  0E-3  00.00  -> 0.000
1122
1123dqadd37710 fma  1  0E+3  00.00  -> 0.00
1124dqadd37711 fma  1  0E+3  00.0   -> 0.0
1125dqadd37712 fma  1  0E+3  00.    -> 0
1126dqadd37713 fma  1  0E+3  00.E+1 -> 0E+1
1127dqadd37714 fma  1  0E+3  00.E+2 -> 0E+2
1128dqadd37715 fma  1  0E+3  00.E+3 -> 0E+3
1129dqadd37716 fma  1  0E+3  00.E+4 -> 0E+3
1130dqadd37717 fma  1  0E+3  00.E+5 -> 0E+3
1131dqadd37718 fma  1  0E+3  -00.0   -> 0.0
1132dqadd37719 fma  1  0E+3  -00.    -> 0
1133dqadd37731 fma  1  0E+3  -00.E+1 -> 0E+1
1134
1135dqadd37720 fma  1  00.00  0E+3  -> 0.00
1136dqadd37721 fma  1  00.0   0E+3  -> 0.0
1137dqadd37722 fma  1  00.    0E+3  -> 0
1138dqadd37723 fma  1  00.E+1 0E+3  -> 0E+1
1139dqadd37724 fma  1  00.E+2 0E+3  -> 0E+2
1140dqadd37725 fma  1  00.E+3 0E+3  -> 0E+3
1141dqadd37726 fma  1  00.E+4 0E+3  -> 0E+3
1142dqadd37727 fma  1  00.E+5 0E+3  -> 0E+3
1143dqadd37728 fma  1  -00.00 0E+3  -> 0.00
1144dqadd37729 fma  1  -00.0  0E+3  -> 0.0
1145dqadd37730 fma  1  -00.   0E+3  -> 0
1146
1147dqadd37732 fma  1   0     0     ->  0
1148dqadd37733 fma  1   0    -0     ->  0
1149dqadd37734 fma  1  -0     0     ->  0
1150dqadd37735 fma  1  -0    -0     -> -0     -- IEEE 854 special case
1151
1152dqadd37736 fma  1   1    -1     ->  0
1153dqadd37737 fma  1  -1    -1     -> -2
1154dqadd37738 fma  1   1     1     ->  2
1155dqadd37739 fma  1  -1     1     ->  0
1156
1157dqadd37741 fma  1   0    -1     -> -1
1158dqadd37742 fma  1  -0    -1     -> -1
1159dqadd37743 fma  1   0     1     ->  1
1160dqadd37744 fma  1  -0     1     ->  1
1161dqadd37745 fma  1  -1     0     -> -1
1162dqadd37746 fma  1  -1    -0     -> -1
1163dqadd37747 fma  1   1     0     ->  1
1164dqadd37748 fma  1   1    -0     ->  1
1165
1166dqadd37751 fma  1   0.0  -1     -> -1.0
1167dqadd37752 fma  1  -0.0  -1     -> -1.0
1168dqadd37753 fma  1   0.0   1     ->  1.0
1169dqadd37754 fma  1  -0.0   1     ->  1.0
1170dqadd37755 fma  1  -1.0   0     -> -1.0
1171dqadd37756 fma  1  -1.0  -0     -> -1.0
1172dqadd37757 fma  1   1.0   0     ->  1.0
1173dqadd37758 fma  1   1.0  -0     ->  1.0
1174
1175dqadd37761 fma  1   0    -1.0   -> -1.0
1176dqadd37762 fma  1  -0    -1.0   -> -1.0
1177dqadd37763 fma  1   0     1.0   ->  1.0
1178dqadd37764 fma  1  -0     1.0   ->  1.0
1179dqadd37765 fma  1  -1     0.0   -> -1.0
1180dqadd37766 fma  1  -1    -0.0   -> -1.0
1181dqadd37767 fma  1   1     0.0   ->  1.0
1182dqadd37768 fma  1   1    -0.0   ->  1.0
1183
1184dqadd37771 fma  1   0.0  -1.0   -> -1.0
1185dqadd37772 fma  1  -0.0  -1.0   -> -1.0
1186dqadd37773 fma  1   0.0   1.0   ->  1.0
1187dqadd37774 fma  1  -0.0   1.0   ->  1.0
1188dqadd37775 fma  1  -1.0   0.0   -> -1.0
1189dqadd37776 fma  1  -1.0  -0.0   -> -1.0
1190dqadd37777 fma  1   1.0   0.0   ->  1.0
1191dqadd37778 fma  1   1.0  -0.0   ->  1.0
1192
1193-- Specials
1194dqadd37780 fma  1  -Inf  -Inf   -> -Infinity
1195dqadd37781 fma  1  -Inf  -1000  -> -Infinity
1196dqadd37782 fma  1  -Inf  -1     -> -Infinity
1197dqadd37783 fma  1  -Inf  -0     -> -Infinity
1198dqadd37784 fma  1  -Inf   0     -> -Infinity
1199dqadd37785 fma  1  -Inf   1     -> -Infinity
1200dqadd37786 fma  1  -Inf   1000  -> -Infinity
1201dqadd37787 fma  1  -1000 -Inf   -> -Infinity
1202dqadd37788 fma  1  -Inf  -Inf   -> -Infinity
1203dqadd37789 fma  1  -1    -Inf   -> -Infinity
1204dqadd37790 fma  1  -0    -Inf   -> -Infinity
1205dqadd37791 fma  1   0    -Inf   -> -Infinity
1206dqadd37792 fma  1   1    -Inf   -> -Infinity
1207dqadd37793 fma  1   1000 -Inf   -> -Infinity
1208dqadd37794 fma  1   Inf  -Inf   ->  NaN  Invalid_operation
1209
1210dqadd37800 fma  1   Inf  -Inf   ->  NaN  Invalid_operation
1211dqadd37801 fma  1   Inf  -1000  ->  Infinity
1212dqadd37802 fma  1   Inf  -1     ->  Infinity
1213dqadd37803 fma  1   Inf  -0     ->  Infinity
1214dqadd37804 fma  1   Inf   0     ->  Infinity
1215dqadd37805 fma  1   Inf   1     ->  Infinity
1216dqadd37806 fma  1   Inf   1000  ->  Infinity
1217dqadd37807 fma  1   Inf   Inf   ->  Infinity
1218dqadd37808 fma  1  -1000  Inf   ->  Infinity
1219dqadd37809 fma  1  -Inf   Inf   ->  NaN  Invalid_operation
1220dqadd37810 fma  1  -1     Inf   ->  Infinity
1221dqadd37811 fma  1  -0     Inf   ->  Infinity
1222dqadd37812 fma  1   0     Inf   ->  Infinity
1223dqadd37813 fma  1   1     Inf   ->  Infinity
1224dqadd37814 fma  1   1000  Inf   ->  Infinity
1225dqadd37815 fma  1   Inf   Inf   ->  Infinity
1226
1227dqadd37821 fma  1   NaN -Inf    ->  NaN
1228dqadd37822 fma  1   NaN -1000   ->  NaN
1229dqadd37823 fma  1   NaN -1      ->  NaN
1230dqadd37824 fma  1   NaN -0      ->  NaN
1231dqadd37825 fma  1   NaN  0      ->  NaN
1232dqadd37826 fma  1   NaN  1      ->  NaN
1233dqadd37827 fma  1   NaN  1000   ->  NaN
1234dqadd37828 fma  1   NaN  Inf    ->  NaN
1235dqadd37829 fma  1   NaN  NaN    ->  NaN
1236dqadd37830 fma  1  -Inf  NaN    ->  NaN
1237dqadd37831 fma  1  -1000 NaN    ->  NaN
1238dqadd37832 fma  1  -1    NaN    ->  NaN
1239dqadd37833 fma  1  -0    NaN    ->  NaN
1240dqadd37834 fma  1   0    NaN    ->  NaN
1241dqadd37835 fma  1   1    NaN    ->  NaN
1242dqadd37836 fma  1   1000 NaN    ->  NaN
1243dqadd37837 fma  1   Inf  NaN    ->  NaN
1244
1245dqadd37841 fma  1   sNaN -Inf   ->  NaN  Invalid_operation
1246dqadd37842 fma  1   sNaN -1000  ->  NaN  Invalid_operation
1247dqadd37843 fma  1   sNaN -1     ->  NaN  Invalid_operation
1248dqadd37844 fma  1   sNaN -0     ->  NaN  Invalid_operation
1249dqadd37845 fma  1   sNaN  0     ->  NaN  Invalid_operation
1250dqadd37846 fma  1   sNaN  1     ->  NaN  Invalid_operation
1251dqadd37847 fma  1   sNaN  1000  ->  NaN  Invalid_operation
1252dqadd37848 fma  1   sNaN  NaN   ->  NaN  Invalid_operation
1253dqadd37849 fma  1   sNaN sNaN   ->  NaN  Invalid_operation
1254dqadd37850 fma  1   NaN  sNaN   ->  NaN  Invalid_operation
1255dqadd37851 fma  1  -Inf  sNaN   ->  NaN  Invalid_operation
1256dqadd37852 fma  1  -1000 sNaN   ->  NaN  Invalid_operation
1257dqadd37853 fma  1  -1    sNaN   ->  NaN  Invalid_operation
1258dqadd37854 fma  1  -0    sNaN   ->  NaN  Invalid_operation
1259dqadd37855 fma  1   0    sNaN   ->  NaN  Invalid_operation
1260dqadd37856 fma  1   1    sNaN   ->  NaN  Invalid_operation
1261dqadd37857 fma  1   1000 sNaN   ->  NaN  Invalid_operation
1262dqadd37858 fma  1   Inf  sNaN   ->  NaN  Invalid_operation
1263dqadd37859 fma  1   NaN  sNaN   ->  NaN  Invalid_operation
1264
1265-- propagating NaNs
1266dqadd37861 fma  1   NaN1   -Inf    ->  NaN1
1267dqadd37862 fma  1  +NaN2   -1000   ->  NaN2
1268dqadd37863 fma  1   NaN3    1000   ->  NaN3
1269dqadd37864 fma  1   NaN4    Inf    ->  NaN4
1270dqadd37865 fma  1   NaN5   +NaN6   ->  NaN5
1271dqadd37866 fma  1  -Inf     NaN7   ->  NaN7
1272dqadd37867 fma  1  -1000    NaN8   ->  NaN8
1273dqadd37868 fma  1   1000    NaN9   ->  NaN9
1274dqadd37869 fma  1   Inf    +NaN10  ->  NaN10
1275dqadd37871 fma  1   sNaN11  -Inf   ->  NaN11  Invalid_operation
1276dqadd37872 fma  1   sNaN12  -1000  ->  NaN12  Invalid_operation
1277dqadd37873 fma  1   sNaN13   1000  ->  NaN13  Invalid_operation
1278dqadd37874 fma  1   sNaN14   NaN17 ->  NaN14  Invalid_operation
1279dqadd37875 fma  1   sNaN15  sNaN18 ->  NaN15  Invalid_operation
1280dqadd37876 fma  1   NaN16   sNaN19 ->  NaN19  Invalid_operation
1281dqadd37877 fma  1  -Inf    +sNaN20 ->  NaN20  Invalid_operation
1282dqadd37878 fma  1  -1000    sNaN21 ->  NaN21  Invalid_operation
1283dqadd37879 fma  1   1000    sNaN22 ->  NaN22  Invalid_operation
1284dqadd37880 fma  1   Inf     sNaN23 ->  NaN23  Invalid_operation
1285dqadd37881 fma  1  +NaN25  +sNaN24 ->  NaN24  Invalid_operation
1286dqadd37882 fma  1  -NaN26    NaN28 -> -NaN26
1287dqadd37883 fma  1  -sNaN27  sNaN29 -> -NaN27  Invalid_operation
1288dqadd37884 fma  1   1000    -NaN30 -> -NaN30
1289dqadd37885 fma  1   1000   -sNaN31 -> -NaN31  Invalid_operation
1290
1291-- Here we explore near the boundary of rounding a subnormal to Nmin
1292dqadd37575 fma  1   1E-6143 -1E-6176 ->  9.99999999999999999999999999999999E-6144 Subnormal
1293dqadd37576 fma  1  -1E-6143 +1E-6176 -> -9.99999999999999999999999999999999E-6144 Subnormal
1294
1295-- check overflow edge case
1296--               1234567890123456
1297dqadd37972 apply       9.999999999999999999999999999999999E+6144         -> 9.999999999999999999999999999999999E+6144
1298dqadd37973 fma  1      9.999999999999999999999999999999999E+6144  1      -> 9.999999999999999999999999999999999E+6144 Inexact Rounded
1299dqadd37974 fma  1       9999999999999999999999999999999999E+6111  1      -> 9.999999999999999999999999999999999E+6144 Inexact Rounded
1300dqadd37975 fma  1       9999999999999999999999999999999999E+6111  1E+6111  -> Infinity Overflow Inexact Rounded
1301dqadd37976 fma  1       9999999999999999999999999999999999E+6111  9E+6110  -> Infinity Overflow Inexact Rounded
1302dqadd37977 fma  1       9999999999999999999999999999999999E+6111  8E+6110  -> Infinity Overflow Inexact Rounded
1303dqadd37978 fma  1       9999999999999999999999999999999999E+6111  7E+6110  -> Infinity Overflow Inexact Rounded
1304dqadd37979 fma  1       9999999999999999999999999999999999E+6111  6E+6110  -> Infinity Overflow Inexact Rounded
1305dqadd37980 fma  1       9999999999999999999999999999999999E+6111  5E+6110  -> Infinity Overflow Inexact Rounded
1306dqadd37981 fma  1       9999999999999999999999999999999999E+6111  4E+6110  -> 9.999999999999999999999999999999999E+6144 Inexact Rounded
1307dqadd37982 fma  1       9999999999999999999999999999999999E+6111  3E+6110  -> 9.999999999999999999999999999999999E+6144 Inexact Rounded
1308dqadd37983 fma  1       9999999999999999999999999999999999E+6111  2E+6110  -> 9.999999999999999999999999999999999E+6144 Inexact Rounded
1309dqadd37984 fma  1       9999999999999999999999999999999999E+6111  1E+6110  -> 9.999999999999999999999999999999999E+6144 Inexact Rounded
1310
1311dqadd37985 apply      -9.999999999999999999999999999999999E+6144         -> -9.999999999999999999999999999999999E+6144
1312dqadd37986 fma  1     -9.999999999999999999999999999999999E+6144 -1      -> -9.999999999999999999999999999999999E+6144 Inexact Rounded
1313dqadd37987 fma  1      -9999999999999999999999999999999999E+6111 -1      -> -9.999999999999999999999999999999999E+6144 Inexact Rounded
1314dqadd37988 fma  1      -9999999999999999999999999999999999E+6111 -1E+6111  -> -Infinity Overflow Inexact Rounded
1315dqadd37989 fma  1      -9999999999999999999999999999999999E+6111 -9E+6110  -> -Infinity Overflow Inexact Rounded
1316dqadd37990 fma  1      -9999999999999999999999999999999999E+6111 -8E+6110  -> -Infinity Overflow Inexact Rounded
1317dqadd37991 fma  1      -9999999999999999999999999999999999E+6111 -7E+6110  -> -Infinity Overflow Inexact Rounded
1318dqadd37992 fma  1      -9999999999999999999999999999999999E+6111 -6E+6110  -> -Infinity Overflow Inexact Rounded
1319dqadd37993 fma  1      -9999999999999999999999999999999999E+6111 -5E+6110  -> -Infinity Overflow Inexact Rounded
1320dqadd37994 fma  1      -9999999999999999999999999999999999E+6111 -4E+6110  -> -9.999999999999999999999999999999999E+6144 Inexact Rounded
1321dqadd37995 fma  1      -9999999999999999999999999999999999E+6111 -3E+6110  -> -9.999999999999999999999999999999999E+6144 Inexact Rounded
1322dqadd37996 fma  1      -9999999999999999999999999999999999E+6111 -2E+6110  -> -9.999999999999999999999999999999999E+6144 Inexact Rounded
1323dqadd37997 fma  1      -9999999999999999999999999999999999E+6111 -1E+6110  -> -9.999999999999999999999999999999999E+6144 Inexact Rounded
1324
1325-- And for round down full and subnormal results
1326rounding:     down
1327dqadd371100 fma  1  1e+2 -1e-6143    -> 99.99999999999999999999999999999999 Rounded Inexact
1328dqadd371101 fma  1  1e+1 -1e-6143    -> 9.999999999999999999999999999999999  Rounded Inexact
1329dqadd371103 fma  1    +1 -1e-6143    -> 0.9999999999999999999999999999999999  Rounded Inexact
1330dqadd371104 fma  1  1e-1 -1e-6143    -> 0.09999999999999999999999999999999999  Rounded Inexact
1331dqadd371105 fma  1  1e-2 -1e-6143    -> 0.009999999999999999999999999999999999  Rounded Inexact
1332dqadd371106 fma  1  1e-3 -1e-6143    -> 0.0009999999999999999999999999999999999  Rounded Inexact
1333dqadd371107 fma  1  1e-4 -1e-6143    -> 0.00009999999999999999999999999999999999  Rounded Inexact
1334dqadd371108 fma  1  1e-5 -1e-6143    -> 0.000009999999999999999999999999999999999  Rounded Inexact
1335dqadd371109 fma  1  1e-6 -1e-6143    -> 9.999999999999999999999999999999999E-7  Rounded Inexact
1336
1337rounding:     ceiling
1338dqadd371110 fma  1  -1e+2 +1e-6143   -> -99.99999999999999999999999999999999 Rounded Inexact
1339dqadd371111 fma  1  -1e+1 +1e-6143   -> -9.999999999999999999999999999999999  Rounded Inexact
1340dqadd371113 fma  1     -1 +1e-6143   -> -0.9999999999999999999999999999999999  Rounded Inexact
1341dqadd371114 fma  1  -1e-1 +1e-6143   -> -0.09999999999999999999999999999999999  Rounded Inexact
1342dqadd371115 fma  1  -1e-2 +1e-6143   -> -0.009999999999999999999999999999999999  Rounded Inexact
1343dqadd371116 fma  1  -1e-3 +1e-6143   -> -0.0009999999999999999999999999999999999  Rounded Inexact
1344dqadd371117 fma  1  -1e-4 +1e-6143   -> -0.00009999999999999999999999999999999999  Rounded Inexact
1345dqadd371118 fma  1  -1e-5 +1e-6143   -> -0.000009999999999999999999999999999999999  Rounded Inexact
1346dqadd371119 fma  1  -1e-6 +1e-6143   -> -9.999999999999999999999999999999999E-7  Rounded Inexact
1347
1348-- tests based on Gunnar Degnbol's edge case
1349rounding:     half_even
1350
1351dqadd371300 fma  1  1E34  -0.5                 ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1352dqadd371310 fma  1  1E34  -0.51                ->  9999999999999999999999999999999999      Inexact Rounded
1353dqadd371311 fma  1  1E34  -0.501               ->  9999999999999999999999999999999999      Inexact Rounded
1354dqadd371312 fma  1  1E34  -0.5001              ->  9999999999999999999999999999999999      Inexact Rounded
1355dqadd371313 fma  1  1E34  -0.50001             ->  9999999999999999999999999999999999      Inexact Rounded
1356dqadd371314 fma  1  1E34  -0.500001            ->  9999999999999999999999999999999999      Inexact Rounded
1357dqadd371315 fma  1  1E34  -0.5000001           ->  9999999999999999999999999999999999      Inexact Rounded
1358dqadd371316 fma  1  1E34  -0.50000001          ->  9999999999999999999999999999999999      Inexact Rounded
1359dqadd371317 fma  1  1E34  -0.500000001         ->  9999999999999999999999999999999999      Inexact Rounded
1360dqadd371318 fma  1  1E34  -0.5000000001        ->  9999999999999999999999999999999999      Inexact Rounded
1361dqadd371319 fma  1  1E34  -0.50000000001       ->  9999999999999999999999999999999999      Inexact Rounded
1362dqadd371320 fma  1  1E34  -0.500000000001      ->  9999999999999999999999999999999999      Inexact Rounded
1363dqadd371321 fma  1  1E34  -0.5000000000001     ->  9999999999999999999999999999999999      Inexact Rounded
1364dqadd371322 fma  1  1E34  -0.50000000000001    ->  9999999999999999999999999999999999      Inexact Rounded
1365dqadd371323 fma  1  1E34  -0.500000000000001   ->  9999999999999999999999999999999999      Inexact Rounded
1366dqadd371324 fma  1  1E34  -0.5000000000000001  ->  9999999999999999999999999999999999      Inexact Rounded
1367dqadd371325 fma  1  1E34  -0.5000000000000000  ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1368dqadd371326 fma  1  1E34  -0.500000000000000   ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1369dqadd371327 fma  1  1E34  -0.50000000000000    ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1370dqadd371328 fma  1  1E34  -0.5000000000000     ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1371dqadd371329 fma  1  1E34  -0.500000000000      ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1372dqadd371330 fma  1  1E34  -0.50000000000       ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1373dqadd371331 fma  1  1E34  -0.5000000000        ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1374dqadd371332 fma  1  1E34  -0.500000000         ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1375dqadd371333 fma  1  1E34  -0.50000000          ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1376dqadd371334 fma  1  1E34  -0.5000000           ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1377dqadd371335 fma  1  1E34  -0.500000            ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1378dqadd371336 fma  1  1E34  -0.50000             ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1379dqadd371337 fma  1  1E34  -0.5000              ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1380dqadd371338 fma  1  1E34  -0.500               ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1381dqadd371339 fma  1  1E34  -0.50                ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1382
1383dqadd371340 fma  1  1E34  -5000000.000010001   ->  9999999999999999999999999995000000      Inexact Rounded
1384dqadd371341 fma  1  1E34  -5000000.000000001   ->  9999999999999999999999999995000000      Inexact Rounded
1385
1386dqadd371349 fma  1  9999999999999999999999999999999999 0.4                 ->  9999999999999999999999999999999999      Inexact Rounded
1387dqadd371350 fma  1  9999999999999999999999999999999999 0.49                ->  9999999999999999999999999999999999      Inexact Rounded
1388dqadd371351 fma  1  9999999999999999999999999999999999 0.499               ->  9999999999999999999999999999999999      Inexact Rounded
1389dqadd371352 fma  1  9999999999999999999999999999999999 0.4999              ->  9999999999999999999999999999999999      Inexact Rounded
1390dqadd371353 fma  1  9999999999999999999999999999999999 0.49999             ->  9999999999999999999999999999999999      Inexact Rounded
1391dqadd371354 fma  1  9999999999999999999999999999999999 0.499999            ->  9999999999999999999999999999999999      Inexact Rounded
1392dqadd371355 fma  1  9999999999999999999999999999999999 0.4999999           ->  9999999999999999999999999999999999      Inexact Rounded
1393dqadd371356 fma  1  9999999999999999999999999999999999 0.49999999          ->  9999999999999999999999999999999999      Inexact Rounded
1394dqadd371357 fma  1  9999999999999999999999999999999999 0.499999999         ->  9999999999999999999999999999999999      Inexact Rounded
1395dqadd371358 fma  1  9999999999999999999999999999999999 0.4999999999        ->  9999999999999999999999999999999999      Inexact Rounded
1396dqadd371359 fma  1  9999999999999999999999999999999999 0.49999999999       ->  9999999999999999999999999999999999      Inexact Rounded
1397dqadd371360 fma  1  9999999999999999999999999999999999 0.499999999999      ->  9999999999999999999999999999999999      Inexact Rounded
1398dqadd371361 fma  1  9999999999999999999999999999999999 0.4999999999999     ->  9999999999999999999999999999999999      Inexact Rounded
1399dqadd371362 fma  1  9999999999999999999999999999999999 0.49999999999999    ->  9999999999999999999999999999999999      Inexact Rounded
1400dqadd371363 fma  1  9999999999999999999999999999999999 0.499999999999999   ->  9999999999999999999999999999999999      Inexact Rounded
1401dqadd371364 fma  1  9999999999999999999999999999999999 0.4999999999999999  ->  9999999999999999999999999999999999      Inexact Rounded
1402dqadd371365 fma  1  9999999999999999999999999999999999 0.5000000000000000  ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1403dqadd371367 fma  1  9999999999999999999999999999999999 0.500000000000000   ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1404dqadd371368 fma  1  9999999999999999999999999999999999 0.50000000000000    ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1405dqadd371369 fma  1  9999999999999999999999999999999999 0.5000000000000     ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1406dqadd371370 fma  1  9999999999999999999999999999999999 0.500000000000      ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1407dqadd371371 fma  1  9999999999999999999999999999999999 0.50000000000       ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1408dqadd371372 fma  1  9999999999999999999999999999999999 0.5000000000        ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1409dqadd371373 fma  1  9999999999999999999999999999999999 0.500000000         ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1410dqadd371374 fma  1  9999999999999999999999999999999999 0.50000000          ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1411dqadd371375 fma  1  9999999999999999999999999999999999 0.5000000           ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1412dqadd371376 fma  1  9999999999999999999999999999999999 0.500000            ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1413dqadd371377 fma  1  9999999999999999999999999999999999 0.50000             ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1414dqadd371378 fma  1  9999999999999999999999999999999999 0.5000              ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1415dqadd371379 fma  1  9999999999999999999999999999999999 0.500               ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1416dqadd371380 fma  1  9999999999999999999999999999999999 0.50                ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1417dqadd371381 fma  1  9999999999999999999999999999999999 0.5                 ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1418dqadd371382 fma  1  9999999999999999999999999999999999 0.5000000000000001  ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1419dqadd371383 fma  1  9999999999999999999999999999999999 0.500000000000001   ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1420dqadd371384 fma  1  9999999999999999999999999999999999 0.50000000000001    ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1421dqadd371385 fma  1  9999999999999999999999999999999999 0.5000000000001     ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1422dqadd371386 fma  1  9999999999999999999999999999999999 0.500000000001      ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1423dqadd371387 fma  1  9999999999999999999999999999999999 0.50000000001       ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1424dqadd371388 fma  1  9999999999999999999999999999999999 0.5000000001        ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1425dqadd371389 fma  1  9999999999999999999999999999999999 0.500000001         ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1426dqadd371390 fma  1  9999999999999999999999999999999999 0.50000001          ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1427dqadd371391 fma  1  9999999999999999999999999999999999 0.5000001           ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1428dqadd371392 fma  1  9999999999999999999999999999999999 0.500001            ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1429dqadd371393 fma  1  9999999999999999999999999999999999 0.50001             ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1430dqadd371394 fma  1  9999999999999999999999999999999999 0.5001              ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1431dqadd371395 fma  1  9999999999999999999999999999999999 0.501               ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1432dqadd371396 fma  1  9999999999999999999999999999999999 0.51                ->  1.000000000000000000000000000000000E+34 Inexact Rounded
1433
1434-- More GD edge cases, where difference between the unadjusted
1435-- exponents is larger than the maximum precision and one side is 0
1436dqadd371420 fma  1   0 1.123456789987654321123456789012345     -> 1.123456789987654321123456789012345
1437dqadd371421 fma  1   0 1.123456789987654321123456789012345E-1  -> 0.1123456789987654321123456789012345
1438dqadd371422 fma  1   0 1.123456789987654321123456789012345E-2  -> 0.01123456789987654321123456789012345
1439dqadd371423 fma  1   0 1.123456789987654321123456789012345E-3  -> 0.001123456789987654321123456789012345
1440dqadd371424 fma  1   0 1.123456789987654321123456789012345E-4  -> 0.0001123456789987654321123456789012345
1441dqadd371425 fma  1   0 1.123456789987654321123456789012345E-5  -> 0.00001123456789987654321123456789012345
1442dqadd371426 fma  1   0 1.123456789987654321123456789012345E-6  -> 0.000001123456789987654321123456789012345
1443dqadd371427 fma  1   0 1.123456789987654321123456789012345E-7  -> 1.123456789987654321123456789012345E-7
1444dqadd371428 fma  1   0 1.123456789987654321123456789012345E-8  -> 1.123456789987654321123456789012345E-8
1445dqadd371429 fma  1   0 1.123456789987654321123456789012345E-9  -> 1.123456789987654321123456789012345E-9
1446dqadd371430 fma  1   0 1.123456789987654321123456789012345E-10 -> 1.123456789987654321123456789012345E-10
1447dqadd371431 fma  1   0 1.123456789987654321123456789012345E-11 -> 1.123456789987654321123456789012345E-11
1448dqadd371432 fma  1   0 1.123456789987654321123456789012345E-12 -> 1.123456789987654321123456789012345E-12
1449dqadd371433 fma  1   0 1.123456789987654321123456789012345E-13 -> 1.123456789987654321123456789012345E-13
1450dqadd371434 fma  1   0 1.123456789987654321123456789012345E-14 -> 1.123456789987654321123456789012345E-14
1451dqadd371435 fma  1   0 1.123456789987654321123456789012345E-15 -> 1.123456789987654321123456789012345E-15
1452dqadd371436 fma  1   0 1.123456789987654321123456789012345E-16 -> 1.123456789987654321123456789012345E-16
1453dqadd371437 fma  1   0 1.123456789987654321123456789012345E-17 -> 1.123456789987654321123456789012345E-17
1454dqadd371438 fma  1   0 1.123456789987654321123456789012345E-18 -> 1.123456789987654321123456789012345E-18
1455dqadd371439 fma  1   0 1.123456789987654321123456789012345E-19 -> 1.123456789987654321123456789012345E-19
1456dqadd371440 fma  1   0 1.123456789987654321123456789012345E-20 -> 1.123456789987654321123456789012345E-20
1457dqadd371441 fma  1   0 1.123456789987654321123456789012345E-21 -> 1.123456789987654321123456789012345E-21
1458dqadd371442 fma  1   0 1.123456789987654321123456789012345E-22 -> 1.123456789987654321123456789012345E-22
1459dqadd371443 fma  1   0 1.123456789987654321123456789012345E-23 -> 1.123456789987654321123456789012345E-23
1460dqadd371444 fma  1   0 1.123456789987654321123456789012345E-24 -> 1.123456789987654321123456789012345E-24
1461dqadd371445 fma  1   0 1.123456789987654321123456789012345E-25 -> 1.123456789987654321123456789012345E-25
1462dqadd371446 fma  1   0 1.123456789987654321123456789012345E-26 -> 1.123456789987654321123456789012345E-26
1463dqadd371447 fma  1   0 1.123456789987654321123456789012345E-27 -> 1.123456789987654321123456789012345E-27
1464dqadd371448 fma  1   0 1.123456789987654321123456789012345E-28 -> 1.123456789987654321123456789012345E-28
1465dqadd371449 fma  1   0 1.123456789987654321123456789012345E-29 -> 1.123456789987654321123456789012345E-29
1466dqadd371450 fma  1   0 1.123456789987654321123456789012345E-30 -> 1.123456789987654321123456789012345E-30
1467dqadd371451 fma  1   0 1.123456789987654321123456789012345E-31 -> 1.123456789987654321123456789012345E-31
1468dqadd371452 fma  1   0 1.123456789987654321123456789012345E-32 -> 1.123456789987654321123456789012345E-32
1469dqadd371453 fma  1   0 1.123456789987654321123456789012345E-33 -> 1.123456789987654321123456789012345E-33
1470dqadd371454 fma  1   0 1.123456789987654321123456789012345E-34 -> 1.123456789987654321123456789012345E-34
1471dqadd371455 fma  1   0 1.123456789987654321123456789012345E-35 -> 1.123456789987654321123456789012345E-35
1472dqadd371456 fma  1   0 1.123456789987654321123456789012345E-36 -> 1.123456789987654321123456789012345E-36
1473
1474-- same, reversed 0
1475dqadd371460 fma  1  1.123456789987654321123456789012345     0 -> 1.123456789987654321123456789012345
1476dqadd371461 fma  1  1.123456789987654321123456789012345E-1  0 -> 0.1123456789987654321123456789012345
1477dqadd371462 fma  1  1.123456789987654321123456789012345E-2  0 -> 0.01123456789987654321123456789012345
1478dqadd371463 fma  1  1.123456789987654321123456789012345E-3  0 -> 0.001123456789987654321123456789012345
1479dqadd371464 fma  1  1.123456789987654321123456789012345E-4  0 -> 0.0001123456789987654321123456789012345
1480dqadd371465 fma  1  1.123456789987654321123456789012345E-5  0 -> 0.00001123456789987654321123456789012345
1481dqadd371466 fma  1  1.123456789987654321123456789012345E-6  0 -> 0.000001123456789987654321123456789012345
1482dqadd371467 fma  1  1.123456789987654321123456789012345E-7  0 -> 1.123456789987654321123456789012345E-7
1483dqadd371468 fma  1  1.123456789987654321123456789012345E-8  0 -> 1.123456789987654321123456789012345E-8
1484dqadd371469 fma  1  1.123456789987654321123456789012345E-9  0 -> 1.123456789987654321123456789012345E-9
1485dqadd371470 fma  1  1.123456789987654321123456789012345E-10 0 -> 1.123456789987654321123456789012345E-10
1486dqadd371471 fma  1  1.123456789987654321123456789012345E-11 0 -> 1.123456789987654321123456789012345E-11
1487dqadd371472 fma  1  1.123456789987654321123456789012345E-12 0 -> 1.123456789987654321123456789012345E-12
1488dqadd371473 fma  1  1.123456789987654321123456789012345E-13 0 -> 1.123456789987654321123456789012345E-13
1489dqadd371474 fma  1  1.123456789987654321123456789012345E-14 0 -> 1.123456789987654321123456789012345E-14
1490dqadd371475 fma  1  1.123456789987654321123456789012345E-15 0 -> 1.123456789987654321123456789012345E-15
1491dqadd371476 fma  1  1.123456789987654321123456789012345E-16 0 -> 1.123456789987654321123456789012345E-16
1492dqadd371477 fma  1  1.123456789987654321123456789012345E-17 0 -> 1.123456789987654321123456789012345E-17
1493dqadd371478 fma  1  1.123456789987654321123456789012345E-18 0 -> 1.123456789987654321123456789012345E-18
1494dqadd371479 fma  1  1.123456789987654321123456789012345E-19 0 -> 1.123456789987654321123456789012345E-19
1495dqadd371480 fma  1  1.123456789987654321123456789012345E-20 0 -> 1.123456789987654321123456789012345E-20
1496dqadd371481 fma  1  1.123456789987654321123456789012345E-21 0 -> 1.123456789987654321123456789012345E-21
1497dqadd371482 fma  1  1.123456789987654321123456789012345E-22 0 -> 1.123456789987654321123456789012345E-22
1498dqadd371483 fma  1  1.123456789987654321123456789012345E-23 0 -> 1.123456789987654321123456789012345E-23
1499dqadd371484 fma  1  1.123456789987654321123456789012345E-24 0 -> 1.123456789987654321123456789012345E-24
1500dqadd371485 fma  1  1.123456789987654321123456789012345E-25 0 -> 1.123456789987654321123456789012345E-25
1501dqadd371486 fma  1  1.123456789987654321123456789012345E-26 0 -> 1.123456789987654321123456789012345E-26
1502dqadd371487 fma  1  1.123456789987654321123456789012345E-27 0 -> 1.123456789987654321123456789012345E-27
1503dqadd371488 fma  1  1.123456789987654321123456789012345E-28 0 -> 1.123456789987654321123456789012345E-28
1504dqadd371489 fma  1  1.123456789987654321123456789012345E-29 0 -> 1.123456789987654321123456789012345E-29
1505dqadd371490 fma  1  1.123456789987654321123456789012345E-30 0 -> 1.123456789987654321123456789012345E-30
1506dqadd371491 fma  1  1.123456789987654321123456789012345E-31 0 -> 1.123456789987654321123456789012345E-31
1507dqadd371492 fma  1  1.123456789987654321123456789012345E-32 0 -> 1.123456789987654321123456789012345E-32
1508dqadd371493 fma  1  1.123456789987654321123456789012345E-33 0 -> 1.123456789987654321123456789012345E-33
1509dqadd371494 fma  1  1.123456789987654321123456789012345E-34 0 -> 1.123456789987654321123456789012345E-34
1510dqadd371495 fma  1  1.123456789987654321123456789012345E-35 0 -> 1.123456789987654321123456789012345E-35
1511dqadd371496 fma  1  1.123456789987654321123456789012345E-36 0 -> 1.123456789987654321123456789012345E-36
1512
1513-- same, Es on the 0
1514dqadd371500 fma  1  1.123456789987654321123456789012345  0E-0   -> 1.123456789987654321123456789012345
1515dqadd371501 fma  1  1.123456789987654321123456789012345  0E-1   -> 1.123456789987654321123456789012345
1516dqadd371502 fma  1  1.123456789987654321123456789012345  0E-2   -> 1.123456789987654321123456789012345
1517dqadd371503 fma  1  1.123456789987654321123456789012345  0E-3   -> 1.123456789987654321123456789012345
1518dqadd371504 fma  1  1.123456789987654321123456789012345  0E-4   -> 1.123456789987654321123456789012345
1519dqadd371505 fma  1  1.123456789987654321123456789012345  0E-5   -> 1.123456789987654321123456789012345
1520dqadd371506 fma  1  1.123456789987654321123456789012345  0E-6   -> 1.123456789987654321123456789012345
1521dqadd371507 fma  1  1.123456789987654321123456789012345  0E-7   -> 1.123456789987654321123456789012345
1522dqadd371508 fma  1  1.123456789987654321123456789012345  0E-8   -> 1.123456789987654321123456789012345
1523dqadd371509 fma  1  1.123456789987654321123456789012345  0E-9   -> 1.123456789987654321123456789012345
1524dqadd371510 fma  1  1.123456789987654321123456789012345  0E-10  -> 1.123456789987654321123456789012345
1525dqadd371511 fma  1  1.123456789987654321123456789012345  0E-11  -> 1.123456789987654321123456789012345
1526dqadd371512 fma  1  1.123456789987654321123456789012345  0E-12  -> 1.123456789987654321123456789012345
1527dqadd371513 fma  1  1.123456789987654321123456789012345  0E-13  -> 1.123456789987654321123456789012345
1528dqadd371514 fma  1  1.123456789987654321123456789012345  0E-14  -> 1.123456789987654321123456789012345
1529dqadd371515 fma  1  1.123456789987654321123456789012345  0E-15  -> 1.123456789987654321123456789012345
1530dqadd371516 fma  1  1.123456789987654321123456789012345  0E-16  -> 1.123456789987654321123456789012345
1531dqadd371517 fma  1  1.123456789987654321123456789012345  0E-17  -> 1.123456789987654321123456789012345
1532dqadd371518 fma  1  1.123456789987654321123456789012345  0E-18  -> 1.123456789987654321123456789012345
1533dqadd371519 fma  1  1.123456789987654321123456789012345  0E-19  -> 1.123456789987654321123456789012345
1534dqadd371520 fma  1  1.123456789987654321123456789012345  0E-20  -> 1.123456789987654321123456789012345
1535dqadd371521 fma  1  1.123456789987654321123456789012345  0E-21  -> 1.123456789987654321123456789012345
1536dqadd371522 fma  1  1.123456789987654321123456789012345  0E-22  -> 1.123456789987654321123456789012345
1537dqadd371523 fma  1  1.123456789987654321123456789012345  0E-23  -> 1.123456789987654321123456789012345
1538dqadd371524 fma  1  1.123456789987654321123456789012345  0E-24  -> 1.123456789987654321123456789012345
1539dqadd371525 fma  1  1.123456789987654321123456789012345  0E-25  -> 1.123456789987654321123456789012345
1540dqadd371526 fma  1  1.123456789987654321123456789012345  0E-26  -> 1.123456789987654321123456789012345
1541dqadd371527 fma  1  1.123456789987654321123456789012345  0E-27  -> 1.123456789987654321123456789012345
1542dqadd371528 fma  1  1.123456789987654321123456789012345  0E-28  -> 1.123456789987654321123456789012345
1543dqadd371529 fma  1  1.123456789987654321123456789012345  0E-29  -> 1.123456789987654321123456789012345
1544dqadd371530 fma  1  1.123456789987654321123456789012345  0E-30  -> 1.123456789987654321123456789012345
1545dqadd371531 fma  1  1.123456789987654321123456789012345  0E-31  -> 1.123456789987654321123456789012345
1546dqadd371532 fma  1  1.123456789987654321123456789012345  0E-32  -> 1.123456789987654321123456789012345
1547dqadd371533 fma  1  1.123456789987654321123456789012345  0E-33  -> 1.123456789987654321123456789012345
1548-- next four flag Rounded because the 0 extends the result
1549dqadd371534 fma  1  1.123456789987654321123456789012345  0E-34  -> 1.123456789987654321123456789012345 Rounded
1550dqadd371535 fma  1  1.123456789987654321123456789012345  0E-35  -> 1.123456789987654321123456789012345 Rounded
1551dqadd371536 fma  1  1.123456789987654321123456789012345  0E-36  -> 1.123456789987654321123456789012345 Rounded
1552dqadd371537 fma  1  1.123456789987654321123456789012345  0E-37  -> 1.123456789987654321123456789012345 Rounded
1553
1554-- sum of two opposite-sign operands is exactly 0 and floor => -0
1555rounding:    half_up
1556-- exact zeros from zeros
1557dqadd371600 fma  1   0        0E-19  ->  0E-19
1558dqadd371601 fma  1  -0        0E-19  ->  0E-19
1559dqadd371602 fma  1   0       -0E-19  ->  0E-19
1560dqadd371603 fma  1  -0       -0E-19  -> -0E-19
1561-- exact zeros from non-zeros
1562dqadd371611 fma  1  -11      11    ->  0
1563dqadd371612 fma  1   11     -11    ->  0
1564-- overflow
1565dqadd371613 fma  9E6144 10   1     ->  Infinity Overflow Inexact Rounded
1566dqadd371614 fma -9E6144 10   1     -> -Infinity Overflow Inexact Rounded
1567
1568rounding:    half_down
1569-- exact zeros from zeros
1570dqadd371620 fma  1   0        0E-19  ->  0E-19
1571dqadd371621 fma  1  -0        0E-19  ->  0E-19
1572dqadd371622 fma  1   0       -0E-19  ->  0E-19
1573dqadd371623 fma  1  -0       -0E-19  -> -0E-19
1574-- exact zeros from non-zeros
1575dqadd371631 fma  1  -11      11    ->  0
1576dqadd371632 fma  1   11     -11    ->  0
1577-- overflow
1578dqadd371633 fma  9E6144 10   1     ->  Infinity Overflow Inexact Rounded
1579dqadd371634 fma -9E6144 10   1     -> -Infinity Overflow Inexact Rounded
1580
1581rounding:    half_even
1582-- exact zeros from zeros
1583dqadd371640 fma  1   0        0E-19  ->  0E-19
1584dqadd371641 fma  1  -0        0E-19  ->  0E-19
1585dqadd371642 fma  1   0       -0E-19  ->  0E-19
1586dqadd371643 fma  1  -0       -0E-19  -> -0E-19
1587-- exact zeros from non-zeros
1588dqadd371651 fma  1  -11      11    ->  0
1589dqadd371652 fma  1   11     -11    ->  0
1590-- overflow
1591dqadd371653 fma  9E6144 10   1     ->  Infinity Overflow Inexact Rounded
1592dqadd371654 fma -9E6144 10   1     -> -Infinity Overflow Inexact Rounded
1593
1594rounding:    up
1595-- exact zeros from zeros
1596dqadd371660 fma  1   0        0E-19  ->  0E-19
1597dqadd371661 fma  1  -0        0E-19  ->  0E-19
1598dqadd371662 fma  1   0       -0E-19  ->  0E-19
1599dqadd371663 fma  1  -0       -0E-19  -> -0E-19
1600-- exact zeros from non-zeros
1601dqadd371671 fma  1  -11      11    ->  0
1602dqadd371672 fma  1   11     -11    ->  0
1603-- overflow
1604dqadd371673 fma  9E6144 10   1     ->  Infinity Overflow Inexact Rounded
1605dqadd371674 fma -9E6144 10   1     -> -Infinity Overflow Inexact Rounded
1606
1607rounding:    down
1608-- exact zeros from zeros
1609dqadd371680 fma  1   0        0E-19  ->  0E-19
1610dqadd371681 fma  1  -0        0E-19  ->  0E-19
1611dqadd371682 fma  1   0       -0E-19  ->  0E-19
1612dqadd371683 fma  1  -0       -0E-19  -> -0E-19
1613-- exact zeros from non-zeros
1614dqadd371691 fma  1  -11      11    ->  0
1615dqadd371692 fma  1   11     -11    ->  0
1616-- overflow
1617dqadd371693 fma  9E6144 10   1     ->  9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded
1618dqadd371694 fma -9E6144 10   1     -> -9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded
1619
1620rounding:    ceiling
1621-- exact zeros from zeros
1622dqadd371700 fma  1   0        0E-19  ->  0E-19
1623dqadd371701 fma  1  -0        0E-19  ->  0E-19
1624dqadd371702 fma  1   0       -0E-19  ->  0E-19
1625dqadd371703 fma  1  -0       -0E-19  -> -0E-19
1626-- exact zeros from non-zeros
1627dqadd371711 fma  1  -11      11    ->  0
1628dqadd371712 fma  1   11     -11    ->  0
1629-- overflow
1630dqadd371713 fma  9E6144 10   1     ->  Infinity Overflow Inexact Rounded
1631dqadd371714 fma -9E6144 10   1     -> -9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded
1632
1633-- and the extra-special ugly case; unusual minuses marked by -- *
1634rounding:    floor
1635-- exact zeros from zeros
1636dqadd371720 fma  1   0        0E-19  ->  0E-19
1637dqadd371721 fma  1  -0        0E-19  -> -0E-19           -- *
1638dqadd371722 fma  1   0       -0E-19  -> -0E-19           -- *
1639dqadd371723 fma  1  -0       -0E-19  -> -0E-19
1640-- exact zeros from non-zeros
1641dqadd371731 fma  1  -11      11    ->  -0                -- *
1642dqadd371732 fma  1   11     -11    ->  -0                -- *
1643-- overflow
1644dqadd371733 fma  9E6144 10   1     ->  9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded
1645dqadd371734 fma -9E6144 10   1     -> -Infinity Overflow Inexact Rounded
1646
1647rounding:    05up
1648-- exact zeros from zeros
1649dqadd371740 fma  1   0        0E-19  ->  0E-19
1650dqadd371741 fma  1  -0        0E-19  ->  0E-19
1651dqadd371742 fma  1   0       -0E-19  ->  0E-19
1652dqadd371743 fma  1  -0       -0E-19  -> -0E-19
1653-- exact zeros from non-zeros
1654dqadd371751 fma  1  -11      11    ->  0
1655dqadd371752 fma  1   11     -11    ->  0
1656-- overflow
1657dqadd371753 fma  9E6144 10   1     ->  9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded
1658dqadd371754 fma -9E6144 10   1     -> -9.999999999999999999999999999999999E+6144 Overflow Inexact Rounded
1659
1660-- Examples from SQL proposal (Krishna Kulkarni)
1661dqadd371761 fma  1  130E-2    120E-2    -> 2.50
1662dqadd371762 fma  1  130E-2    12E-1     -> 2.50
1663dqadd371763 fma  1  130E-2    1E0       -> 2.30
1664dqadd371764 fma  1  1E2       1E4       -> 1.01E+4
1665dqadd371765 fma  1  130E-2   -120E-2 -> 0.10
1666dqadd371766 fma  1  130E-2   -12E-1  -> 0.10
1667dqadd371767 fma  1  130E-2   -1E0    -> 0.30
1668dqadd371768 fma  1  1E2      -1E4    -> -9.9E+3
1669
1670-- Gappy coefficients; check residue handling even with full coefficient gap
1671rounding: half_even
1672
1673dqadd375001 fma  1  1239876543211234567894567890123456 1      -> 1239876543211234567894567890123457
1674dqadd375002 fma  1  1239876543211234567894567890123456 0.6    -> 1239876543211234567894567890123457  Inexact Rounded
1675dqadd375003 fma  1  1239876543211234567894567890123456 0.06   -> 1239876543211234567894567890123456  Inexact Rounded
1676dqadd375004 fma  1  1239876543211234567894567890123456 6E-3   -> 1239876543211234567894567890123456  Inexact Rounded
1677dqadd375005 fma  1  1239876543211234567894567890123456 6E-4   -> 1239876543211234567894567890123456  Inexact Rounded
1678dqadd375006 fma  1  1239876543211234567894567890123456 6E-5   -> 1239876543211234567894567890123456  Inexact Rounded
1679dqadd375007 fma  1  1239876543211234567894567890123456 6E-6   -> 1239876543211234567894567890123456  Inexact Rounded
1680dqadd375008 fma  1  1239876543211234567894567890123456 6E-7   -> 1239876543211234567894567890123456  Inexact Rounded
1681dqadd375009 fma  1  1239876543211234567894567890123456 6E-8   -> 1239876543211234567894567890123456  Inexact Rounded
1682dqadd375010 fma  1  1239876543211234567894567890123456 6E-9   -> 1239876543211234567894567890123456  Inexact Rounded
1683dqadd375011 fma  1  1239876543211234567894567890123456 6E-10  -> 1239876543211234567894567890123456  Inexact Rounded
1684dqadd375012 fma  1  1239876543211234567894567890123456 6E-11  -> 1239876543211234567894567890123456  Inexact Rounded
1685dqadd375013 fma  1  1239876543211234567894567890123456 6E-12  -> 1239876543211234567894567890123456  Inexact Rounded
1686dqadd375014 fma  1  1239876543211234567894567890123456 6E-13  -> 1239876543211234567894567890123456  Inexact Rounded
1687dqadd375015 fma  1  1239876543211234567894567890123456 6E-14  -> 1239876543211234567894567890123456  Inexact Rounded
1688dqadd375016 fma  1  1239876543211234567894567890123456 6E-15  -> 1239876543211234567894567890123456  Inexact Rounded
1689dqadd375017 fma  1  1239876543211234567894567890123456 6E-16  -> 1239876543211234567894567890123456  Inexact Rounded
1690dqadd375018 fma  1  1239876543211234567894567890123456 6E-17  -> 1239876543211234567894567890123456  Inexact Rounded
1691dqadd375019 fma  1  1239876543211234567894567890123456 6E-18  -> 1239876543211234567894567890123456  Inexact Rounded
1692dqadd375020 fma  1  1239876543211234567894567890123456 6E-19  -> 1239876543211234567894567890123456  Inexact Rounded
1693dqadd375021 fma  1  1239876543211234567894567890123456 6E-20  -> 1239876543211234567894567890123456  Inexact Rounded
1694
1695-- widening second argument at gap
1696dqadd375030 fma  1  12398765432112345678945678 1                       -> 12398765432112345678945679
1697dqadd375031 fma  1  12398765432112345678945678 0.1                     -> 12398765432112345678945678.1
1698dqadd375032 fma  1  12398765432112345678945678 0.12                    -> 12398765432112345678945678.12
1699dqadd375033 fma  1  12398765432112345678945678 0.123                   -> 12398765432112345678945678.123
1700dqadd375034 fma  1  12398765432112345678945678 0.1234                  -> 12398765432112345678945678.1234
1701dqadd375035 fma  1  12398765432112345678945678 0.12345                 -> 12398765432112345678945678.12345
1702dqadd375036 fma  1  12398765432112345678945678 0.123456                -> 12398765432112345678945678.123456
1703dqadd375037 fma  1  12398765432112345678945678 0.1234567               -> 12398765432112345678945678.1234567
1704dqadd375038 fma  1  12398765432112345678945678 0.12345678              -> 12398765432112345678945678.12345678
1705dqadd375039 fma  1  12398765432112345678945678 0.123456789             -> 12398765432112345678945678.12345679 Inexact Rounded
1706dqadd375040 fma  1  12398765432112345678945678 0.123456785             -> 12398765432112345678945678.12345678 Inexact Rounded
1707dqadd375041 fma  1  12398765432112345678945678 0.1234567850            -> 12398765432112345678945678.12345678 Inexact Rounded
1708dqadd375042 fma  1  12398765432112345678945678 0.1234567851            -> 12398765432112345678945678.12345679 Inexact Rounded
1709dqadd375043 fma  1  12398765432112345678945678 0.12345678501           -> 12398765432112345678945678.12345679 Inexact Rounded
1710dqadd375044 fma  1  12398765432112345678945678 0.123456785001          -> 12398765432112345678945678.12345679 Inexact Rounded
1711dqadd375045 fma  1  12398765432112345678945678 0.1234567850001         -> 12398765432112345678945678.12345679 Inexact Rounded
1712dqadd375046 fma  1  12398765432112345678945678 0.12345678500001        -> 12398765432112345678945678.12345679 Inexact Rounded
1713dqadd375047 fma  1  12398765432112345678945678 0.123456785000001       -> 12398765432112345678945678.12345679 Inexact Rounded
1714dqadd375048 fma  1  12398765432112345678945678 0.1234567850000001      -> 12398765432112345678945678.12345679 Inexact Rounded
1715dqadd375049 fma  1  12398765432112345678945678 0.1234567850000000      -> 12398765432112345678945678.12345678 Inexact Rounded
1716--                               90123456
1717rounding: half_even
1718dqadd375050 fma  1  12398765432112345678945678 0.0234567750000000      -> 12398765432112345678945678.02345678 Inexact Rounded
1719dqadd375051 fma  1  12398765432112345678945678 0.0034567750000000      -> 12398765432112345678945678.00345678 Inexact Rounded
1720dqadd375052 fma  1  12398765432112345678945678 0.0004567750000000      -> 12398765432112345678945678.00045678 Inexact Rounded
1721dqadd375053 fma  1  12398765432112345678945678 0.0000567750000000      -> 12398765432112345678945678.00005678 Inexact Rounded
1722dqadd375054 fma  1  12398765432112345678945678 0.0000067750000000      -> 12398765432112345678945678.00000678 Inexact Rounded
1723dqadd375055 fma  1  12398765432112345678945678 0.0000007750000000      -> 12398765432112345678945678.00000078 Inexact Rounded
1724dqadd375056 fma  1  12398765432112345678945678 0.0000000750000000      -> 12398765432112345678945678.00000008 Inexact Rounded
1725dqadd375057 fma  1  12398765432112345678945678 0.0000000050000000      -> 12398765432112345678945678.00000000 Inexact Rounded
1726dqadd375060 fma  1  12398765432112345678945678 0.0234567750000001      -> 12398765432112345678945678.02345678 Inexact Rounded
1727dqadd375061 fma  1  12398765432112345678945678 0.0034567750000001      -> 12398765432112345678945678.00345678 Inexact Rounded
1728dqadd375062 fma  1  12398765432112345678945678 0.0004567750000001      -> 12398765432112345678945678.00045678 Inexact Rounded
1729dqadd375063 fma  1  12398765432112345678945678 0.0000567750000001      -> 12398765432112345678945678.00005678 Inexact Rounded
1730dqadd375064 fma  1  12398765432112345678945678 0.0000067750000001      -> 12398765432112345678945678.00000678 Inexact Rounded
1731dqadd375065 fma  1  12398765432112345678945678 0.0000007750000001      -> 12398765432112345678945678.00000078 Inexact Rounded
1732dqadd375066 fma  1  12398765432112345678945678 0.0000000750000001      -> 12398765432112345678945678.00000008 Inexact Rounded
1733dqadd375067 fma  1  12398765432112345678945678 0.0000000050000001      -> 12398765432112345678945678.00000001 Inexact Rounded
1734-- far-out residues (full coefficient gap is 16+15 digits)
1735rounding: up
1736dqadd375070 fma  1  12398765432112345678945678 1E-8                    -> 12398765432112345678945678.00000001
1737dqadd375071 fma  1  12398765432112345678945678 1E-9                    -> 12398765432112345678945678.00000001 Inexact Rounded
1738dqadd375072 fma  1  12398765432112345678945678 1E-10                   -> 12398765432112345678945678.00000001 Inexact Rounded
1739dqadd375073 fma  1  12398765432112345678945678 1E-11                   -> 12398765432112345678945678.00000001 Inexact Rounded
1740dqadd375074 fma  1  12398765432112345678945678 1E-12                   -> 12398765432112345678945678.00000001 Inexact Rounded
1741dqadd375075 fma  1  12398765432112345678945678 1E-13                   -> 12398765432112345678945678.00000001 Inexact Rounded
1742dqadd375076 fma  1  12398765432112345678945678 1E-14                   -> 12398765432112345678945678.00000001 Inexact Rounded
1743dqadd375077 fma  1  12398765432112345678945678 1E-15                   -> 12398765432112345678945678.00000001 Inexact Rounded
1744dqadd375078 fma  1  12398765432112345678945678 1E-16                   -> 12398765432112345678945678.00000001 Inexact Rounded
1745dqadd375079 fma  1  12398765432112345678945678 1E-17                   -> 12398765432112345678945678.00000001 Inexact Rounded
1746dqadd375080 fma  1  12398765432112345678945678 1E-18                   -> 12398765432112345678945678.00000001 Inexact Rounded
1747dqadd375081 fma  1  12398765432112345678945678 1E-19                   -> 12398765432112345678945678.00000001 Inexact Rounded
1748dqadd375082 fma  1  12398765432112345678945678 1E-20                   -> 12398765432112345678945678.00000001 Inexact Rounded
1749dqadd375083 fma  1  12398765432112345678945678 1E-25                   -> 12398765432112345678945678.00000001 Inexact Rounded
1750dqadd375084 fma  1  12398765432112345678945678 1E-30                   -> 12398765432112345678945678.00000001 Inexact Rounded
1751dqadd375085 fma  1  12398765432112345678945678 1E-31                   -> 12398765432112345678945678.00000001 Inexact Rounded
1752dqadd375086 fma  1  12398765432112345678945678 1E-32                   -> 12398765432112345678945678.00000001 Inexact Rounded
1753dqadd375087 fma  1  12398765432112345678945678 1E-33                   -> 12398765432112345678945678.00000001 Inexact Rounded
1754dqadd375088 fma  1  12398765432112345678945678 1E-34                   -> 12398765432112345678945678.00000001 Inexact Rounded
1755dqadd375089 fma  1  12398765432112345678945678 1E-35                   -> 12398765432112345678945678.00000001 Inexact Rounded
1756
1757-- Destructive subtract (from remainder tests)
1758
1759-- +++ some of these will be off-by-one remainder vs remainderNear
1760
1761dqfma4000  fma  -1234567890123456789012345678901233   1.000000000000000000000000000000001    1234567890123456789012345678901234  ->  -0.234567890123456789012345678901233
1762dqfma4001  fma  -1234567890123456789012345678901222    1.00000000000000000000000000000001    1234567890123456789012345678901234  ->  -0.34567890123456789012345678901222
1763dqfma4002  fma  -1234567890123456789012345678901111     1.0000000000000000000000000000001    1234567890123456789012345678901234  ->  -0.4567890123456789012345678901111
1764dqfma4003  fma   -308641972530864197253086419725314   4.000000000000000000000000000000001    1234567890123456789012345678901255  ->  -1.308641972530864197253086419725314
1765dqfma4004  fma   -308641972530864197253086419725308   4.000000000000000000000000000000001    1234567890123456789012345678901234  ->  1.691358027469135802746913580274692
1766dqfma4005  fma   -246913578024691357802469135780252     4.9999999999999999999999999999999    1234567890123456789012345678901234  ->  -1.3086421975308642197530864219748
1767dqfma4006  fma   -246913578024691357802469135780247    4.99999999999999999999999999999999    1234567890123456789012345678901234  ->  1.46913578024691357802469135780247
1768dqfma4007  fma   -246913578024691357802469135780247   4.999999999999999999999999999999999    1234567890123456789012345678901234  ->  -0.753086421975308642197530864219753
1769dqfma4008  fma   -246913578024691357802469135780247   5.000000000000000000000000000000001    1234567890123456789012345678901234  ->  -1.246913578024691357802469135780247
1770dqfma4009  fma   -246913578024691357802469135780246    5.00000000000000000000000000000001    1234567890123456789012345678901234  ->  1.53086421975308642197530864219754
1771dqfma4010  fma   -246913578024691357802469135780242     5.0000000000000000000000000000001    1234567890123456789012345678901234  ->  -0.6913578024691357802469135780242
1772dqfma4011  fma  -1234567890123456789012345678901232   1.000000000000000000000000000000001    1234567890123456789012345678901234  ->  0.765432109876543210987654321098768
1773dqfma4012  fma  -1234567890123456789012345678901221    1.00000000000000000000000000000001    1234567890123456789012345678901234  ->  0.65432109876543210987654321098779
1774dqfma4013  fma  -1234567890123456789012345678901110     1.0000000000000000000000000000001    1234567890123456789012345678901234  ->  0.5432109876543210987654321098890
1775dqfma4014  fma   -308641972530864197253086419725313   4.000000000000000000000000000000001    1234567890123456789012345678901255  ->  2.691358027469135802746913580274687
1776dqfma4015  fma   -308641972530864197253086419725308   4.000000000000000000000000000000001    1234567890123456789012345678901234  ->  1.691358027469135802746913580274692
1777dqfma4016  fma   -246913578024691357802469135780251     4.9999999999999999999999999999999    1234567890123456789012345678901234  ->  3.6913578024691357802469135780251
1778dqfma4017  fma   -246913578024691357802469135780247    4.99999999999999999999999999999999    1234567890123456789012345678901234  ->  1.46913578024691357802469135780247
1779dqfma4018  fma   -246913578024691357802469135780246   4.999999999999999999999999999999999    1234567890123456789012345678901234  ->  4.246913578024691357802469135780246
1780dqfma4019  fma   -246913578024691357802469135780241     5.0000000000000000000000000000001    1234567890123456789012345678901234  ->  4.3086421975308642197530864219759
1781
1782-- Null tests
1783dqadd39990 fma  1  10  # -> NaN Invalid_operation
1784dqadd39991 fma  1   # 10 -> NaN Invalid_operation
1785
1786
1787