]> CyberLeo.Net >> Repos - FreeBSD/releng/7.2.git/blob - contrib/gdtoa/test/x.ou1
Create releng/7.2 from stable/7 in preparation for 7.2-RELEASE.
[FreeBSD/releng/7.2.git] / contrib / gdtoa / test / x.ou1
1
2 Input: 1.23
3
4 strtox consumes 4 bytes and returns 33
5 with bits = #3fff 9d70 a3d7 a3d 70a4
6 printf("%.21Lg") gives 1.23000000000000000002
7 g_xfmt(0) gives 4 bytes: "1.23"
8
9 strtoIx returns 33, consuming 4 bytes.
10 fI[0] = #3fff 9d70 a3d7 a3d 70a3
11 = 1.22999999999999999991
12 fI[1] = #3fff 9d70 a3d7 a3d 70a4
13 = 1.23000000000000000002
14 fI[1] == strtox
15
16
17 Input: 1.23e+20
18
19 strtox consumes 8 bytes and returns 1
20 with bits = #4041 d55e f90a 2da1 8000
21 printf("%.21Lg") gives 123000000000000000000
22 g_xfmt(0) gives 8 bytes: "1.23e+20"
23
24 strtoIx returns 1, consuming 8 bytes.
25 fI[0] == fI[1] == strtox
26
27
28 Input: 1.23e-20
29
30 strtox consumes 8 bytes and returns 17
31 with bits = #3fbc e857 267b b3a9 84f2
32 printf("%.21Lg") gives 1.22999999999999999997e-20
33 g_xfmt(0) gives 8 bytes: "1.23e-20"
34
35 strtoIx returns 17, consuming 8 bytes.
36 fI[0] = #3fbc e857 267b b3a9 84f2
37 = 1.22999999999999999997e-20
38 fI[1] = #3fbc e857 267b b3a9 84f3
39 = 1.23000000000000000004e-20
40 fI[0] == strtox
41
42
43 Input: 1.23456789
44
45 strtox consumes 10 bytes and returns 33
46 with bits = #3fff 9e06 5214 1ef0 dbf6
47 printf("%.21Lg") gives 1.23456789000000000003
48 g_xfmt(0) gives 10 bytes: "1.23456789"
49
50 strtoIx returns 33, consuming 10 bytes.
51 fI[0] = #3fff 9e06 5214 1ef0 dbf5
52 = 1.23456788999999999992
53 fI[1] = #3fff 9e06 5214 1ef0 dbf6
54 = 1.23456789000000000003
55 fI[1] == strtox
56
57
58 Input: 1.23456589e+20
59
60 strtox consumes 14 bytes and returns 1
61 with bits = #4041 d629 bd33 5cc ba00
62 printf("%.21Lg") gives 123456589000000000000
63 g_xfmt(0) gives 14 bytes: "1.23456589e+20"
64
65 strtoIx returns 1, consuming 14 bytes.
66 fI[0] == fI[1] == strtox
67
68
69 Input: 1.23e+30
70
71 strtox consumes 8 bytes and returns 17
72 with bits = #4062 f865 8274 7dbc 824a
73 printf("%.21Lg") gives 1.22999999999999999999e+30
74 g_xfmt(0) gives 8 bytes: "1.23e+30"
75
76 strtoIx returns 17, consuming 8 bytes.
77 fI[0] = #4062 f865 8274 7dbc 824a
78 = 1.22999999999999999999e+30
79 fI[1] = #4062 f865 8274 7dbc 824b
80 = 1.23000000000000000006e+30
81 fI[0] == strtox
82
83
84 Input: 1.23e-30
85
86 strtox consumes 8 bytes and returns 17
87 with bits = #3f9b c794 337a 8085 54eb
88 printf("%.21Lg") gives 1.22999999999999999999e-30
89 g_xfmt(0) gives 8 bytes: "1.23e-30"
90
91 strtoIx returns 17, consuming 8 bytes.
92 fI[0] = #3f9b c794 337a 8085 54eb
93 = 1.22999999999999999999e-30
94 fI[1] = #3f9b c794 337a 8085 54ec
95 = 1.23000000000000000007e-30
96 fI[0] == strtox
97
98
99 Input: 1.23456789e-20
100
101 strtox consumes 14 bytes and returns 17
102 with bits = #3fbc e934 a38 f3d6 d352
103 printf("%.21Lg") gives 1.23456788999999999998e-20
104 g_xfmt(0) gives 14 bytes: "1.23456789e-20"
105
106 strtoIx returns 17, consuming 14 bytes.
107 fI[0] = #3fbc e934 a38 f3d6 d352
108 = 1.23456788999999999998e-20
109 fI[1] = #3fbc e934 a38 f3d6 d353
110 = 1.23456789000000000005e-20
111 fI[0] == strtox
112
113
114 Input: 1.23456789e-30
115
116 strtox consumes 14 bytes and returns 17
117 with bits = #3f9b c851 f19d decc a8fc
118 printf("%.21Lg") gives 1.23456788999999999999e-30
119 g_xfmt(0) gives 14 bytes: "1.23456789e-30"
120
121 strtoIx returns 17, consuming 14 bytes.
122 fI[0] = #3f9b c851 f19d decc a8fc
123 = 1.23456788999999999999e-30
124 fI[1] = #3f9b c851 f19d decc a8fd
125 = 1.23456789000000000007e-30
126 fI[0] == strtox
127
128
129 Input: 1.234567890123456789
130
131 strtox consumes 20 bytes and returns 17
132 with bits = #3fff 9e06 5214 62cf db8d
133 printf("%.21Lg") gives 1.23456789012345678899
134 g_xfmt(0) gives 20 bytes: "1.234567890123456789"
135
136 strtoIx returns 17, consuming 20 bytes.
137 fI[0] = #3fff 9e06 5214 62cf db8d
138 = 1.23456789012345678899
139 fI[1] = #3fff 9e06 5214 62cf db8e
140 = 1.23456789012345678909
141 fI[0] == strtox
142
143
144 Input: 1.23456789012345678901234567890123456789
145
146 strtox consumes 40 bytes and returns 17
147 with bits = #3fff 9e06 5214 62cf db8d
148 printf("%.21Lg") gives 1.23456789012345678899
149 g_xfmt(0) gives 20 bytes: "1.234567890123456789"
150
151 strtoIx returns 17, consuming 40 bytes.
152 fI[0] = #3fff 9e06 5214 62cf db8d
153 = 1.23456789012345678899
154 fI[1] = #3fff 9e06 5214 62cf db8e
155 = 1.23456789012345678909
156 fI[0] == strtox
157
158
159 Input: 1.23e306
160
161 strtox consumes 8 bytes and returns 17
162 with bits = #43f7 e033 b668 e30f a6d5
163 printf("%.21Lg") gives 1.22999999999999999997e+306
164 g_xfmt(0) gives 9 bytes: "1.23e+306"
165
166 strtoIx returns 17, consuming 8 bytes.
167 fI[0] = #43f7 e033 b668 e30f a6d5
168 = 1.22999999999999999997e+306
169 fI[1] = #43f7 e033 b668 e30f a6d6
170 = 1.23000000000000000005e+306
171 fI[0] == strtox
172
173
174 Input: 1.23e-306
175
176 strtox consumes 9 bytes and returns 33
177 with bits = #3c06 dd1d c2ed 1cb7 3f25
178 printf("%.21Lg") gives 1.23000000000000000002e-306
179 g_xfmt(0) gives 9 bytes: "1.23e-306"
180
181 strtoIx returns 33, consuming 9 bytes.
182 fI[0] = #3c06 dd1d c2ed 1cb7 3f24
183 = 1.22999999999999999995e-306
184 fI[1] = #3c06 dd1d c2ed 1cb7 3f25
185 = 1.23000000000000000002e-306
186 fI[1] == strtox
187
188
189 Input: 1.23e-320
190
191 strtox consumes 9 bytes and returns 33
192 with bits = #3bd8 9b98 c371 844c 3f1a
193 printf("%.21Lg") gives 1.23000000000000000002e-320
194 g_xfmt(0) gives 9 bytes: "1.23e-320"
195
196 strtoIx returns 33, consuming 9 bytes.
197 fI[0] = #3bd8 9b98 c371 844c 3f19
198 = 1.22999999999999999991e-320
199 fI[1] = #3bd8 9b98 c371 844c 3f1a
200 = 1.23000000000000000002e-320
201 fI[1] == strtox
202
203
204 Input: 1.23e-20
205
206 strtox consumes 8 bytes and returns 17
207 with bits = #3fbc e857 267b b3a9 84f2
208 printf("%.21Lg") gives 1.22999999999999999997e-20
209 g_xfmt(0) gives 8 bytes: "1.23e-20"
210
211 strtoIx returns 17, consuming 8 bytes.
212 fI[0] = #3fbc e857 267b b3a9 84f2
213 = 1.22999999999999999997e-20
214 fI[1] = #3fbc e857 267b b3a9 84f3
215 = 1.23000000000000000004e-20
216 fI[0] == strtox
217
218
219 Input: 1.23456789e307
220
221 strtox consumes 14 bytes and returns 17
222 with bits = #43fb 8ca5 8a5e d766 de75
223 printf("%.21Lg") gives 1.23456788999999999998e+307
224 g_xfmt(0) gives 15 bytes: "1.23456789e+307"
225
226 strtoIx returns 17, consuming 14 bytes.
227 fI[0] = #43fb 8ca5 8a5e d766 de75
228 = 1.23456788999999999998e+307
229 fI[1] = #43fb 8ca5 8a5e d766 de76
230 = 1.23456789000000000011e+307
231 fI[0] == strtox
232
233
234 Input: 1.23456589e-307
235
236 strtox consumes 15 bytes and returns 17
237 with bits = #3c03 b18c b5dc c22f d369
238 printf("%.21Lg") gives 1.23456588999999999999e-307
239 g_xfmt(0) gives 15 bytes: "1.23456589e-307"
240
241 strtoIx returns 17, consuming 15 bytes.
242 fI[0] = #3c03 b18c b5dc c22f d369
243 = 1.23456588999999999999e-307
244 fI[1] = #3c03 b18c b5dc c22f d36a
245 = 1.23456589000000000009e-307
246 fI[0] == strtox
247
248
249 Input: 1.234567890123456789
250
251 strtox consumes 20 bytes and returns 17
252 with bits = #3fff 9e06 5214 62cf db8d
253 printf("%.21Lg") gives 1.23456789012345678899
254 g_xfmt(0) gives 20 bytes: "1.234567890123456789"
255
256 strtoIx returns 17, consuming 20 bytes.
257 fI[0] = #3fff 9e06 5214 62cf db8d
258 = 1.23456789012345678899
259 fI[1] = #3fff 9e06 5214 62cf db8e
260 = 1.23456789012345678909
261 fI[0] == strtox
262
263
264 Input: 1.234567890123456789e301
265
266 strtox consumes 24 bytes and returns 33
267 with bits = #43e7 937a 8baf ab20 980c
268 printf("%.21Lg") gives 1.234567890123456789e+301
269 g_xfmt(0) gives 25 bytes: "1.234567890123456789e+301"
270
271 strtoIx returns 33, consuming 24 bytes.
272 fI[0] = #43e7 937a 8baf ab20 980b
273 = 1.23456789012345678889e+301
274 fI[1] = #43e7 937a 8baf ab20 980c
275 = 1.234567890123456789e+301
276 fI[1] == strtox
277
278
279 Input: 1.234567890123456789e-301
280
281 strtox consumes 25 bytes and returns 33
282 with bits = #3c17 a953 271a 5d06 9ad9
283 printf("%.21Lg") gives 1.23456789012345678902e-301
284 g_xfmt(0) gives 25 bytes: "1.234567890123456789e-301"
285
286 strtoIx returns 33, consuming 25 bytes.
287 fI[0] = #3c17 a953 271a 5d06 9ad8
288 = 1.23456789012345678892e-301
289 fI[1] = #3c17 a953 271a 5d06 9ad9
290 = 1.23456789012345678902e-301
291 fI[1] == strtox
292
293
294 Input: 1.234567890123456789e-321
295
296 strtox consumes 25 bytes and returns 33
297 with bits = #3bd4 f9e1 1b4c ea6d cce9
298 printf("%.21Lg") gives 1.234567890123456789e-321
299 g_xfmt(0) gives 25 bytes: "1.234567890123456789e-321"
300
301 strtoIx returns 33, consuming 25 bytes.
302 fI[0] = #3bd4 f9e1 1b4c ea6d cce8
303 = 1.23456789012345678893e-321
304 fI[1] = #3bd4 f9e1 1b4c ea6d cce9
305 = 1.234567890123456789e-321
306 fI[1] == strtox
307
308
309 Input: 1e23
310
311 strtox consumes 4 bytes and returns 1
312 with bits = #404b a968 163f a57 b400
313 printf("%.21Lg") gives 1e+23
314 g_xfmt(0) gives 5 bytes: "1e+23"
315
316 strtoIx returns 1, consuming 4 bytes.
317 fI[0] == fI[1] == strtox
318
319
320 Input: 1e310
321
322 strtox consumes 5 bytes and returns 33
323 with bits = #4404 de81 e40a 34b cf50
324 printf("%.21Lg") gives 1e+310
325 g_xfmt(0) gives 6 bytes: "1e+310"
326
327 strtoIx returns 33, consuming 5 bytes.
328 fI[0] = #4404 de81 e40a 34b cf4f
329 = 9.9999999999999999994e+309
330 fI[1] = #4404 de81 e40a 34b cf50
331 = 1e+310
332 fI[1] == strtox
333
334
335 Input: 9.0259718793241475e-277
336
337 strtox consumes 23 bytes and returns 33
338 with bits = #3c69 ffff ffff ffff fcf7
339 printf("%.21Lg") gives 9.02597187932414750016e-277
340 g_xfmt(0) gives 23 bytes: "9.0259718793241475e-277"
341
342 strtoIx returns 33, consuming 23 bytes.
343 fI[0] = #3c69 ffff ffff ffff fcf6
344 = 9.02597187932414749967e-277
345 fI[1] = #3c69 ffff ffff ffff fcf7
346 = 9.02597187932414750016e-277
347 fI[1] == strtox
348
349
350 Input: 9.025971879324147880346310405869e-277
351
352 strtox consumes 37 bytes and returns 17
353 with bits = #3c6a 8000 0 0 0
354 printf("%.21Lg") gives 9.02597187932414788035e-277
355 g_xfmt(0) gives 26 bytes: "9.0259718793241478803e-277"
356
357 strtoIx returns 17, consuming 37 bytes.
358 fI[0] = #3c6a 8000 0 0 0
359 = 9.02597187932414788035e-277
360 fI[1] = #3c6a 8000 0 0 1
361 = 9.02597187932414788132e-277
362 fI[0] == strtox
363
364
365 Input: 9.025971879324147880346310405868e-277
366
367 strtox consumes 37 bytes and returns 33
368 with bits = #3c6a 8000 0 0 0
369 printf("%.21Lg") gives 9.02597187932414788035e-277
370 g_xfmt(0) gives 26 bytes: "9.0259718793241478803e-277"
371
372 strtoIx returns 33, consuming 37 bytes.
373 fI[0] = #3c69 ffff ffff ffff ffff
374 = 9.02597187932414787986e-277
375 fI[1] = #3c6a 8000 0 0 0
376 = 9.02597187932414788035e-277
377 fI[1] == strtox
378
379
380 Input: 2.2250738585072014e-308
381
382 strtox consumes 23 bytes and returns 17
383 with bits = #3c01 8000 0 0 46
384 printf("%.21Lg") gives 2.22507385850720139998e-308
385 g_xfmt(0) gives 23 bytes: "2.2250738585072014e-308"
386
387 strtoIx returns 17, consuming 23 bytes.
388 fI[0] = #3c01 8000 0 0 46
389 = 2.22507385850720139998e-308
390 fI[1] = #3c01 8000 0 0 47
391 = 2.22507385850720140022e-308
392 fI[0] == strtox
393
394
395 Input: 2.2250738585072013e-308
396
397 strtox consumes 23 bytes and returns 17
398 with bits = #3c00 ffff ffff ffff fd4f
399 printf("%.21Lg") gives 2.22507385850720129998e-308
400 g_xfmt(0) gives 23 bytes: "2.2250738585072013e-308"
401
402 strtoIx returns 17, consuming 23 bytes.
403 fI[0] = #3c00 ffff ffff ffff fd4f
404 = 2.22507385850720129998e-308
405 fI[1] = #3c00 ffff ffff ffff fd50
406 = 2.2250738585072013001e-308
407 fI[0] == strtox
408
409 Rounding mode for strtor... changed from 1 (nearest) to 0 (toward zero)
410
411 Input: 1.1
412
413 strtox consumes 3 bytes and returns 17
414 with bits = #3fff 8ccc cccc cccc cccc
415 printf("%.21Lg") gives 1.09999999999999999991
416 g_xfmt(0) gives 21 bytes: "1.0999999999999999999"
417
418 strtoIx returns 33, consuming 3 bytes.
419 fI[0] = #3fff 8ccc cccc cccc cccc
420 = 1.09999999999999999991
421 fI[1] = #3fff 8ccc cccc cccc cccd
422 = 1.10000000000000000002
423 fI[0] == strtox
424
425
426 Input: -1.1
427
428 strtox consumes 4 bytes and returns 25
429 with bits = #bfff 8ccc cccc cccc cccc
430 printf("%.21Lg") gives -1.09999999999999999991
431 g_xfmt(0) gives 22 bytes: "-1.0999999999999999999"
432
433 strtoIx returns 41, consuming 4 bytes.
434 fI[0] = #bfff 8ccc cccc cccc cccd
435 = -1.10000000000000000002
436 fI[1] = #bfff 8ccc cccc cccc cccc
437 = -1.09999999999999999991
438 fI[1] == strtox
439
440
441 Input: 1.2
442
443 strtox consumes 3 bytes and returns 17
444 with bits = #3fff 9999 9999 9999 9999
445 printf("%.21Lg") gives 1.19999999999999999993
446 g_xfmt(0) gives 21 bytes: "1.1999999999999999999"
447
448 strtoIx returns 33, consuming 3 bytes.
449 fI[0] = #3fff 9999 9999 9999 9999
450 = 1.19999999999999999993
451 fI[1] = #3fff 9999 9999 9999 999a
452 = 1.20000000000000000004
453 fI[0] == strtox
454
455
456 Input: -1.2
457
458 strtox consumes 4 bytes and returns 25
459 with bits = #bfff 9999 9999 9999 9999
460 printf("%.21Lg") gives -1.19999999999999999993
461 g_xfmt(0) gives 22 bytes: "-1.1999999999999999999"
462
463 strtoIx returns 41, consuming 4 bytes.
464 fI[0] = #bfff 9999 9999 9999 999a
465 = -1.20000000000000000004
466 fI[1] = #bfff 9999 9999 9999 9999
467 = -1.19999999999999999993
468 fI[1] == strtox
469
470
471 Input: 1.3
472
473 strtox consumes 3 bytes and returns 17
474 with bits = #3fff a666 6666 6666 6666
475 printf("%.21Lg") gives 1.29999999999999999996
476 g_xfmt(0) gives 3 bytes: "1.3"
477
478 strtoIx returns 17, consuming 3 bytes.
479 fI[0] = #3fff a666 6666 6666 6666
480 = 1.29999999999999999996
481 fI[1] = #3fff a666 6666 6666 6667
482 = 1.30000000000000000007
483 fI[0] == strtox
484
485
486 Input: -1.3
487
488 strtox consumes 4 bytes and returns 25
489 with bits = #bfff a666 6666 6666 6666
490 printf("%.21Lg") gives -1.29999999999999999996
491 g_xfmt(0) gives 4 bytes: "-1.3"
492
493 strtoIx returns 25, consuming 4 bytes.
494 fI[0] = #bfff a666 6666 6666 6667
495 = -1.30000000000000000007
496 fI[1] = #bfff a666 6666 6666 6666
497 = -1.29999999999999999996
498 fI[1] == strtox
499
500
501 Input: 1.4
502
503 strtox consumes 3 bytes and returns 17
504 with bits = #3fff b333 3333 3333 3333
505 printf("%.21Lg") gives 1.39999999999999999998
506 g_xfmt(0) gives 3 bytes: "1.4"
507
508 strtoIx returns 17, consuming 3 bytes.
509 fI[0] = #3fff b333 3333 3333 3333
510 = 1.39999999999999999998
511 fI[1] = #3fff b333 3333 3333 3334
512 = 1.40000000000000000009
513 fI[0] == strtox
514
515
516 Input: -1.4
517
518 strtox consumes 4 bytes and returns 25
519 with bits = #bfff b333 3333 3333 3333
520 printf("%.21Lg") gives -1.39999999999999999998
521 g_xfmt(0) gives 4 bytes: "-1.4"
522
523 strtoIx returns 25, consuming 4 bytes.
524 fI[0] = #bfff b333 3333 3333 3334
525 = -1.40000000000000000009
526 fI[1] = #bfff b333 3333 3333 3333
527 = -1.39999999999999999998
528 fI[1] == strtox
529
530
531 Input: 1.5
532
533 strtox consumes 3 bytes and returns 1
534 with bits = #3fff c000 0 0 0
535 printf("%.21Lg") gives 1.5
536 g_xfmt(0) gives 3 bytes: "1.5"
537
538 strtoIx returns 1, consuming 3 bytes.
539 fI[0] == fI[1] == strtox
540
541
542 Input: -1.5
543
544 strtox consumes 4 bytes and returns 9
545 with bits = #bfff c000 0 0 0
546 printf("%.21Lg") gives -1.5
547 g_xfmt(0) gives 4 bytes: "-1.5"
548
549 strtoIx returns 9, consuming 4 bytes.
550 fI[0] == fI[1] == strtox
551
552
553 Input: 1.6
554
555 strtox consumes 3 bytes and returns 17
556 with bits = #3fff cccc cccc cccc cccc
557 printf("%.21Lg") gives 1.59999999999999999991
558 g_xfmt(0) gives 21 bytes: "1.5999999999999999999"
559
560 strtoIx returns 33, consuming 3 bytes.
561 fI[0] = #3fff cccc cccc cccc cccc
562 = 1.59999999999999999991
563 fI[1] = #3fff cccc cccc cccc cccd
564 = 1.60000000000000000002
565 fI[0] == strtox
566
567
568 Input: -1.6
569
570 strtox consumes 4 bytes and returns 25
571 with bits = #bfff cccc cccc cccc cccc
572 printf("%.21Lg") gives -1.59999999999999999991
573 g_xfmt(0) gives 22 bytes: "-1.5999999999999999999"
574
575 strtoIx returns 41, consuming 4 bytes.
576 fI[0] = #bfff cccc cccc cccc cccd
577 = -1.60000000000000000002
578 fI[1] = #bfff cccc cccc cccc cccc
579 = -1.59999999999999999991
580 fI[1] == strtox
581
582
583 Input: 1.7
584
585 strtox consumes 3 bytes and returns 17
586 with bits = #3fff d999 9999 9999 9999
587 printf("%.21Lg") gives 1.69999999999999999993
588 g_xfmt(0) gives 21 bytes: "1.6999999999999999999"
589
590 strtoIx returns 33, consuming 3 bytes.
591 fI[0] = #3fff d999 9999 9999 9999
592 = 1.69999999999999999993
593 fI[1] = #3fff d999 9999 9999 999a
594 = 1.70000000000000000004
595 fI[0] == strtox
596
597
598 Input: -1.7
599
600 strtox consumes 4 bytes and returns 25
601 with bits = #bfff d999 9999 9999 9999
602 printf("%.21Lg") gives -1.69999999999999999993
603 g_xfmt(0) gives 22 bytes: "-1.6999999999999999999"
604
605 strtoIx returns 41, consuming 4 bytes.
606 fI[0] = #bfff d999 9999 9999 999a
607 = -1.70000000000000000004
608 fI[1] = #bfff d999 9999 9999 9999
609 = -1.69999999999999999993
610 fI[1] == strtox
611
612
613 Input: 1.8
614
615 strtox consumes 3 bytes and returns 17
616 with bits = #3fff e666 6666 6666 6666
617 printf("%.21Lg") gives 1.79999999999999999996
618 g_xfmt(0) gives 3 bytes: "1.8"
619
620 strtoIx returns 17, consuming 3 bytes.
621 fI[0] = #3fff e666 6666 6666 6666
622 = 1.79999999999999999996
623 fI[1] = #3fff e666 6666 6666 6667
624 = 1.80000000000000000007
625 fI[0] == strtox
626
627
628 Input: -1.8
629
630 strtox consumes 4 bytes and returns 25
631 with bits = #bfff e666 6666 6666 6666
632 printf("%.21Lg") gives -1.79999999999999999996
633 g_xfmt(0) gives 4 bytes: "-1.8"
634
635 strtoIx returns 25, consuming 4 bytes.
636 fI[0] = #bfff e666 6666 6666 6667
637 = -1.80000000000000000007
638 fI[1] = #bfff e666 6666 6666 6666
639 = -1.79999999999999999996
640 fI[1] == strtox
641
642
643 Input: 1.9
644
645 strtox consumes 3 bytes and returns 17
646 with bits = #3fff f333 3333 3333 3333
647 printf("%.21Lg") gives 1.89999999999999999998
648 g_xfmt(0) gives 3 bytes: "1.9"
649
650 strtoIx returns 17, consuming 3 bytes.
651 fI[0] = #3fff f333 3333 3333 3333
652 = 1.89999999999999999998
653 fI[1] = #3fff f333 3333 3333 3334
654 = 1.90000000000000000009
655 fI[0] == strtox
656
657
658 Input: -1.9
659
660 strtox consumes 4 bytes and returns 25
661 with bits = #bfff f333 3333 3333 3333
662 printf("%.21Lg") gives -1.89999999999999999998
663 g_xfmt(0) gives 4 bytes: "-1.9"
664
665 strtoIx returns 25, consuming 4 bytes.
666 fI[0] = #bfff f333 3333 3333 3334
667 = -1.90000000000000000009
668 fI[1] = #bfff f333 3333 3333 3333
669 = -1.89999999999999999998
670 fI[1] == strtox
671
672 Rounding mode for strtor... changed from 0 (toward zero) to 1 (nearest)
673
674 Input: 1.1
675
676 strtox consumes 3 bytes and returns 33
677 with bits = #3fff 8ccc cccc cccc cccd
678 printf("%.21Lg") gives 1.10000000000000000002
679 g_xfmt(0) gives 3 bytes: "1.1"
680
681 strtoIx returns 33, consuming 3 bytes.
682 fI[0] = #3fff 8ccc cccc cccc cccc
683 = 1.09999999999999999991
684 fI[1] = #3fff 8ccc cccc cccc cccd
685 = 1.10000000000000000002
686 fI[1] == strtox
687
688
689 Input: -1.1
690
691 strtox consumes 4 bytes and returns 41
692 with bits = #bfff 8ccc cccc cccc cccd
693 printf("%.21Lg") gives -1.10000000000000000002
694 g_xfmt(0) gives 4 bytes: "-1.1"
695
696 strtoIx returns 41, consuming 4 bytes.
697 fI[0] = #bfff 8ccc cccc cccc cccd
698 = -1.10000000000000000002
699 fI[1] = #bfff 8ccc cccc cccc cccc
700 = -1.09999999999999999991
701 fI[0] == strtox
702
703
704 Input: 1.2
705
706 strtox consumes 3 bytes and returns 33
707 with bits = #3fff 9999 9999 9999 999a
708 printf("%.21Lg") gives 1.20000000000000000004
709 g_xfmt(0) gives 3 bytes: "1.2"
710
711 strtoIx returns 33, consuming 3 bytes.
712 fI[0] = #3fff 9999 9999 9999 9999
713 = 1.19999999999999999993
714 fI[1] = #3fff 9999 9999 9999 999a
715 = 1.20000000000000000004
716 fI[1] == strtox
717
718
719 Input: -1.2
720
721 strtox consumes 4 bytes and returns 41
722 with bits = #bfff 9999 9999 9999 999a
723 printf("%.21Lg") gives -1.20000000000000000004
724 g_xfmt(0) gives 4 bytes: "-1.2"
725
726 strtoIx returns 41, consuming 4 bytes.
727 fI[0] = #bfff 9999 9999 9999 999a
728 = -1.20000000000000000004
729 fI[1] = #bfff 9999 9999 9999 9999
730 = -1.19999999999999999993
731 fI[0] == strtox
732
733
734 Input: 1.3
735
736 strtox consumes 3 bytes and returns 17
737 with bits = #3fff a666 6666 6666 6666
738 printf("%.21Lg") gives 1.29999999999999999996
739 g_xfmt(0) gives 3 bytes: "1.3"
740
741 strtoIx returns 17, consuming 3 bytes.
742 fI[0] = #3fff a666 6666 6666 6666
743 = 1.29999999999999999996
744 fI[1] = #3fff a666 6666 6666 6667
745 = 1.30000000000000000007
746 fI[0] == strtox
747
748
749 Input: -1.3
750
751 strtox consumes 4 bytes and returns 25
752 with bits = #bfff a666 6666 6666 6666
753 printf("%.21Lg") gives -1.29999999999999999996
754 g_xfmt(0) gives 4 bytes: "-1.3"
755
756 strtoIx returns 25, consuming 4 bytes.
757 fI[0] = #bfff a666 6666 6666 6667
758 = -1.30000000000000000007
759 fI[1] = #bfff a666 6666 6666 6666
760 = -1.29999999999999999996
761 fI[1] == strtox
762
763
764 Input: 1.4
765
766 strtox consumes 3 bytes and returns 17
767 with bits = #3fff b333 3333 3333 3333
768 printf("%.21Lg") gives 1.39999999999999999998
769 g_xfmt(0) gives 3 bytes: "1.4"
770
771 strtoIx returns 17, consuming 3 bytes.
772 fI[0] = #3fff b333 3333 3333 3333
773 = 1.39999999999999999998
774 fI[1] = #3fff b333 3333 3333 3334
775 = 1.40000000000000000009
776 fI[0] == strtox
777
778
779 Input: -1.4
780
781 strtox consumes 4 bytes and returns 25
782 with bits = #bfff b333 3333 3333 3333
783 printf("%.21Lg") gives -1.39999999999999999998
784 g_xfmt(0) gives 4 bytes: "-1.4"
785
786 strtoIx returns 25, consuming 4 bytes.
787 fI[0] = #bfff b333 3333 3333 3334
788 = -1.40000000000000000009
789 fI[1] = #bfff b333 3333 3333 3333
790 = -1.39999999999999999998
791 fI[1] == strtox
792
793
794 Input: 1.5
795
796 strtox consumes 3 bytes and returns 1
797 with bits = #3fff c000 0 0 0
798 printf("%.21Lg") gives 1.5
799 g_xfmt(0) gives 3 bytes: "1.5"
800
801 strtoIx returns 1, consuming 3 bytes.
802 fI[0] == fI[1] == strtox
803
804
805 Input: -1.5
806
807 strtox consumes 4 bytes and returns 9
808 with bits = #bfff c000 0 0 0
809 printf("%.21Lg") gives -1.5
810 g_xfmt(0) gives 4 bytes: "-1.5"
811
812 strtoIx returns 9, consuming 4 bytes.
813 fI[0] == fI[1] == strtox
814
815
816 Input: 1.6
817
818 strtox consumes 3 bytes and returns 33
819 with bits = #3fff cccc cccc cccc cccd
820 printf("%.21Lg") gives 1.60000000000000000002
821 g_xfmt(0) gives 3 bytes: "1.6"
822
823 strtoIx returns 33, consuming 3 bytes.
824 fI[0] = #3fff cccc cccc cccc cccc
825 = 1.59999999999999999991
826 fI[1] = #3fff cccc cccc cccc cccd
827 = 1.60000000000000000002
828 fI[1] == strtox
829
830
831 Input: -1.6
832
833 strtox consumes 4 bytes and returns 41
834 with bits = #bfff cccc cccc cccc cccd
835 printf("%.21Lg") gives -1.60000000000000000002
836 g_xfmt(0) gives 4 bytes: "-1.6"
837
838 strtoIx returns 41, consuming 4 bytes.
839 fI[0] = #bfff cccc cccc cccc cccd
840 = -1.60000000000000000002
841 fI[1] = #bfff cccc cccc cccc cccc
842 = -1.59999999999999999991
843 fI[0] == strtox
844
845
846 Input: 1.7
847
848 strtox consumes 3 bytes and returns 33
849 with bits = #3fff d999 9999 9999 999a
850 printf("%.21Lg") gives 1.70000000000000000004
851 g_xfmt(0) gives 3 bytes: "1.7"
852
853 strtoIx returns 33, consuming 3 bytes.
854 fI[0] = #3fff d999 9999 9999 9999
855 = 1.69999999999999999993
856 fI[1] = #3fff d999 9999 9999 999a
857 = 1.70000000000000000004
858 fI[1] == strtox
859
860
861 Input: -1.7
862
863 strtox consumes 4 bytes and returns 41
864 with bits = #bfff d999 9999 9999 999a
865 printf("%.21Lg") gives -1.70000000000000000004
866 g_xfmt(0) gives 4 bytes: "-1.7"
867
868 strtoIx returns 41, consuming 4 bytes.
869 fI[0] = #bfff d999 9999 9999 999a
870 = -1.70000000000000000004
871 fI[1] = #bfff d999 9999 9999 9999
872 = -1.69999999999999999993
873 fI[0] == strtox
874
875
876 Input: 1.8
877
878 strtox consumes 3 bytes and returns 17
879 with bits = #3fff e666 6666 6666 6666
880 printf("%.21Lg") gives 1.79999999999999999996
881 g_xfmt(0) gives 3 bytes: "1.8"
882
883 strtoIx returns 17, consuming 3 bytes.
884 fI[0] = #3fff e666 6666 6666 6666
885 = 1.79999999999999999996
886 fI[1] = #3fff e666 6666 6666 6667
887 = 1.80000000000000000007
888 fI[0] == strtox
889
890
891 Input: -1.8
892
893 strtox consumes 4 bytes and returns 25
894 with bits = #bfff e666 6666 6666 6666
895 printf("%.21Lg") gives -1.79999999999999999996
896 g_xfmt(0) gives 4 bytes: "-1.8"
897
898 strtoIx returns 25, consuming 4 bytes.
899 fI[0] = #bfff e666 6666 6666 6667
900 = -1.80000000000000000007
901 fI[1] = #bfff e666 6666 6666 6666
902 = -1.79999999999999999996
903 fI[1] == strtox
904
905
906 Input: 1.9
907
908 strtox consumes 3 bytes and returns 17
909 with bits = #3fff f333 3333 3333 3333
910 printf("%.21Lg") gives 1.89999999999999999998
911 g_xfmt(0) gives 3 bytes: "1.9"
912
913 strtoIx returns 17, consuming 3 bytes.
914 fI[0] = #3fff f333 3333 3333 3333
915 = 1.89999999999999999998
916 fI[1] = #3fff f333 3333 3333 3334
917 = 1.90000000000000000009
918 fI[0] == strtox
919
920
921 Input: -1.9
922
923 strtox consumes 4 bytes and returns 25
924 with bits = #bfff f333 3333 3333 3333
925 printf("%.21Lg") gives -1.89999999999999999998
926 g_xfmt(0) gives 4 bytes: "-1.9"
927
928 strtoIx returns 25, consuming 4 bytes.
929 fI[0] = #bfff f333 3333 3333 3334
930 = -1.90000000000000000009
931 fI[1] = #bfff f333 3333 3333 3333
932 = -1.89999999999999999998
933 fI[1] == strtox
934
935 Rounding mode for strtor... changed from 1 (nearest) to 2 (toward +Infinity)
936
937 Input: 1.1
938
939 strtox consumes 3 bytes and returns 33
940 with bits = #3fff 8ccc cccc cccc cccd
941 printf("%.21Lg") gives 1.10000000000000000002
942 g_xfmt(0) gives 3 bytes: "1.1"
943
944 strtoIx returns 33, consuming 3 bytes.
945 fI[0] = #3fff 8ccc cccc cccc cccc
946 = 1.09999999999999999991
947 fI[1] = #3fff 8ccc cccc cccc cccd
948 = 1.10000000000000000002
949 fI[1] == strtox
950
951
952 Input: -1.1
953
954 strtox consumes 4 bytes and returns 25
955 with bits = #bfff 8ccc cccc cccc cccc
956 printf("%.21Lg") gives -1.09999999999999999991
957 g_xfmt(0) gives 22 bytes: "-1.0999999999999999999"
958
959 strtoIx returns 41, consuming 4 bytes.
960 fI[0] = #bfff 8ccc cccc cccc cccd
961 = -1.10000000000000000002
962 fI[1] = #bfff 8ccc cccc cccc cccc
963 = -1.09999999999999999991
964 fI[1] == strtox
965
966
967 Input: 1.2
968
969 strtox consumes 3 bytes and returns 33
970 with bits = #3fff 9999 9999 9999 999a
971 printf("%.21Lg") gives 1.20000000000000000004
972 g_xfmt(0) gives 3 bytes: "1.2"
973
974 strtoIx returns 33, consuming 3 bytes.
975 fI[0] = #3fff 9999 9999 9999 9999
976 = 1.19999999999999999993
977 fI[1] = #3fff 9999 9999 9999 999a
978 = 1.20000000000000000004
979 fI[1] == strtox
980
981
982 Input: -1.2
983
984 strtox consumes 4 bytes and returns 25
985 with bits = #bfff 9999 9999 9999 9999
986 printf("%.21Lg") gives -1.19999999999999999993
987 g_xfmt(0) gives 22 bytes: "-1.1999999999999999999"
988
989 strtoIx returns 41, consuming 4 bytes.
990 fI[0] = #bfff 9999 9999 9999 999a
991 = -1.20000000000000000004
992 fI[1] = #bfff 9999 9999 9999 9999
993 = -1.19999999999999999993
994 fI[1] == strtox
995
996
997 Input: 1.3
998
999 strtox consumes 3 bytes and returns 33
1000 with bits = #3fff a666 6666 6666 6667
1001 printf("%.21Lg") gives 1.30000000000000000007
1002 g_xfmt(0) gives 21 bytes: "1.3000000000000000001"
1003
1004 strtoIx returns 17, consuming 3 bytes.
1005 fI[0] = #3fff a666 6666 6666 6666
1006 = 1.29999999999999999996
1007 fI[1] = #3fff a666 6666 6666 6667
1008 = 1.30000000000000000007
1009 fI[1] == strtox
1010
1011
1012 Input: -1.3
1013
1014 strtox consumes 4 bytes and returns 25
1015 with bits = #bfff a666 6666 6666 6666
1016 printf("%.21Lg") gives -1.29999999999999999996
1017 g_xfmt(0) gives 4 bytes: "-1.3"
1018
1019 strtoIx returns 25, consuming 4 bytes.
1020 fI[0] = #bfff a666 6666 6666 6667
1021 = -1.30000000000000000007
1022 fI[1] = #bfff a666 6666 6666 6666
1023 = -1.29999999999999999996
1024 fI[1] == strtox
1025
1026
1027 Input: 1.4
1028
1029 strtox consumes 3 bytes and returns 33
1030 with bits = #3fff b333 3333 3333 3334
1031 printf("%.21Lg") gives 1.40000000000000000009
1032 g_xfmt(0) gives 21 bytes: "1.4000000000000000001"
1033
1034 strtoIx returns 17, consuming 3 bytes.
1035 fI[0] = #3fff b333 3333 3333 3333
1036 = 1.39999999999999999998
1037 fI[1] = #3fff b333 3333 3333 3334
1038 = 1.40000000000000000009
1039 fI[1] == strtox
1040
1041
1042 Input: -1.4
1043
1044 strtox consumes 4 bytes and returns 25
1045 with bits = #bfff b333 3333 3333 3333
1046 printf("%.21Lg") gives -1.39999999999999999998
1047 g_xfmt(0) gives 4 bytes: "-1.4"
1048
1049 strtoIx returns 25, consuming 4 bytes.
1050 fI[0] = #bfff b333 3333 3333 3334
1051 = -1.40000000000000000009
1052 fI[1] = #bfff b333 3333 3333 3333
1053 = -1.39999999999999999998
1054 fI[1] == strtox
1055
1056
1057 Input: 1.5
1058
1059 strtox consumes 3 bytes and returns 1
1060 with bits = #3fff c000 0 0 0
1061 printf("%.21Lg") gives 1.5
1062 g_xfmt(0) gives 3 bytes: "1.5"
1063
1064 strtoIx returns 1, consuming 3 bytes.
1065 fI[0] == fI[1] == strtox
1066
1067
1068 Input: -1.5
1069
1070 strtox consumes 4 bytes and returns 9
1071 with bits = #bfff c000 0 0 0
1072 printf("%.21Lg") gives -1.5
1073 g_xfmt(0) gives 4 bytes: "-1.5"
1074
1075 strtoIx returns 9, consuming 4 bytes.
1076 fI[0] == fI[1] == strtox
1077
1078
1079 Input: 1.6
1080
1081 strtox consumes 3 bytes and returns 33
1082 with bits = #3fff cccc cccc cccc cccd
1083 printf("%.21Lg") gives 1.60000000000000000002
1084 g_xfmt(0) gives 3 bytes: "1.6"
1085
1086 strtoIx returns 33, consuming 3 bytes.
1087 fI[0] = #3fff cccc cccc cccc cccc
1088 = 1.59999999999999999991
1089 fI[1] = #3fff cccc cccc cccc cccd
1090 = 1.60000000000000000002
1091 fI[1] == strtox
1092
1093
1094 Input: -1.6
1095
1096 strtox consumes 4 bytes and returns 25
1097 with bits = #bfff cccc cccc cccc cccc
1098 printf("%.21Lg") gives -1.59999999999999999991
1099 g_xfmt(0) gives 22 bytes: "-1.5999999999999999999"
1100
1101 strtoIx returns 41, consuming 4 bytes.
1102 fI[0] = #bfff cccc cccc cccc cccd
1103 = -1.60000000000000000002
1104 fI[1] = #bfff cccc cccc cccc cccc
1105 = -1.59999999999999999991
1106 fI[1] == strtox
1107
1108
1109 Input: 1.7
1110
1111 strtox consumes 3 bytes and returns 33
1112 with bits = #3fff d999 9999 9999 999a
1113 printf("%.21Lg") gives 1.70000000000000000004
1114 g_xfmt(0) gives 3 bytes: "1.7"
1115
1116 strtoIx returns 33, consuming 3 bytes.
1117 fI[0] = #3fff d999 9999 9999 9999
1118 = 1.69999999999999999993
1119 fI[1] = #3fff d999 9999 9999 999a
1120 = 1.70000000000000000004
1121 fI[1] == strtox
1122
1123
1124 Input: -1.7
1125
1126 strtox consumes 4 bytes and returns 25
1127 with bits = #bfff d999 9999 9999 9999
1128 printf("%.21Lg") gives -1.69999999999999999993
1129 g_xfmt(0) gives 22 bytes: "-1.6999999999999999999"
1130
1131 strtoIx returns 41, consuming 4 bytes.
1132 fI[0] = #bfff d999 9999 9999 999a
1133 = -1.70000000000000000004
1134 fI[1] = #bfff d999 9999 9999 9999
1135 = -1.69999999999999999993
1136 fI[1] == strtox
1137
1138
1139 Input: 1.8
1140
1141 strtox consumes 3 bytes and returns 33
1142 with bits = #3fff e666 6666 6666 6667
1143 printf("%.21Lg") gives 1.80000000000000000007
1144 g_xfmt(0) gives 21 bytes: "1.8000000000000000001"
1145
1146 strtoIx returns 17, consuming 3 bytes.
1147 fI[0] = #3fff e666 6666 6666 6666
1148 = 1.79999999999999999996
1149 fI[1] = #3fff e666 6666 6666 6667
1150 = 1.80000000000000000007
1151 fI[1] == strtox
1152
1153
1154 Input: -1.8
1155
1156 strtox consumes 4 bytes and returns 25
1157 with bits = #bfff e666 6666 6666 6666
1158 printf("%.21Lg") gives -1.79999999999999999996
1159 g_xfmt(0) gives 4 bytes: "-1.8"
1160
1161 strtoIx returns 25, consuming 4 bytes.
1162 fI[0] = #bfff e666 6666 6666 6667
1163 = -1.80000000000000000007
1164 fI[1] = #bfff e666 6666 6666 6666
1165 = -1.79999999999999999996
1166 fI[1] == strtox
1167
1168
1169 Input: 1.9
1170
1171 strtox consumes 3 bytes and returns 33
1172 with bits = #3fff f333 3333 3333 3334
1173 printf("%.21Lg") gives 1.90000000000000000009
1174 g_xfmt(0) gives 21 bytes: "1.9000000000000000001"
1175
1176 strtoIx returns 17, consuming 3 bytes.
1177 fI[0] = #3fff f333 3333 3333 3333
1178 = 1.89999999999999999998
1179 fI[1] = #3fff f333 3333 3333 3334
1180 = 1.90000000000000000009
1181 fI[1] == strtox
1182
1183
1184 Input: -1.9
1185
1186 strtox consumes 4 bytes and returns 25
1187 with bits = #bfff f333 3333 3333 3333
1188 printf("%.21Lg") gives -1.89999999999999999998
1189 g_xfmt(0) gives 4 bytes: "-1.9"
1190
1191 strtoIx returns 25, consuming 4 bytes.
1192 fI[0] = #bfff f333 3333 3333 3334
1193 = -1.90000000000000000009
1194 fI[1] = #bfff f333 3333 3333 3333
1195 = -1.89999999999999999998
1196 fI[1] == strtox
1197
1198 Rounding mode for strtor... changed from 2 (toward +Infinity) to 3 (toward -Infinity)
1199
1200 Input: 1.1
1201
1202 strtox consumes 3 bytes and returns 17
1203 with bits = #3fff 8ccc cccc cccc cccc
1204 printf("%.21Lg") gives 1.09999999999999999991
1205 g_xfmt(0) gives 21 bytes: "1.0999999999999999999"
1206
1207 strtoIx returns 33, consuming 3 bytes.
1208 fI[0] = #3fff 8ccc cccc cccc cccc
1209 = 1.09999999999999999991
1210 fI[1] = #3fff 8ccc cccc cccc cccd
1211 = 1.10000000000000000002
1212 fI[0] == strtox
1213
1214
1215 Input: -1.1
1216
1217 strtox consumes 4 bytes and returns 41
1218 with bits = #bfff 8ccc cccc cccc cccd
1219 printf("%.21Lg") gives -1.10000000000000000002
1220 g_xfmt(0) gives 4 bytes: "-1.1"
1221
1222 strtoIx returns 41, consuming 4 bytes.
1223 fI[0] = #bfff 8ccc cccc cccc cccd
1224 = -1.10000000000000000002
1225 fI[1] = #bfff 8ccc cccc cccc cccc
1226 = -1.09999999999999999991
1227 fI[0] == strtox
1228
1229
1230 Input: 1.2
1231
1232 strtox consumes 3 bytes and returns 17
1233 with bits = #3fff 9999 9999 9999 9999
1234 printf("%.21Lg") gives 1.19999999999999999993
1235 g_xfmt(0) gives 21 bytes: "1.1999999999999999999"
1236
1237 strtoIx returns 33, consuming 3 bytes.
1238 fI[0] = #3fff 9999 9999 9999 9999
1239 = 1.19999999999999999993
1240 fI[1] = #3fff 9999 9999 9999 999a
1241 = 1.20000000000000000004
1242 fI[0] == strtox
1243
1244
1245 Input: -1.2
1246
1247 strtox consumes 4 bytes and returns 41
1248 with bits = #bfff 9999 9999 9999 999a
1249 printf("%.21Lg") gives -1.20000000000000000004
1250 g_xfmt(0) gives 4 bytes: "-1.2"
1251
1252 strtoIx returns 41, consuming 4 bytes.
1253 fI[0] = #bfff 9999 9999 9999 999a
1254 = -1.20000000000000000004
1255 fI[1] = #bfff 9999 9999 9999 9999
1256 = -1.19999999999999999993
1257 fI[0] == strtox
1258
1259
1260 Input: 1.3
1261
1262 strtox consumes 3 bytes and returns 17
1263 with bits = #3fff a666 6666 6666 6666
1264 printf("%.21Lg") gives 1.29999999999999999996
1265 g_xfmt(0) gives 3 bytes: "1.3"
1266
1267 strtoIx returns 17, consuming 3 bytes.
1268 fI[0] = #3fff a666 6666 6666 6666
1269 = 1.29999999999999999996
1270 fI[1] = #3fff a666 6666 6666 6667
1271 = 1.30000000000000000007
1272 fI[0] == strtox
1273
1274
1275 Input: -1.3
1276
1277 strtox consumes 4 bytes and returns 41
1278 with bits = #bfff a666 6666 6666 6667
1279 printf("%.21Lg") gives -1.30000000000000000007
1280 g_xfmt(0) gives 22 bytes: "-1.3000000000000000001"
1281
1282 strtoIx returns 25, consuming 4 bytes.
1283 fI[0] = #bfff a666 6666 6666 6667
1284 = -1.30000000000000000007
1285 fI[1] = #bfff a666 6666 6666 6666
1286 = -1.29999999999999999996
1287 fI[0] == strtox
1288
1289
1290 Input: 1.4
1291
1292 strtox consumes 3 bytes and returns 17
1293 with bits = #3fff b333 3333 3333 3333
1294 printf("%.21Lg") gives 1.39999999999999999998
1295 g_xfmt(0) gives 3 bytes: "1.4"
1296
1297 strtoIx returns 17, consuming 3 bytes.
1298 fI[0] = #3fff b333 3333 3333 3333
1299 = 1.39999999999999999998
1300 fI[1] = #3fff b333 3333 3333 3334
1301 = 1.40000000000000000009
1302 fI[0] == strtox
1303
1304
1305 Input: -1.4
1306
1307 strtox consumes 4 bytes and returns 41
1308 with bits = #bfff b333 3333 3333 3334
1309 printf("%.21Lg") gives -1.40000000000000000009
1310 g_xfmt(0) gives 22 bytes: "-1.4000000000000000001"
1311
1312 strtoIx returns 25, consuming 4 bytes.
1313 fI[0] = #bfff b333 3333 3333 3334
1314 = -1.40000000000000000009
1315 fI[1] = #bfff b333 3333 3333 3333
1316 = -1.39999999999999999998
1317 fI[0] == strtox
1318
1319
1320 Input: 1.5
1321
1322 strtox consumes 3 bytes and returns 1
1323 with bits = #3fff c000 0 0 0
1324 printf("%.21Lg") gives 1.5
1325 g_xfmt(0) gives 3 bytes: "1.5"
1326
1327 strtoIx returns 1, consuming 3 bytes.
1328 fI[0] == fI[1] == strtox
1329
1330
1331 Input: -1.5
1332
1333 strtox consumes 4 bytes and returns 9
1334 with bits = #bfff c000 0 0 0
1335 printf("%.21Lg") gives -1.5
1336 g_xfmt(0) gives 4 bytes: "-1.5"
1337
1338 strtoIx returns 9, consuming 4 bytes.
1339 fI[0] == fI[1] == strtox
1340
1341
1342 Input: 1.6
1343
1344 strtox consumes 3 bytes and returns 17
1345 with bits = #3fff cccc cccc cccc cccc
1346 printf("%.21Lg") gives 1.59999999999999999991
1347 g_xfmt(0) gives 21 bytes: "1.5999999999999999999"
1348
1349 strtoIx returns 33, consuming 3 bytes.
1350 fI[0] = #3fff cccc cccc cccc cccc
1351 = 1.59999999999999999991
1352 fI[1] = #3fff cccc cccc cccc cccd
1353 = 1.60000000000000000002
1354 fI[0] == strtox
1355
1356
1357 Input: -1.6
1358
1359 strtox consumes 4 bytes and returns 41
1360 with bits = #bfff cccc cccc cccc cccd
1361 printf("%.21Lg") gives -1.60000000000000000002
1362 g_xfmt(0) gives 4 bytes: "-1.6"
1363
1364 strtoIx returns 41, consuming 4 bytes.
1365 fI[0] = #bfff cccc cccc cccc cccd
1366 = -1.60000000000000000002
1367 fI[1] = #bfff cccc cccc cccc cccc
1368 = -1.59999999999999999991
1369 fI[0] == strtox
1370
1371
1372 Input: 1.7
1373
1374 strtox consumes 3 bytes and returns 17
1375 with bits = #3fff d999 9999 9999 9999
1376 printf("%.21Lg") gives 1.69999999999999999993
1377 g_xfmt(0) gives 21 bytes: "1.6999999999999999999"
1378
1379 strtoIx returns 33, consuming 3 bytes.
1380 fI[0] = #3fff d999 9999 9999 9999
1381 = 1.69999999999999999993
1382 fI[1] = #3fff d999 9999 9999 999a
1383 = 1.70000000000000000004
1384 fI[0] == strtox
1385
1386
1387 Input: -1.7
1388
1389 strtox consumes 4 bytes and returns 41
1390 with bits = #bfff d999 9999 9999 999a
1391 printf("%.21Lg") gives -1.70000000000000000004
1392 g_xfmt(0) gives 4 bytes: "-1.7"
1393
1394 strtoIx returns 41, consuming 4 bytes.
1395 fI[0] = #bfff d999 9999 9999 999a
1396 = -1.70000000000000000004
1397 fI[1] = #bfff d999 9999 9999 9999
1398 = -1.69999999999999999993
1399 fI[0] == strtox
1400
1401
1402 Input: 1.8
1403
1404 strtox consumes 3 bytes and returns 17
1405 with bits = #3fff e666 6666 6666 6666
1406 printf("%.21Lg") gives 1.79999999999999999996
1407 g_xfmt(0) gives 3 bytes: "1.8"
1408
1409 strtoIx returns 17, consuming 3 bytes.
1410 fI[0] = #3fff e666 6666 6666 6666
1411 = 1.79999999999999999996
1412 fI[1] = #3fff e666 6666 6666 6667
1413 = 1.80000000000000000007
1414 fI[0] == strtox
1415
1416
1417 Input: -1.8
1418
1419 strtox consumes 4 bytes and returns 41
1420 with bits = #bfff e666 6666 6666 6667
1421 printf("%.21Lg") gives -1.80000000000000000007
1422 g_xfmt(0) gives 22 bytes: "-1.8000000000000000001"
1423
1424 strtoIx returns 25, consuming 4 bytes.
1425 fI[0] = #bfff e666 6666 6666 6667
1426 = -1.80000000000000000007
1427 fI[1] = #bfff e666 6666 6666 6666
1428 = -1.79999999999999999996
1429 fI[0] == strtox
1430
1431
1432 Input: 1.9
1433
1434 strtox consumes 3 bytes and returns 17
1435 with bits = #3fff f333 3333 3333 3333
1436 printf("%.21Lg") gives 1.89999999999999999998
1437 g_xfmt(0) gives 3 bytes: "1.9"
1438
1439 strtoIx returns 17, consuming 3 bytes.
1440 fI[0] = #3fff f333 3333 3333 3333
1441 = 1.89999999999999999998
1442 fI[1] = #3fff f333 3333 3333 3334
1443 = 1.90000000000000000009
1444 fI[0] == strtox
1445
1446
1447 Input: -1.9
1448
1449 strtox consumes 4 bytes and returns 41
1450 with bits = #bfff f333 3333 3333 3334
1451 printf("%.21Lg") gives -1.90000000000000000009
1452 g_xfmt(0) gives 22 bytes: "-1.9000000000000000001"
1453
1454 strtoIx returns 25, consuming 4 bytes.
1455 fI[0] = #bfff f333 3333 3333 3334
1456 = -1.90000000000000000009
1457 fI[1] = #bfff f333 3333 3333 3333
1458 = -1.89999999999999999998
1459 fI[0] == strtox
1460