VirtualBox

source: vbox/trunk/src/libs/softfloat-3e/testfloat/source/genLoops.c@ 107044

Last change on this file since 107044 was 94551, checked in by vboxsync, 3 years ago

libs/softfloat: Copied TestFloat-3e from vendor branch and to testfloat subdir. bugref:9898

  • Property svn:eol-style set to native
File size: 75.2 KB
Line 
1
2/*============================================================================
3
4This C source file is part of TestFloat, Release 3e, a package of programs for
5testing the correctness of floating-point arithmetic complying with the IEEE
6Standard for Floating-Point, by John R. Hauser.
7
8Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
9University of California. All rights reserved.
10
11Redistribution and use in source and binary forms, with or without
12modification, are permitted provided that the following conditions are met:
13
14 1. Redistributions of source code must retain the above copyright notice,
15 this list of conditions, and the following disclaimer.
16
17 2. Redistributions in binary form must reproduce the above copyright notice,
18 this list of conditions, and the following disclaimer in the documentation
19 and/or other materials provided with the distribution.
20
21 3. Neither the name of the University nor the names of its contributors may
22 be used to endorse or promote products derived from this software without
23 specific prior written permission.
24
25THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS "AS IS", AND ANY
26EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
27WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, ARE
28DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY
29DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
30(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
31LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
32ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
33(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
34SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
35
36=============================================================================*/
37
38#include <stdbool.h>
39#include <stdint.h>
40#include <stdio.h>
41#include <signal.h>
42#include "platform.h"
43#include "uint128.h"
44#include "fail.h"
45#include "softfloat.h"
46#include "genCases.h"
47#include "writeHex.h"
48#include "genLoops.h"
49
50volatile sig_atomic_t genLoops_stop = false;
51
52bool genLoops_forever;
53bool genLoops_givenCount;
54uint_fast64_t genLoops_count;
55uint_fast8_t *genLoops_trueFlagsPtr;
56
57#ifdef FLOAT16
58union ui16_f16 { uint16_t ui; float16_t f; };
59#endif
60union ui32_f32 { uint32_t ui; float32_t f; };
61#ifdef FLOAT64
62union ui64_f64 { uint64_t ui; float64_t f; };
63#endif
64
65static void checkEnoughCases( void )
66{
67
68 if ( genLoops_givenCount && (genLoops_count < genCases_total) ) {
69 if ( 2000000000 <= genCases_total ) {
70 fail(
71 "Too few cases; minimum is %lu%09lu",
72 (unsigned long) (genCases_total / 1000000000),
73 (unsigned long) (genCases_total % 1000000000)
74 );
75 } else {
76 fail(
77 "Too few cases; minimum is %lu", (unsigned long) genCases_total
78 );
79 }
80 }
81
82}
83
84static void writeGenOutput_flags( uint_fast8_t flags )
85{
86 uint_fast8_t commonFlags;
87
88 commonFlags = 0;
89 if ( flags & softfloat_flag_invalid ) commonFlags |= 0x10;
90 if ( flags & softfloat_flag_infinite ) commonFlags |= 0x08;
91 if ( flags & softfloat_flag_overflow ) commonFlags |= 0x04;
92 if ( flags & softfloat_flag_underflow ) commonFlags |= 0x02;
93 if ( flags & softfloat_flag_inexact ) commonFlags |= 0x01;
94 writeHex_ui8( commonFlags, '\n' );
95
96}
97
98static bool writeGenOutputs_bool( bool z, uint_fast8_t flags )
99{
100
101 writeHex_bool( z, ' ' );
102 writeGenOutput_flags( flags );
103 if ( genLoops_givenCount ) {
104 --genLoops_count;
105 if ( ! genLoops_count ) return true;
106 }
107 return false;
108
109}
110
111#ifdef FLOAT16
112
113static bool writeGenOutputs_ui16( uint_fast16_t z, uint_fast8_t flags )
114{
115
116 writeHex_ui16( z, ' ' );
117 writeGenOutput_flags( flags );
118 if ( genLoops_givenCount ) {
119 --genLoops_count;
120 if ( ! genLoops_count ) return true;
121 }
122 return false;
123
124}
125
126#endif
127
128static bool writeGenOutputs_ui32( uint_fast32_t z, uint_fast8_t flags )
129{
130
131 writeHex_ui32( z, ' ' );
132 writeGenOutput_flags( flags );
133 if ( genLoops_givenCount ) {
134 --genLoops_count;
135 if ( ! genLoops_count ) return true;
136 }
137 return false;
138
139}
140
141static bool writeGenOutputs_ui64( uint_fast64_t z, uint_fast8_t flags )
142{
143
144 writeHex_ui64( z, ' ' );
145 writeGenOutput_flags( flags );
146 if ( genLoops_givenCount ) {
147 --genLoops_count;
148 if ( ! genLoops_count ) return true;
149 }
150 return false;
151
152}
153
154#ifdef EXTFLOAT80
155
156static void writeHex_uiExtF80M( const extFloat80_t *aPtr, char sepChar )
157{
158 const struct extFloat80M *aSPtr;
159
160 aSPtr = (const struct extFloat80M *) aPtr;
161 writeHex_ui16( aSPtr->signExp, 0 );
162 writeHex_ui64( aSPtr->signif, sepChar );
163
164}
165
166static
167bool writeGenOutputs_extF80M( const extFloat80_t *aPtr, uint_fast8_t flags )
168{
169
170 writeHex_uiExtF80M( aPtr, ' ' );
171 writeGenOutput_flags( flags );
172 if ( genLoops_givenCount ) {
173 --genLoops_count;
174 if ( ! genLoops_count ) return true;
175 }
176 return false;
177
178}
179
180#endif
181
182#ifdef FLOAT128
183
184static void writeHex_uiF128M( const float128_t *aPtr, char sepChar )
185{
186 const struct uint128 *uiAPtr;
187
188 uiAPtr = (const struct uint128 *) aPtr;
189 writeHex_ui64( uiAPtr->v64, 0 );
190 writeHex_ui64( uiAPtr->v0, sepChar );
191
192}
193
194static bool writeGenOutputs_f128M( const float128_t *aPtr, uint_fast8_t flags )
195{
196
197 writeHex_uiF128M( aPtr, ' ' );
198 writeGenOutput_flags( flags );
199 if ( genLoops_givenCount ) {
200 --genLoops_count;
201 if ( ! genLoops_count ) return true;
202 }
203 return false;
204
205}
206
207#endif
208
209void gen_a_ui32( void )
210{
211
212 genCases_ui32_a_init();
213 checkEnoughCases();
214 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
215 genCases_ui32_a_next();
216 writeHex_ui32( genCases_ui32_a, '\n' );
217 if ( genLoops_givenCount ) {
218 --genLoops_count;
219 if ( ! genLoops_count ) break;
220 }
221 }
222
223}
224
225void gen_a_ui64( void )
226{
227
228 genCases_ui64_a_init();
229 checkEnoughCases();
230 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
231 genCases_ui64_a_next();
232 writeHex_ui64( genCases_ui64_a, '\n' );
233 if ( genLoops_givenCount ) {
234 --genLoops_count;
235 if ( ! genLoops_count ) break;
236 }
237 }
238
239}
240
241void gen_a_i32( void )
242{
243
244 genCases_i32_a_init();
245 checkEnoughCases();
246 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
247 genCases_i32_a_next();
248 writeHex_ui32( genCases_i32_a, '\n' );
249 if ( genLoops_givenCount ) {
250 --genLoops_count;
251 if ( ! genLoops_count ) break;
252 }
253 }
254
255}
256
257void gen_a_i64( void )
258{
259
260 genCases_i64_a_init();
261 checkEnoughCases();
262 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
263 genCases_i64_a_next();
264 writeHex_ui64( genCases_i64_a, '\n' );
265 if ( genLoops_givenCount ) {
266 --genLoops_count;
267 if ( ! genLoops_count ) break;
268 }
269 }
270
271}
272
273#ifdef FLOAT16
274
275void gen_a_f16( void )
276{
277 union ui16_f16 uA;
278
279 genCases_f16_a_init();
280 checkEnoughCases();
281 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
282 genCases_f16_a_next();
283 uA.f = genCases_f16_a;
284 writeHex_ui16( uA.ui, '\n' );
285 if ( genLoops_givenCount ) {
286 --genLoops_count;
287 if ( ! genLoops_count ) break;
288 }
289 }
290
291}
292
293void gen_ab_f16( void )
294{
295 union ui16_f16 u;
296
297 genCases_f16_ab_init();
298 checkEnoughCases();
299 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
300 genCases_f16_ab_next();
301 u.f = genCases_f16_a;
302 writeHex_ui16( u.ui, ' ' );
303 u.f = genCases_f16_b;
304 writeHex_ui16( u.ui, '\n' );
305 if ( genLoops_givenCount ) {
306 --genLoops_count;
307 if ( ! genLoops_count ) break;
308 }
309 }
310
311}
312
313void gen_abc_f16( void )
314{
315 union ui16_f16 u;
316
317 genCases_f16_abc_init();
318 checkEnoughCases();
319 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
320 genCases_f16_abc_next();
321 u.f = genCases_f16_a;
322 writeHex_ui16( u.ui, ' ' );
323 u.f = genCases_f16_b;
324 writeHex_ui16( u.ui, ' ' );
325 u.f = genCases_f16_c;
326 writeHex_ui16( u.ui, '\n' );
327 if ( genLoops_givenCount ) {
328 --genLoops_count;
329 if ( ! genLoops_count ) break;
330 }
331 }
332
333}
334
335#endif
336
337void gen_a_f32( void )
338{
339 union ui32_f32 uA;
340
341 genCases_f32_a_init();
342 checkEnoughCases();
343 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
344 genCases_f32_a_next();
345 uA.f = genCases_f32_a;
346 writeHex_ui32( uA.ui, '\n' );
347 if ( genLoops_givenCount ) {
348 --genLoops_count;
349 if ( ! genLoops_count ) break;
350 }
351 }
352
353}
354
355void gen_ab_f32( void )
356{
357 union ui32_f32 u;
358
359 genCases_f32_ab_init();
360 checkEnoughCases();
361 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
362 genCases_f32_ab_next();
363 u.f = genCases_f32_a;
364 writeHex_ui32( u.ui, ' ' );
365 u.f = genCases_f32_b;
366 writeHex_ui32( u.ui, '\n' );
367 if ( genLoops_givenCount ) {
368 --genLoops_count;
369 if ( ! genLoops_count ) break;
370 }
371 }
372
373}
374
375void gen_abc_f32( void )
376{
377 union ui32_f32 u;
378
379 genCases_f32_abc_init();
380 checkEnoughCases();
381 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
382 genCases_f32_abc_next();
383 u.f = genCases_f32_a;
384 writeHex_ui32( u.ui, ' ' );
385 u.f = genCases_f32_b;
386 writeHex_ui32( u.ui, ' ' );
387 u.f = genCases_f32_c;
388 writeHex_ui32( u.ui, '\n' );
389 if ( genLoops_givenCount ) {
390 --genLoops_count;
391 if ( ! genLoops_count ) break;
392 }
393 }
394
395}
396
397#ifdef FLOAT64
398
399void gen_a_f64( void )
400{
401 union ui64_f64 uA;
402
403 genCases_f64_a_init();
404 checkEnoughCases();
405 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
406 genCases_f64_a_next();
407 uA.f = genCases_f64_a;
408 writeHex_ui64( uA.ui, '\n' );
409 if ( genLoops_givenCount ) {
410 --genLoops_count;
411 if ( ! genLoops_count ) break;
412 }
413 }
414
415}
416
417void gen_ab_f64( void )
418{
419 union ui64_f64 u;
420
421 genCases_f64_ab_init();
422 checkEnoughCases();
423 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
424 genCases_f64_ab_next();
425 u.f = genCases_f64_a;
426 writeHex_ui64( u.ui, ' ' );
427 u.f = genCases_f64_b;
428 writeHex_ui64( u.ui, '\n' );
429 if ( genLoops_givenCount ) {
430 --genLoops_count;
431 if ( ! genLoops_count ) break;
432 }
433 }
434
435}
436
437void gen_abc_f64( void )
438{
439 union ui64_f64 u;
440
441 genCases_f64_abc_init();
442 checkEnoughCases();
443 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
444 genCases_f64_abc_next();
445 u.f = genCases_f64_a;
446 writeHex_ui64( u.ui, ' ' );
447 u.f = genCases_f64_b;
448 writeHex_ui64( u.ui, ' ' );
449 u.f = genCases_f64_c;
450 writeHex_ui64( u.ui, '\n' );
451 if ( genLoops_givenCount ) {
452 --genLoops_count;
453 if ( ! genLoops_count ) break;
454 }
455 }
456
457}
458
459#endif
460
461#ifdef EXTFLOAT80
462
463void gen_a_extF80( void )
464{
465
466 genCases_extF80_a_init();
467 checkEnoughCases();
468 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
469 genCases_extF80_a_next();
470 writeHex_uiExtF80M( &genCases_extF80_a, '\n' );
471 if ( genLoops_givenCount ) {
472 --genLoops_count;
473 if ( ! genLoops_count ) break;
474 }
475 }
476
477}
478
479void gen_ab_extF80( void )
480{
481
482 genCases_extF80_ab_init();
483 checkEnoughCases();
484 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
485 genCases_extF80_ab_next();
486 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
487 writeHex_uiExtF80M( &genCases_extF80_b, '\n' );
488 if ( genLoops_givenCount ) {
489 --genLoops_count;
490 if ( ! genLoops_count ) break;
491 }
492 }
493
494}
495
496void gen_abc_extF80( void )
497{
498
499 genCases_extF80_abc_init();
500 checkEnoughCases();
501 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
502 genCases_extF80_abc_next();
503 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
504 writeHex_uiExtF80M( &genCases_extF80_b, ' ' );
505 writeHex_uiExtF80M( &genCases_extF80_c, '\n' );
506 if ( genLoops_givenCount ) {
507 --genLoops_count;
508 if ( ! genLoops_count ) break;
509 }
510 }
511
512}
513
514#endif
515
516#ifdef FLOAT128
517
518void gen_a_f128( void )
519{
520
521 genCases_f128_a_init();
522 checkEnoughCases();
523 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
524 genCases_f128_a_next();
525 writeHex_uiF128M( &genCases_f128_a, '\n' );
526 if ( genLoops_givenCount ) {
527 --genLoops_count;
528 if ( ! genLoops_count ) break;
529 }
530 }
531
532}
533
534void gen_ab_f128( void )
535{
536
537 genCases_f128_ab_init();
538 checkEnoughCases();
539 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
540 genCases_f128_ab_next();
541 writeHex_uiF128M( &genCases_f128_a, ' ' );
542 writeHex_uiF128M( &genCases_f128_b, '\n' );
543 if ( genLoops_givenCount ) {
544 --genLoops_count;
545 if ( ! genLoops_count ) break;
546 }
547 }
548
549}
550
551void gen_abc_f128( void )
552{
553
554 genCases_f128_abc_init();
555 checkEnoughCases();
556 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
557 genCases_f128_abc_next();
558 writeHex_uiF128M( &genCases_f128_a, ' ' );
559 writeHex_uiF128M( &genCases_f128_b, ' ' );
560 writeHex_uiF128M( &genCases_f128_c, '\n' );
561 if ( genLoops_givenCount ) {
562 --genLoops_count;
563 if ( ! genLoops_count ) break;
564 }
565 }
566
567}
568
569#endif
570
571#ifdef FLOAT16
572
573void gen_a_ui32_z_f16( float16_t trueFunction( uint32_t ) )
574{
575 union ui16_f16 uTrueZ;
576 uint_fast8_t trueFlags;
577
578 genCases_ui32_a_init();
579 checkEnoughCases();
580 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
581 genCases_ui32_a_next();
582 writeHex_ui32( genCases_ui32_a, ' ' );
583 *genLoops_trueFlagsPtr = 0;
584 uTrueZ.f = trueFunction( genCases_ui32_a );
585 trueFlags = *genLoops_trueFlagsPtr;
586 if ( writeGenOutputs_ui16( uTrueZ.ui, trueFlags ) ) break;
587 }
588
589}
590
591#endif
592
593void gen_a_ui32_z_f32( float32_t trueFunction( uint32_t ) )
594{
595 union ui32_f32 uTrueZ;
596 uint_fast8_t trueFlags;
597
598 genCases_ui32_a_init();
599 checkEnoughCases();
600 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
601 genCases_ui32_a_next();
602 writeHex_ui32( genCases_ui32_a, ' ' );
603 *genLoops_trueFlagsPtr = 0;
604 uTrueZ.f = trueFunction( genCases_ui32_a );
605 trueFlags = *genLoops_trueFlagsPtr;
606 if ( writeGenOutputs_ui32( uTrueZ.ui, trueFlags ) ) break;
607 }
608
609}
610
611#ifdef FLOAT64
612
613void gen_a_ui32_z_f64( float64_t trueFunction( uint32_t ) )
614{
615 union ui64_f64 uTrueZ;
616 uint_fast8_t trueFlags;
617
618 genCases_ui32_a_init();
619 checkEnoughCases();
620 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
621 genCases_ui32_a_next();
622 writeHex_ui32( genCases_ui32_a, ' ' );
623 *genLoops_trueFlagsPtr = 0;
624 uTrueZ.f = trueFunction( genCases_ui32_a );
625 trueFlags = *genLoops_trueFlagsPtr;
626 if ( writeGenOutputs_ui64( uTrueZ.ui, trueFlags ) ) break;
627 }
628
629}
630
631#endif
632
633#ifdef EXTFLOAT80
634
635void gen_a_ui32_z_extF80( void trueFunction( uint32_t, extFloat80_t * ) )
636{
637 extFloat80_t trueZ;
638 uint_fast8_t trueFlags;
639
640 genCases_ui32_a_init();
641 checkEnoughCases();
642 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
643 genCases_ui32_a_next();
644 writeHex_ui32( genCases_ui32_a, ' ' );
645 *genLoops_trueFlagsPtr = 0;
646 trueFunction( genCases_ui32_a, &trueZ );
647 trueFlags = *genLoops_trueFlagsPtr;
648 if ( writeGenOutputs_extF80M( &trueZ, trueFlags ) ) break;
649 }
650
651}
652
653#endif
654
655#ifdef FLOAT128
656
657void gen_a_ui32_z_f128( void trueFunction( uint32_t, float128_t * ) )
658{
659 float128_t trueZ;
660 uint_fast8_t trueFlags;
661
662 genCases_ui32_a_init();
663 checkEnoughCases();
664 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
665 genCases_ui32_a_next();
666 writeHex_ui32( genCases_ui32_a, ' ' );
667 *genLoops_trueFlagsPtr = 0;
668 trueFunction( genCases_ui32_a, &trueZ );
669 trueFlags = *genLoops_trueFlagsPtr;
670 if ( writeGenOutputs_f128M( &trueZ, trueFlags ) ) break;
671 }
672
673}
674
675#endif
676
677#ifdef FLOAT16
678
679void gen_a_ui64_z_f16( float16_t trueFunction( uint64_t ) )
680{
681 union ui16_f16 uTrueZ;
682 uint_fast8_t trueFlags;
683
684 genCases_ui64_a_init();
685 checkEnoughCases();
686 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
687 genCases_ui64_a_next();
688 writeHex_ui64( genCases_ui64_a, ' ' );
689 *genLoops_trueFlagsPtr = 0;
690 uTrueZ.f = trueFunction( genCases_ui64_a );
691 trueFlags = *genLoops_trueFlagsPtr;
692 if ( writeGenOutputs_ui16( uTrueZ.ui, trueFlags ) ) break;
693 }
694
695}
696
697#endif
698
699void gen_a_ui64_z_f32( float32_t trueFunction( uint64_t ) )
700{
701 union ui32_f32 uTrueZ;
702 uint_fast8_t trueFlags;
703
704 genCases_ui64_a_init();
705 checkEnoughCases();
706 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
707 genCases_ui64_a_next();
708 writeHex_ui64( genCases_ui64_a, ' ' );
709 *genLoops_trueFlagsPtr = 0;
710 uTrueZ.f = trueFunction( genCases_ui64_a );
711 trueFlags = *genLoops_trueFlagsPtr;
712 if ( writeGenOutputs_ui32( uTrueZ.ui, trueFlags ) ) break;
713 }
714
715}
716
717#ifdef FLOAT64
718
719void gen_a_ui64_z_f64( float64_t trueFunction( uint64_t ) )
720{
721 union ui64_f64 uTrueZ;
722 uint_fast8_t trueFlags;
723
724 genCases_ui64_a_init();
725 checkEnoughCases();
726 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
727 genCases_ui64_a_next();
728 writeHex_ui64( genCases_ui64_a, ' ' );
729 *genLoops_trueFlagsPtr = 0;
730 uTrueZ.f = trueFunction( genCases_ui64_a );
731 trueFlags = *genLoops_trueFlagsPtr;
732 if ( writeGenOutputs_ui64( uTrueZ.ui, trueFlags ) ) break;
733 }
734
735}
736
737#endif
738
739#ifdef EXTFLOAT80
740
741void gen_a_ui64_z_extF80( void trueFunction( uint64_t, extFloat80_t * ) )
742{
743 extFloat80_t trueZ;
744 uint_fast8_t trueFlags;
745
746 genCases_ui64_a_init();
747 checkEnoughCases();
748 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
749 genCases_ui64_a_next();
750 writeHex_ui64( genCases_ui64_a, ' ' );
751 *genLoops_trueFlagsPtr = 0;
752 trueFunction( genCases_ui64_a, &trueZ );
753 trueFlags = *genLoops_trueFlagsPtr;
754 if ( writeGenOutputs_extF80M( &trueZ, trueFlags ) ) break;
755 }
756
757}
758
759#endif
760
761#ifdef FLOAT128
762
763void gen_a_ui64_z_f128( void trueFunction( uint64_t, float128_t * ) )
764{
765 float128_t trueZ;
766 uint_fast8_t trueFlags;
767
768 genCases_ui64_a_init();
769 checkEnoughCases();
770 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
771 genCases_ui64_a_next();
772 writeHex_ui64( genCases_ui64_a, ' ' );
773 *genLoops_trueFlagsPtr = 0;
774 trueFunction( genCases_ui64_a, &trueZ );
775 trueFlags = *genLoops_trueFlagsPtr;
776 if ( writeGenOutputs_f128M( &trueZ, trueFlags ) ) break;
777 }
778
779}
780
781#endif
782
783#ifdef FLOAT16
784
785void gen_a_i32_z_f16( float16_t trueFunction( int32_t ) )
786{
787 union ui16_f16 uTrueZ;
788 uint_fast8_t trueFlags;
789
790 genCases_i32_a_init();
791 checkEnoughCases();
792 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
793 genCases_i32_a_next();
794 writeHex_ui32( genCases_i32_a, ' ' );
795 *genLoops_trueFlagsPtr = 0;
796 uTrueZ.f = trueFunction( genCases_i32_a );
797 trueFlags = *genLoops_trueFlagsPtr;
798 if ( writeGenOutputs_ui16( uTrueZ.ui, trueFlags ) ) break;
799 }
800
801}
802
803#endif
804
805void gen_a_i32_z_f32( float32_t trueFunction( int32_t ) )
806{
807 union ui32_f32 uTrueZ;
808 uint_fast8_t trueFlags;
809
810 genCases_i32_a_init();
811 checkEnoughCases();
812 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
813 genCases_i32_a_next();
814 writeHex_ui32( genCases_i32_a, ' ' );
815 *genLoops_trueFlagsPtr = 0;
816 uTrueZ.f = trueFunction( genCases_i32_a );
817 trueFlags = *genLoops_trueFlagsPtr;
818 if ( writeGenOutputs_ui32( uTrueZ.ui, trueFlags ) ) break;
819 }
820
821}
822
823#ifdef FLOAT64
824
825void gen_a_i32_z_f64( float64_t trueFunction( int32_t ) )
826{
827 union ui64_f64 uTrueZ;
828 uint_fast8_t trueFlags;
829
830 genCases_i32_a_init();
831 checkEnoughCases();
832 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
833 genCases_i32_a_next();
834 writeHex_ui32( genCases_i32_a, ' ' );
835 *genLoops_trueFlagsPtr = 0;
836 uTrueZ.f = trueFunction( genCases_i32_a );
837 trueFlags = *genLoops_trueFlagsPtr;
838 if ( writeGenOutputs_ui64( uTrueZ.ui, trueFlags ) ) break;
839 }
840
841}
842
843#endif
844
845#ifdef EXTFLOAT80
846
847void gen_a_i32_z_extF80( void trueFunction( int32_t, extFloat80_t * ) )
848{
849 extFloat80_t trueZ;
850 uint_fast8_t trueFlags;
851
852 genCases_i32_a_init();
853 checkEnoughCases();
854 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
855 genCases_i32_a_next();
856 writeHex_ui32( genCases_i32_a, ' ' );
857 *genLoops_trueFlagsPtr = 0;
858 trueFunction( genCases_i32_a, &trueZ );
859 trueFlags = *genLoops_trueFlagsPtr;
860 if ( writeGenOutputs_extF80M( &trueZ, trueFlags ) ) break;
861 }
862
863}
864
865#endif
866
867#ifdef FLOAT128
868
869void gen_a_i32_z_f128( void trueFunction( int32_t, float128_t * ) )
870{
871 float128_t trueZ;
872 uint_fast8_t trueFlags;
873
874 genCases_i32_a_init();
875 checkEnoughCases();
876 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
877 genCases_i32_a_next();
878 writeHex_ui32( genCases_i32_a, ' ' );
879 *genLoops_trueFlagsPtr = 0;
880 trueFunction( genCases_i32_a, &trueZ );
881 trueFlags = *genLoops_trueFlagsPtr;
882 if ( writeGenOutputs_f128M( &trueZ, trueFlags ) ) break;
883 }
884
885}
886
887#endif
888
889#ifdef FLOAT16
890
891void gen_a_i64_z_f16( float16_t trueFunction( int64_t ) )
892{
893 union ui16_f16 uTrueZ;
894 uint_fast8_t trueFlags;
895
896 genCases_i64_a_init();
897 checkEnoughCases();
898 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
899 genCases_i64_a_next();
900 writeHex_ui64( genCases_i64_a, ' ' );
901 *genLoops_trueFlagsPtr = 0;
902 uTrueZ.f = trueFunction( genCases_i64_a );
903 trueFlags = *genLoops_trueFlagsPtr;
904 if ( writeGenOutputs_ui16( uTrueZ.ui, trueFlags ) ) break;
905 }
906
907}
908
909#endif
910
911void gen_a_i64_z_f32( float32_t trueFunction( int64_t ) )
912{
913 union ui32_f32 uTrueZ;
914 uint_fast8_t trueFlags;
915
916 genCases_i64_a_init();
917 checkEnoughCases();
918 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
919 genCases_i64_a_next();
920 writeHex_ui64( genCases_i64_a, ' ' );
921 *genLoops_trueFlagsPtr = 0;
922 uTrueZ.f = trueFunction( genCases_i64_a );
923 trueFlags = *genLoops_trueFlagsPtr;
924 if ( writeGenOutputs_ui32( uTrueZ.ui, trueFlags ) ) break;
925 }
926
927}
928
929#ifdef FLOAT64
930
931void gen_a_i64_z_f64( float64_t trueFunction( int64_t ) )
932{
933 union ui64_f64 uTrueZ;
934 uint_fast8_t trueFlags;
935
936 genCases_i64_a_init();
937 checkEnoughCases();
938 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
939 genCases_i64_a_next();
940 writeHex_ui64( genCases_i64_a, ' ' );
941 *genLoops_trueFlagsPtr = 0;
942 uTrueZ.f = trueFunction( genCases_i64_a );
943 trueFlags = *genLoops_trueFlagsPtr;
944 if ( writeGenOutputs_ui64( uTrueZ.ui, trueFlags ) ) break;
945 }
946
947}
948
949#endif
950
951#ifdef EXTFLOAT80
952
953void gen_a_i64_z_extF80( void trueFunction( int64_t, extFloat80_t * ) )
954{
955 extFloat80_t trueZ;
956 uint_fast8_t trueFlags;
957
958 genCases_i64_a_init();
959 checkEnoughCases();
960 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
961 genCases_i64_a_next();
962 writeHex_ui64( genCases_i64_a, ' ' );
963 *genLoops_trueFlagsPtr = 0;
964 trueFunction( genCases_i64_a, &trueZ );
965 trueFlags = *genLoops_trueFlagsPtr;
966 if ( writeGenOutputs_extF80M( &trueZ, trueFlags ) ) break;
967 }
968
969}
970
971#endif
972
973#ifdef FLOAT128
974
975void gen_a_i64_z_f128( void trueFunction( int64_t, float128_t * ) )
976{
977 float128_t trueZ;
978 uint_fast8_t trueFlags;
979
980 genCases_i64_a_init();
981 checkEnoughCases();
982 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
983 genCases_i64_a_next();
984 writeHex_ui64( genCases_i64_a, ' ' );
985 *genLoops_trueFlagsPtr = 0;
986 trueFunction( genCases_i64_a, &trueZ );
987 trueFlags = *genLoops_trueFlagsPtr;
988 if ( writeGenOutputs_f128M( &trueZ, trueFlags ) ) break;
989 }
990
991}
992
993#endif
994
995#ifdef FLOAT16
996
997void
998 gen_a_f16_z_ui32_rx(
999 uint_fast32_t trueFunction( float16_t, uint_fast8_t, bool ),
1000 uint_fast8_t roundingMode,
1001 bool exact
1002 )
1003{
1004 union ui16_f16 uA;
1005 uint_fast32_t trueZ;
1006 uint_fast8_t trueFlags;
1007
1008 genCases_f16_a_init();
1009 checkEnoughCases();
1010 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1011 genCases_f16_a_next();
1012 uA.f = genCases_f16_a;
1013 writeHex_ui16( uA.ui, ' ' );
1014 *genLoops_trueFlagsPtr = 0;
1015 trueZ = trueFunction( genCases_f16_a, roundingMode, exact );
1016 trueFlags = *genLoops_trueFlagsPtr;
1017 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
1018 }
1019
1020}
1021
1022void
1023 gen_a_f16_z_ui64_rx(
1024 uint_fast64_t trueFunction( float16_t, uint_fast8_t, bool ),
1025 uint_fast8_t roundingMode,
1026 bool exact
1027 )
1028{
1029 union ui16_f16 uA;
1030 uint_fast64_t trueZ;
1031 uint_fast8_t trueFlags;
1032
1033 genCases_f16_a_init();
1034 checkEnoughCases();
1035 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1036 genCases_f16_a_next();
1037 uA.f = genCases_f16_a;
1038 writeHex_ui16( uA.ui, ' ' );
1039 *genLoops_trueFlagsPtr = 0;
1040 trueZ = trueFunction( genCases_f16_a, roundingMode, exact );
1041 trueFlags = *genLoops_trueFlagsPtr;
1042 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
1043 }
1044
1045}
1046
1047void
1048 gen_a_f16_z_i32_rx(
1049 int_fast32_t trueFunction( float16_t, uint_fast8_t, bool ),
1050 uint_fast8_t roundingMode,
1051 bool exact
1052 )
1053{
1054 union ui16_f16 uA;
1055 int_fast32_t trueZ;
1056 uint_fast8_t trueFlags;
1057
1058 genCases_f16_a_init();
1059 checkEnoughCases();
1060 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1061 genCases_f16_a_next();
1062 uA.f = genCases_f16_a;
1063 writeHex_ui16( uA.ui, ' ' );
1064 *genLoops_trueFlagsPtr = 0;
1065 trueZ = trueFunction( genCases_f16_a, roundingMode, exact );
1066 trueFlags = *genLoops_trueFlagsPtr;
1067 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
1068 }
1069
1070}
1071
1072void
1073 gen_a_f16_z_i64_rx(
1074 int_fast64_t trueFunction( float16_t, uint_fast8_t, bool ),
1075 uint_fast8_t roundingMode,
1076 bool exact
1077 )
1078{
1079 union ui16_f16 uA;
1080 int_fast64_t trueZ;
1081 uint_fast8_t trueFlags;
1082
1083 genCases_f16_a_init();
1084 checkEnoughCases();
1085 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1086 genCases_f16_a_next();
1087 uA.f = genCases_f16_a;
1088 writeHex_ui16( uA.ui, ' ' );
1089 *genLoops_trueFlagsPtr = 0;
1090 trueZ = trueFunction( genCases_f16_a, roundingMode, exact );
1091 trueFlags = *genLoops_trueFlagsPtr;
1092 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
1093 }
1094
1095}
1096
1097void
1098 gen_a_f16_z_ui32_x(
1099 uint_fast32_t trueFunction( float16_t, bool ), bool exact )
1100{
1101 union ui16_f16 uA;
1102 uint_fast32_t trueZ;
1103 uint_fast8_t trueFlags;
1104
1105 genCases_f16_a_init();
1106 checkEnoughCases();
1107 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1108 genCases_f16_a_next();
1109 uA.f = genCases_f16_a;
1110 writeHex_ui16( uA.ui, ' ' );
1111 *genLoops_trueFlagsPtr = 0;
1112 trueZ = trueFunction( genCases_f16_a, exact );
1113 trueFlags = *genLoops_trueFlagsPtr;
1114 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
1115 }
1116
1117}
1118
1119void
1120 gen_a_f16_z_ui64_x(
1121 uint_fast64_t trueFunction( float16_t, bool ), bool exact )
1122{
1123 union ui16_f16 uA;
1124 uint_fast64_t trueZ;
1125 uint_fast8_t trueFlags;
1126
1127 genCases_f16_a_init();
1128 checkEnoughCases();
1129 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1130 genCases_f16_a_next();
1131 uA.f = genCases_f16_a;
1132 writeHex_ui16( uA.ui, ' ' );
1133 *genLoops_trueFlagsPtr = 0;
1134 trueZ = trueFunction( genCases_f16_a, exact );
1135 trueFlags = *genLoops_trueFlagsPtr;
1136 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
1137 }
1138
1139}
1140
1141void
1142 gen_a_f16_z_i32_x( int_fast32_t trueFunction( float16_t, bool ), bool exact )
1143{
1144 union ui16_f16 uA;
1145 int_fast32_t trueZ;
1146 uint_fast8_t trueFlags;
1147
1148 genCases_f16_a_init();
1149 checkEnoughCases();
1150 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1151 genCases_f16_a_next();
1152 uA.f = genCases_f16_a;
1153 writeHex_ui16( uA.ui, ' ' );
1154 *genLoops_trueFlagsPtr = 0;
1155 trueZ = trueFunction( genCases_f16_a, exact );
1156 trueFlags = *genLoops_trueFlagsPtr;
1157 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
1158 }
1159
1160}
1161
1162void
1163 gen_a_f16_z_i64_x( int_fast64_t trueFunction( float16_t, bool ), bool exact )
1164{
1165 union ui16_f16 uA;
1166 int_fast64_t trueZ;
1167 uint_fast8_t trueFlags;
1168
1169 genCases_f16_a_init();
1170 checkEnoughCases();
1171 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1172 genCases_f16_a_next();
1173 uA.f = genCases_f16_a;
1174 writeHex_ui16( uA.ui, ' ' );
1175 *genLoops_trueFlagsPtr = 0;
1176 trueZ = trueFunction( genCases_f16_a, exact );
1177 trueFlags = *genLoops_trueFlagsPtr;
1178 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
1179 }
1180
1181}
1182
1183void gen_a_f16_z_f32( float32_t trueFunction( float16_t ) )
1184{
1185 union ui16_f16 uA;
1186 union ui32_f32 uTrueZ;
1187 uint_fast8_t trueFlags;
1188
1189 genCases_f16_a_init();
1190 checkEnoughCases();
1191 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1192 genCases_f16_a_next();
1193 uA.f = genCases_f16_a;
1194 writeHex_ui16( uA.ui, ' ' );
1195 *genLoops_trueFlagsPtr = 0;
1196 uTrueZ.f = trueFunction( genCases_f16_a );
1197 trueFlags = *genLoops_trueFlagsPtr;
1198 if ( writeGenOutputs_ui32( uTrueZ.ui, trueFlags ) ) break;
1199 }
1200
1201}
1202
1203#ifdef FLOAT64
1204
1205void gen_a_f16_z_f64( float64_t trueFunction( float16_t ) )
1206{
1207 union ui16_f16 uA;
1208 union ui64_f64 uTrueZ;
1209 uint_fast8_t trueFlags;
1210
1211 genCases_f16_a_init();
1212 checkEnoughCases();
1213 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1214 genCases_f16_a_next();
1215 uA.f = genCases_f16_a;
1216 writeHex_ui16( uA.ui, ' ' );
1217 *genLoops_trueFlagsPtr = 0;
1218 uTrueZ.f = trueFunction( genCases_f16_a );
1219 trueFlags = *genLoops_trueFlagsPtr;
1220 if ( writeGenOutputs_ui64( uTrueZ.ui, trueFlags ) ) break;
1221 }
1222
1223}
1224
1225#endif
1226
1227#ifdef EXTFLOAT80
1228
1229void gen_a_f16_z_extF80( void trueFunction( float16_t, extFloat80_t * ) )
1230{
1231 union ui16_f16 uA;
1232 extFloat80_t trueZ;
1233 uint_fast8_t trueFlags;
1234
1235 genCases_f16_a_init();
1236 checkEnoughCases();
1237 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1238 genCases_f16_a_next();
1239 uA.f = genCases_f16_a;
1240 writeHex_ui16( uA.ui, ' ' );
1241 *genLoops_trueFlagsPtr = 0;
1242 trueFunction( genCases_f16_a, &trueZ );
1243 trueFlags = *genLoops_trueFlagsPtr;
1244 if ( writeGenOutputs_extF80M( &trueZ, trueFlags ) ) break;
1245 }
1246
1247}
1248
1249#endif
1250
1251#ifdef FLOAT128
1252
1253void gen_a_f16_z_f128( void trueFunction( float16_t, float128_t * ) )
1254{
1255 union ui16_f16 uA;
1256 float128_t trueZ;
1257 uint_fast8_t trueFlags;
1258
1259 genCases_f16_a_init();
1260 checkEnoughCases();
1261 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1262 genCases_f16_a_next();
1263 uA.f = genCases_f16_a;
1264 writeHex_ui16( uA.ui, ' ' );
1265 *genLoops_trueFlagsPtr = 0;
1266 trueFunction( genCases_f16_a, &trueZ );
1267 trueFlags = *genLoops_trueFlagsPtr;
1268 if ( writeGenOutputs_f128M( &trueZ, trueFlags ) ) break;
1269 }
1270
1271}
1272
1273#endif
1274
1275void gen_az_f16( float16_t trueFunction( float16_t ) )
1276{
1277 union ui16_f16 u;
1278 uint_fast8_t trueFlags;
1279
1280 genCases_f16_a_init();
1281 checkEnoughCases();
1282 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1283 genCases_f16_a_next();
1284 u.f = genCases_f16_a;
1285 writeHex_ui16( u.ui, ' ' );
1286 *genLoops_trueFlagsPtr = 0;
1287 u.f = trueFunction( genCases_f16_a );
1288 trueFlags = *genLoops_trueFlagsPtr;
1289 if ( writeGenOutputs_ui16( u.ui, trueFlags ) ) break;
1290 }
1291
1292}
1293
1294void
1295 gen_az_f16_rx(
1296 float16_t trueFunction( float16_t, uint_fast8_t, bool ),
1297 uint_fast8_t roundingMode,
1298 bool exact
1299 )
1300{
1301 union ui16_f16 u;
1302 uint_fast8_t trueFlags;
1303
1304 genCases_f16_a_init();
1305 checkEnoughCases();
1306 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1307 genCases_f16_a_next();
1308 u.f = genCases_f16_a;
1309 writeHex_ui16( u.ui, ' ' );
1310 *genLoops_trueFlagsPtr = 0;
1311 u.f = trueFunction( genCases_f16_a, roundingMode, exact );
1312 trueFlags = *genLoops_trueFlagsPtr;
1313 if ( writeGenOutputs_ui16( u.ui, trueFlags ) ) break;
1314 }
1315
1316}
1317
1318void gen_abz_f16( float16_t trueFunction( float16_t, float16_t ) )
1319{
1320 union ui16_f16 u;
1321 uint_fast8_t trueFlags;
1322
1323 genCases_f16_ab_init();
1324 checkEnoughCases();
1325 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1326 genCases_f16_ab_next();
1327 u.f = genCases_f16_a;
1328 writeHex_ui16( u.ui, ' ' );
1329 u.f = genCases_f16_b;
1330 writeHex_ui16( u.ui, ' ' );
1331 *genLoops_trueFlagsPtr = 0;
1332 u.f = trueFunction( genCases_f16_a, genCases_f16_b );
1333 trueFlags = *genLoops_trueFlagsPtr;
1334 if ( writeGenOutputs_ui16( u.ui, trueFlags ) ) break;
1335 }
1336
1337}
1338
1339void gen_abcz_f16( float16_t trueFunction( float16_t, float16_t, float16_t ) )
1340{
1341 union ui16_f16 u;
1342 uint_fast8_t trueFlags;
1343
1344 genCases_f16_abc_init();
1345 checkEnoughCases();
1346 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1347 genCases_f16_abc_next();
1348 u.f = genCases_f16_a;
1349 writeHex_ui16( u.ui, ' ' );
1350 u.f = genCases_f16_b;
1351 writeHex_ui16( u.ui, ' ' );
1352 u.f = genCases_f16_c;
1353 writeHex_ui16( u.ui, ' ' );
1354 *genLoops_trueFlagsPtr = 0;
1355 u.f = trueFunction( genCases_f16_a, genCases_f16_b, genCases_f16_c );
1356 trueFlags = *genLoops_trueFlagsPtr;
1357 if ( writeGenOutputs_ui16( u.ui, trueFlags ) ) break;
1358 }
1359
1360}
1361
1362void gen_ab_f16_z_bool( bool trueFunction( float16_t, float16_t ) )
1363{
1364 union ui16_f16 u;
1365 bool trueZ;
1366 uint_fast8_t trueFlags;
1367
1368 genCases_f16_ab_init();
1369 checkEnoughCases();
1370 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1371 genCases_f16_ab_next();
1372 u.f = genCases_f16_a;
1373 writeHex_ui16( u.ui, ' ' );
1374 u.f = genCases_f16_b;
1375 writeHex_ui16( u.ui, ' ' );
1376 *genLoops_trueFlagsPtr = 0;
1377 trueZ = trueFunction( genCases_f16_a, genCases_f16_b );
1378 trueFlags = *genLoops_trueFlagsPtr;
1379 if ( writeGenOutputs_bool( trueZ, trueFlags ) ) break;
1380 }
1381
1382}
1383
1384#endif
1385
1386void
1387 gen_a_f32_z_ui32_rx(
1388 uint_fast32_t trueFunction( float32_t, uint_fast8_t, bool ),
1389 uint_fast8_t roundingMode,
1390 bool exact
1391 )
1392{
1393 union ui32_f32 uA;
1394 uint_fast32_t trueZ;
1395 uint_fast8_t trueFlags;
1396
1397 genCases_f32_a_init();
1398 checkEnoughCases();
1399 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1400 genCases_f32_a_next();
1401 uA.f = genCases_f32_a;
1402 writeHex_ui32( uA.ui, ' ' );
1403 *genLoops_trueFlagsPtr = 0;
1404 trueZ = trueFunction( genCases_f32_a, roundingMode, exact );
1405 trueFlags = *genLoops_trueFlagsPtr;
1406 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
1407 }
1408
1409}
1410
1411void
1412 gen_a_f32_z_ui64_rx(
1413 uint_fast64_t trueFunction( float32_t, uint_fast8_t, bool ),
1414 uint_fast8_t roundingMode,
1415 bool exact
1416 )
1417{
1418 union ui32_f32 uA;
1419 uint_fast64_t trueZ;
1420 uint_fast8_t trueFlags;
1421
1422 genCases_f32_a_init();
1423 checkEnoughCases();
1424 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1425 genCases_f32_a_next();
1426 uA.f = genCases_f32_a;
1427 writeHex_ui32( uA.ui, ' ' );
1428 *genLoops_trueFlagsPtr = 0;
1429 trueZ = trueFunction( genCases_f32_a, roundingMode, exact );
1430 trueFlags = *genLoops_trueFlagsPtr;
1431 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
1432 }
1433
1434}
1435
1436void
1437 gen_a_f32_z_i32_rx(
1438 int_fast32_t trueFunction( float32_t, uint_fast8_t, bool ),
1439 uint_fast8_t roundingMode,
1440 bool exact
1441 )
1442{
1443 union ui32_f32 uA;
1444 int_fast32_t trueZ;
1445 uint_fast8_t trueFlags;
1446
1447 genCases_f32_a_init();
1448 checkEnoughCases();
1449 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1450 genCases_f32_a_next();
1451 uA.f = genCases_f32_a;
1452 writeHex_ui32( uA.ui, ' ' );
1453 *genLoops_trueFlagsPtr = 0;
1454 trueZ = trueFunction( genCases_f32_a, roundingMode, exact );
1455 trueFlags = *genLoops_trueFlagsPtr;
1456 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
1457 }
1458
1459}
1460
1461void
1462 gen_a_f32_z_i64_rx(
1463 int_fast64_t trueFunction( float32_t, uint_fast8_t, bool ),
1464 uint_fast8_t roundingMode,
1465 bool exact
1466 )
1467{
1468 union ui32_f32 uA;
1469 int_fast64_t trueZ;
1470 uint_fast8_t trueFlags;
1471
1472 genCases_f32_a_init();
1473 checkEnoughCases();
1474 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1475 genCases_f32_a_next();
1476 uA.f = genCases_f32_a;
1477 writeHex_ui32( uA.ui, ' ' );
1478 *genLoops_trueFlagsPtr = 0;
1479 trueZ = trueFunction( genCases_f32_a, roundingMode, exact );
1480 trueFlags = *genLoops_trueFlagsPtr;
1481 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
1482 }
1483
1484}
1485
1486void
1487 gen_a_f32_z_ui32_x(
1488 uint_fast32_t trueFunction( float32_t, bool ), bool exact )
1489{
1490 union ui32_f32 uA;
1491 uint_fast32_t trueZ;
1492 uint_fast8_t trueFlags;
1493
1494 genCases_f32_a_init();
1495 checkEnoughCases();
1496 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1497 genCases_f32_a_next();
1498 uA.f = genCases_f32_a;
1499 writeHex_ui32( uA.ui, ' ' );
1500 *genLoops_trueFlagsPtr = 0;
1501 trueZ = trueFunction( genCases_f32_a, exact );
1502 trueFlags = *genLoops_trueFlagsPtr;
1503 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
1504 }
1505
1506}
1507
1508void
1509 gen_a_f32_z_ui64_x(
1510 uint_fast64_t trueFunction( float32_t, bool ), bool exact )
1511{
1512 union ui32_f32 uA;
1513 uint_fast64_t trueZ;
1514 uint_fast8_t trueFlags;
1515
1516 genCases_f32_a_init();
1517 checkEnoughCases();
1518 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1519 genCases_f32_a_next();
1520 uA.f = genCases_f32_a;
1521 writeHex_ui32( uA.ui, ' ' );
1522 *genLoops_trueFlagsPtr = 0;
1523 trueZ = trueFunction( genCases_f32_a, exact );
1524 trueFlags = *genLoops_trueFlagsPtr;
1525 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
1526 }
1527
1528}
1529
1530void
1531 gen_a_f32_z_i32_x( int_fast32_t trueFunction( float32_t, bool ), bool exact )
1532{
1533 union ui32_f32 uA;
1534 int_fast32_t trueZ;
1535 uint_fast8_t trueFlags;
1536
1537 genCases_f32_a_init();
1538 checkEnoughCases();
1539 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1540 genCases_f32_a_next();
1541 uA.f = genCases_f32_a;
1542 writeHex_ui32( uA.ui, ' ' );
1543 *genLoops_trueFlagsPtr = 0;
1544 trueZ = trueFunction( genCases_f32_a, exact );
1545 trueFlags = *genLoops_trueFlagsPtr;
1546 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
1547 }
1548
1549}
1550
1551void
1552 gen_a_f32_z_i64_x( int_fast64_t trueFunction( float32_t, bool ), bool exact )
1553{
1554 union ui32_f32 uA;
1555 int_fast64_t trueZ;
1556 uint_fast8_t trueFlags;
1557
1558 genCases_f32_a_init();
1559 checkEnoughCases();
1560 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1561 genCases_f32_a_next();
1562 uA.f = genCases_f32_a;
1563 writeHex_ui32( uA.ui, ' ' );
1564 *genLoops_trueFlagsPtr = 0;
1565 trueZ = trueFunction( genCases_f32_a, exact );
1566 trueFlags = *genLoops_trueFlagsPtr;
1567 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
1568 }
1569
1570}
1571
1572#ifdef FLOAT16
1573
1574void gen_a_f32_z_f16( float16_t trueFunction( float32_t ) )
1575{
1576 union ui32_f32 uA;
1577 union ui16_f16 uTrueZ;
1578 uint_fast8_t trueFlags;
1579
1580 genCases_f32_a_init();
1581 checkEnoughCases();
1582 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1583 genCases_f32_a_next();
1584 uA.f = genCases_f32_a;
1585 writeHex_ui32( uA.ui, ' ' );
1586 *genLoops_trueFlagsPtr = 0;
1587 uTrueZ.f = trueFunction( genCases_f32_a );
1588 trueFlags = *genLoops_trueFlagsPtr;
1589 if ( writeGenOutputs_ui16( uTrueZ.ui, trueFlags ) ) break;
1590 }
1591
1592}
1593
1594#endif
1595
1596#ifdef FLOAT64
1597
1598void gen_a_f32_z_f64( float64_t trueFunction( float32_t ) )
1599{
1600 union ui32_f32 uA;
1601 union ui64_f64 uTrueZ;
1602 uint_fast8_t trueFlags;
1603
1604 genCases_f32_a_init();
1605 checkEnoughCases();
1606 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1607 genCases_f32_a_next();
1608 uA.f = genCases_f32_a;
1609 writeHex_ui32( uA.ui, ' ' );
1610 *genLoops_trueFlagsPtr = 0;
1611 uTrueZ.f = trueFunction( genCases_f32_a );
1612 trueFlags = *genLoops_trueFlagsPtr;
1613 if ( writeGenOutputs_ui64( uTrueZ.ui, trueFlags ) ) break;
1614 }
1615
1616}
1617
1618#endif
1619
1620#ifdef EXTFLOAT80
1621
1622void gen_a_f32_z_extF80( void trueFunction( float32_t, extFloat80_t * ) )
1623{
1624 union ui32_f32 uA;
1625 extFloat80_t trueZ;
1626 uint_fast8_t trueFlags;
1627
1628 genCases_f32_a_init();
1629 checkEnoughCases();
1630 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1631 genCases_f32_a_next();
1632 uA.f = genCases_f32_a;
1633 writeHex_ui32( uA.ui, ' ' );
1634 *genLoops_trueFlagsPtr = 0;
1635 trueFunction( genCases_f32_a, &trueZ );
1636 trueFlags = *genLoops_trueFlagsPtr;
1637 if ( writeGenOutputs_extF80M( &trueZ, trueFlags ) ) break;
1638 }
1639
1640}
1641
1642#endif
1643
1644#ifdef FLOAT128
1645
1646void gen_a_f32_z_f128( void trueFunction( float32_t, float128_t * ) )
1647{
1648 union ui32_f32 uA;
1649 float128_t trueZ;
1650 uint_fast8_t trueFlags;
1651
1652 genCases_f32_a_init();
1653 checkEnoughCases();
1654 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1655 genCases_f32_a_next();
1656 uA.f = genCases_f32_a;
1657 writeHex_ui32( uA.ui, ' ' );
1658 *genLoops_trueFlagsPtr = 0;
1659 trueFunction( genCases_f32_a, &trueZ );
1660 trueFlags = *genLoops_trueFlagsPtr;
1661 if ( writeGenOutputs_f128M( &trueZ, trueFlags ) ) break;
1662 }
1663
1664}
1665
1666#endif
1667
1668void gen_az_f32( float32_t trueFunction( float32_t ) )
1669{
1670 union ui32_f32 u;
1671 uint_fast8_t trueFlags;
1672
1673 genCases_f32_a_init();
1674 checkEnoughCases();
1675 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1676 genCases_f32_a_next();
1677 u.f = genCases_f32_a;
1678 writeHex_ui32( u.ui, ' ' );
1679 *genLoops_trueFlagsPtr = 0;
1680 u.f = trueFunction( genCases_f32_a );
1681 trueFlags = *genLoops_trueFlagsPtr;
1682 if ( writeGenOutputs_ui32( u.ui, trueFlags ) ) break;
1683 }
1684
1685}
1686
1687void
1688 gen_az_f32_rx(
1689 float32_t trueFunction( float32_t, uint_fast8_t, bool ),
1690 uint_fast8_t roundingMode,
1691 bool exact
1692 )
1693{
1694 union ui32_f32 u;
1695 uint_fast8_t trueFlags;
1696
1697 genCases_f32_a_init();
1698 checkEnoughCases();
1699 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1700 genCases_f32_a_next();
1701 u.f = genCases_f32_a;
1702 writeHex_ui32( u.ui, ' ' );
1703 *genLoops_trueFlagsPtr = 0;
1704 u.f = trueFunction( genCases_f32_a, roundingMode, exact );
1705 trueFlags = *genLoops_trueFlagsPtr;
1706 if ( writeGenOutputs_ui32( u.ui, trueFlags ) ) break;
1707 }
1708
1709}
1710
1711void gen_abz_f32( float32_t trueFunction( float32_t, float32_t ) )
1712{
1713 union ui32_f32 u;
1714 uint_fast8_t trueFlags;
1715
1716 genCases_f32_ab_init();
1717 checkEnoughCases();
1718 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1719 genCases_f32_ab_next();
1720 u.f = genCases_f32_a;
1721 writeHex_ui32( u.ui, ' ' );
1722 u.f = genCases_f32_b;
1723 writeHex_ui32( u.ui, ' ' );
1724 *genLoops_trueFlagsPtr = 0;
1725 u.f = trueFunction( genCases_f32_a, genCases_f32_b );
1726 trueFlags = *genLoops_trueFlagsPtr;
1727 if ( writeGenOutputs_ui32( u.ui, trueFlags ) ) break;
1728 }
1729
1730}
1731
1732void gen_abcz_f32( float32_t trueFunction( float32_t, float32_t, float32_t ) )
1733{
1734 union ui32_f32 u;
1735 uint_fast8_t trueFlags;
1736
1737 genCases_f32_abc_init();
1738 checkEnoughCases();
1739 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1740 genCases_f32_abc_next();
1741 u.f = genCases_f32_a;
1742 writeHex_ui32( u.ui, ' ' );
1743 u.f = genCases_f32_b;
1744 writeHex_ui32( u.ui, ' ' );
1745 u.f = genCases_f32_c;
1746 writeHex_ui32( u.ui, ' ' );
1747 *genLoops_trueFlagsPtr = 0;
1748 u.f = trueFunction( genCases_f32_a, genCases_f32_b, genCases_f32_c );
1749 trueFlags = *genLoops_trueFlagsPtr;
1750 if ( writeGenOutputs_ui32( u.ui, trueFlags ) ) break;
1751 }
1752
1753}
1754
1755void gen_ab_f32_z_bool( bool trueFunction( float32_t, float32_t ) )
1756{
1757 union ui32_f32 u;
1758 bool trueZ;
1759 uint_fast8_t trueFlags;
1760
1761 genCases_f32_ab_init();
1762 checkEnoughCases();
1763 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1764 genCases_f32_ab_next();
1765 u.f = genCases_f32_a;
1766 writeHex_ui32( u.ui, ' ' );
1767 u.f = genCases_f32_b;
1768 writeHex_ui32( u.ui, ' ' );
1769 *genLoops_trueFlagsPtr = 0;
1770 trueZ = trueFunction( genCases_f32_a, genCases_f32_b );
1771 trueFlags = *genLoops_trueFlagsPtr;
1772 if ( writeGenOutputs_bool( trueZ, trueFlags ) ) break;
1773 }
1774
1775}
1776
1777#ifdef FLOAT64
1778
1779void
1780 gen_a_f64_z_ui32_rx(
1781 uint_fast32_t trueFunction( float64_t, uint_fast8_t, bool ),
1782 uint_fast8_t roundingMode,
1783 bool exact
1784 )
1785{
1786 union ui64_f64 uA;
1787 uint_fast32_t trueZ;
1788 uint_fast8_t trueFlags;
1789
1790 genCases_f64_a_init();
1791 checkEnoughCases();
1792 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1793 genCases_f64_a_next();
1794 uA.f = genCases_f64_a;
1795 writeHex_ui64( uA.ui, ' ' );
1796 *genLoops_trueFlagsPtr = 0;
1797 trueZ = trueFunction( genCases_f64_a, roundingMode, exact );
1798 trueFlags = *genLoops_trueFlagsPtr;
1799 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
1800 }
1801
1802}
1803
1804void
1805 gen_a_f64_z_ui64_rx(
1806 uint_fast64_t trueFunction( float64_t, uint_fast8_t, bool ),
1807 uint_fast8_t roundingMode,
1808 bool exact
1809 )
1810{
1811 union ui64_f64 uA;
1812 uint_fast64_t trueZ;
1813 uint_fast8_t trueFlags;
1814
1815 genCases_f64_a_init();
1816 checkEnoughCases();
1817 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1818 genCases_f64_a_next();
1819 uA.f = genCases_f64_a;
1820 writeHex_ui64( uA.ui, ' ' );
1821 *genLoops_trueFlagsPtr = 0;
1822 trueZ = trueFunction( genCases_f64_a, roundingMode, exact );
1823 trueFlags = *genLoops_trueFlagsPtr;
1824 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
1825 }
1826
1827}
1828
1829void
1830 gen_a_f64_z_i32_rx(
1831 int_fast32_t trueFunction( float64_t, uint_fast8_t, bool ),
1832 uint_fast8_t roundingMode,
1833 bool exact
1834 )
1835{
1836 union ui64_f64 uA;
1837 int_fast32_t trueZ;
1838 uint_fast8_t trueFlags;
1839
1840 genCases_f64_a_init();
1841 checkEnoughCases();
1842 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1843 genCases_f64_a_next();
1844 uA.f = genCases_f64_a;
1845 writeHex_ui64( uA.ui, ' ' );
1846 *genLoops_trueFlagsPtr = 0;
1847 trueZ = trueFunction( genCases_f64_a, roundingMode, exact );
1848 trueFlags = *genLoops_trueFlagsPtr;
1849 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
1850 }
1851
1852}
1853
1854void
1855 gen_a_f64_z_i64_rx(
1856 int_fast64_t trueFunction( float64_t, uint_fast8_t, bool ),
1857 uint_fast8_t roundingMode,
1858 bool exact
1859 )
1860{
1861 union ui64_f64 uA;
1862 int_fast64_t trueZ;
1863 uint_fast8_t trueFlags;
1864
1865 genCases_f64_a_init();
1866 checkEnoughCases();
1867 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1868 genCases_f64_a_next();
1869 uA.f = genCases_f64_a;
1870 writeHex_ui64( uA.ui, ' ' );
1871 *genLoops_trueFlagsPtr = 0;
1872 trueZ = trueFunction( genCases_f64_a, roundingMode, exact );
1873 trueFlags = *genLoops_trueFlagsPtr;
1874 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
1875 }
1876
1877}
1878
1879void
1880 gen_a_f64_z_ui32_x(
1881 uint_fast32_t trueFunction( float64_t, bool ), bool exact )
1882{
1883 union ui64_f64 uA;
1884 uint_fast32_t trueZ;
1885 uint_fast8_t trueFlags;
1886
1887 genCases_f64_a_init();
1888 checkEnoughCases();
1889 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1890 genCases_f64_a_next();
1891 uA.f = genCases_f64_a;
1892 writeHex_ui64( uA.ui, ' ' );
1893 *genLoops_trueFlagsPtr = 0;
1894 trueZ = trueFunction( genCases_f64_a, exact );
1895 trueFlags = *genLoops_trueFlagsPtr;
1896 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
1897 }
1898
1899}
1900
1901void
1902 gen_a_f64_z_ui64_x(
1903 uint_fast64_t trueFunction( float64_t, bool ), bool exact )
1904{
1905 union ui64_f64 uA;
1906 uint_fast64_t trueZ;
1907 uint_fast8_t trueFlags;
1908
1909 genCases_f64_a_init();
1910 checkEnoughCases();
1911 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1912 genCases_f64_a_next();
1913 uA.f = genCases_f64_a;
1914 writeHex_ui64( uA.ui, ' ' );
1915 *genLoops_trueFlagsPtr = 0;
1916 trueZ = trueFunction( genCases_f64_a, exact );
1917 trueFlags = *genLoops_trueFlagsPtr;
1918 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
1919 }
1920
1921}
1922
1923void
1924 gen_a_f64_z_i32_x( int_fast32_t trueFunction( float64_t, bool ), bool exact )
1925{
1926 union ui64_f64 uA;
1927 int_fast32_t trueZ;
1928 uint_fast8_t trueFlags;
1929
1930 genCases_f64_a_init();
1931 checkEnoughCases();
1932 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1933 genCases_f64_a_next();
1934 uA.f = genCases_f64_a;
1935 writeHex_ui64( uA.ui, ' ' );
1936 *genLoops_trueFlagsPtr = 0;
1937 trueZ = trueFunction( genCases_f64_a, exact );
1938 trueFlags = *genLoops_trueFlagsPtr;
1939 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
1940 }
1941
1942}
1943
1944void
1945 gen_a_f64_z_i64_x( int_fast64_t trueFunction( float64_t, bool ), bool exact )
1946{
1947 union ui64_f64 uA;
1948 int_fast64_t trueZ;
1949 uint_fast8_t trueFlags;
1950
1951 genCases_f64_a_init();
1952 checkEnoughCases();
1953 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1954 genCases_f64_a_next();
1955 uA.f = genCases_f64_a;
1956 writeHex_ui64( uA.ui, ' ' );
1957 *genLoops_trueFlagsPtr = 0;
1958 trueZ = trueFunction( genCases_f64_a, exact );
1959 trueFlags = *genLoops_trueFlagsPtr;
1960 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
1961 }
1962
1963}
1964
1965#ifdef FLOAT16
1966
1967void gen_a_f64_z_f16( float16_t trueFunction( float64_t ) )
1968{
1969 union ui64_f64 uA;
1970 union ui16_f16 uTrueZ;
1971 uint_fast8_t trueFlags;
1972
1973 genCases_f64_a_init();
1974 checkEnoughCases();
1975 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1976 genCases_f64_a_next();
1977 uA.f = genCases_f64_a;
1978 writeHex_ui64( uA.ui, ' ' );
1979 *genLoops_trueFlagsPtr = 0;
1980 uTrueZ.f = trueFunction( genCases_f64_a );
1981 trueFlags = *genLoops_trueFlagsPtr;
1982 if ( writeGenOutputs_ui16( uTrueZ.ui, trueFlags ) ) break;
1983 }
1984
1985}
1986
1987#endif
1988
1989void gen_a_f64_z_f32( float32_t trueFunction( float64_t ) )
1990{
1991 union ui64_f64 uA;
1992 union ui32_f32 uTrueZ;
1993 uint_fast8_t trueFlags;
1994
1995 genCases_f64_a_init();
1996 checkEnoughCases();
1997 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
1998 genCases_f64_a_next();
1999 uA.f = genCases_f64_a;
2000 writeHex_ui64( uA.ui, ' ' );
2001 *genLoops_trueFlagsPtr = 0;
2002 uTrueZ.f = trueFunction( genCases_f64_a );
2003 trueFlags = *genLoops_trueFlagsPtr;
2004 if ( writeGenOutputs_ui32( uTrueZ.ui, trueFlags ) ) break;
2005 }
2006
2007}
2008
2009#ifdef EXTFLOAT80
2010
2011void gen_a_f64_z_extF80( void trueFunction( float64_t, extFloat80_t * ) )
2012{
2013 union ui64_f64 uA;
2014 extFloat80_t trueZ;
2015 uint_fast8_t trueFlags;
2016
2017 genCases_f64_a_init();
2018 checkEnoughCases();
2019 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2020 genCases_f64_a_next();
2021 uA.f = genCases_f64_a;
2022 writeHex_ui64( uA.ui, ' ' );
2023 *genLoops_trueFlagsPtr = 0;
2024 trueFunction( genCases_f64_a, &trueZ );
2025 trueFlags = *genLoops_trueFlagsPtr;
2026 if ( writeGenOutputs_extF80M( &trueZ, trueFlags ) ) break;
2027 }
2028
2029}
2030
2031#endif
2032
2033#ifdef FLOAT128
2034
2035void gen_a_f64_z_f128( void trueFunction( float64_t, float128_t * ) )
2036{
2037 union ui64_f64 uA;
2038 float128_t trueZ;
2039 uint_fast8_t trueFlags;
2040
2041 genCases_f64_a_init();
2042 checkEnoughCases();
2043 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2044 genCases_f64_a_next();
2045 uA.f = genCases_f64_a;
2046 writeHex_ui64( uA.ui, ' ' );
2047 *genLoops_trueFlagsPtr = 0;
2048 trueFunction( genCases_f64_a, &trueZ );
2049 trueFlags = *genLoops_trueFlagsPtr;
2050 if ( writeGenOutputs_f128M( &trueZ, trueFlags ) ) break;
2051 }
2052
2053}
2054
2055#endif
2056
2057void gen_az_f64( float64_t trueFunction( float64_t ) )
2058{
2059 union ui64_f64 u;
2060 uint_fast8_t trueFlags;
2061
2062 genCases_f64_a_init();
2063 checkEnoughCases();
2064 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2065 genCases_f64_a_next();
2066 u.f = genCases_f64_a;
2067 writeHex_ui64( u.ui, ' ' );
2068 *genLoops_trueFlagsPtr = 0;
2069 u.f = trueFunction( genCases_f64_a );
2070 trueFlags = *genLoops_trueFlagsPtr;
2071 if ( writeGenOutputs_ui64( u.ui, trueFlags ) ) break;
2072 }
2073
2074}
2075
2076void
2077 gen_az_f64_rx(
2078 float64_t trueFunction( float64_t, uint_fast8_t, bool ),
2079 uint_fast8_t roundingMode,
2080 bool exact
2081 )
2082{
2083 union ui64_f64 u;
2084 uint_fast8_t trueFlags;
2085
2086 genCases_f64_a_init();
2087 checkEnoughCases();
2088 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2089 genCases_f64_a_next();
2090 u.f = genCases_f64_a;
2091 writeHex_ui64( u.ui, ' ' );
2092 *genLoops_trueFlagsPtr = 0;
2093 u.f = trueFunction( genCases_f64_a, roundingMode, exact );
2094 trueFlags = *genLoops_trueFlagsPtr;
2095 if ( writeGenOutputs_ui64( u.ui, trueFlags ) ) break;
2096 }
2097
2098}
2099
2100void gen_abz_f64( float64_t trueFunction( float64_t, float64_t ) )
2101{
2102 union ui64_f64 u;
2103 uint_fast8_t trueFlags;
2104
2105 genCases_f64_ab_init();
2106 checkEnoughCases();
2107 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2108 genCases_f64_ab_next();
2109 u.f = genCases_f64_a;
2110 writeHex_ui64( u.ui, ' ' );
2111 u.f = genCases_f64_b;
2112 writeHex_ui64( u.ui, ' ' );
2113 *genLoops_trueFlagsPtr = 0;
2114 u.f = trueFunction( genCases_f64_a, genCases_f64_b );
2115 trueFlags = *genLoops_trueFlagsPtr;
2116 if ( writeGenOutputs_ui64( u.ui, trueFlags ) ) break;
2117 }
2118
2119}
2120
2121void gen_abcz_f64( float64_t trueFunction( float64_t, float64_t, float64_t ) )
2122{
2123 union ui64_f64 u;
2124 uint_fast8_t trueFlags;
2125
2126 genCases_f64_abc_init();
2127 checkEnoughCases();
2128 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2129 genCases_f64_abc_next();
2130 u.f = genCases_f64_a;
2131 writeHex_ui64( u.ui, ' ' );
2132 u.f = genCases_f64_b;
2133 writeHex_ui64( u.ui, ' ' );
2134 u.f = genCases_f64_c;
2135 writeHex_ui64( u.ui, ' ' );
2136 *genLoops_trueFlagsPtr = 0;
2137 u.f = trueFunction( genCases_f64_a, genCases_f64_b, genCases_f64_c );
2138 trueFlags = *genLoops_trueFlagsPtr;
2139 if ( writeGenOutputs_ui64( u.ui, trueFlags ) ) break;
2140 }
2141
2142}
2143
2144void gen_ab_f64_z_bool( bool trueFunction( float64_t, float64_t ) )
2145{
2146 union ui64_f64 u;
2147 bool trueZ;
2148 uint_fast8_t trueFlags;
2149
2150 genCases_f64_ab_init();
2151 checkEnoughCases();
2152 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2153 genCases_f64_ab_next();
2154 u.f = genCases_f64_a;
2155 writeHex_ui64( u.ui, ' ' );
2156 u.f = genCases_f64_b;
2157 writeHex_ui64( u.ui, ' ' );
2158 *genLoops_trueFlagsPtr = 0;
2159 trueZ = trueFunction( genCases_f64_a, genCases_f64_b );
2160 trueFlags = *genLoops_trueFlagsPtr;
2161 if ( writeGenOutputs_bool( trueZ, trueFlags ) ) break;
2162 }
2163
2164}
2165
2166#endif
2167
2168#ifdef EXTFLOAT80
2169
2170void
2171 gen_a_extF80_z_ui32_rx(
2172 uint_fast32_t trueFunction( const extFloat80_t *, uint_fast8_t, bool ),
2173 uint_fast8_t roundingMode,
2174 bool exact
2175 )
2176{
2177 uint_fast32_t trueZ;
2178 uint_fast8_t trueFlags;
2179
2180 genCases_extF80_a_init();
2181 checkEnoughCases();
2182 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2183 genCases_extF80_a_next();
2184 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2185 *genLoops_trueFlagsPtr = 0;
2186 trueZ = trueFunction( &genCases_extF80_a, roundingMode, exact );
2187 trueFlags = *genLoops_trueFlagsPtr;
2188 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
2189 }
2190
2191}
2192
2193void
2194 gen_a_extF80_z_ui64_rx(
2195 uint_fast64_t trueFunction( const extFloat80_t *, uint_fast8_t, bool ),
2196 uint_fast8_t roundingMode,
2197 bool exact
2198 )
2199{
2200 uint_fast64_t trueZ;
2201 uint_fast8_t trueFlags;
2202
2203 genCases_extF80_a_init();
2204 checkEnoughCases();
2205 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2206 genCases_extF80_a_next();
2207 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2208 *genLoops_trueFlagsPtr = 0;
2209 trueZ = trueFunction( &genCases_extF80_a, roundingMode, exact );
2210 trueFlags = *genLoops_trueFlagsPtr;
2211 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
2212 }
2213
2214}
2215
2216void
2217 gen_a_extF80_z_i32_rx(
2218 int_fast32_t trueFunction( const extFloat80_t *, uint_fast8_t, bool ),
2219 uint_fast8_t roundingMode,
2220 bool exact
2221 )
2222{
2223 int_fast32_t trueZ;
2224 uint_fast8_t trueFlags;
2225
2226 genCases_extF80_a_init();
2227 checkEnoughCases();
2228 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2229 genCases_extF80_a_next();
2230 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2231 *genLoops_trueFlagsPtr = 0;
2232 trueZ = trueFunction( &genCases_extF80_a, roundingMode, exact );
2233 trueFlags = *genLoops_trueFlagsPtr;
2234 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
2235 }
2236
2237}
2238
2239void
2240 gen_a_extF80_z_i64_rx(
2241 int_fast64_t trueFunction( const extFloat80_t *, uint_fast8_t, bool ),
2242 uint_fast8_t roundingMode,
2243 bool exact
2244 )
2245{
2246 int_fast64_t trueZ;
2247 uint_fast8_t trueFlags;
2248
2249 genCases_extF80_a_init();
2250 checkEnoughCases();
2251 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2252 genCases_extF80_a_next();
2253 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2254 *genLoops_trueFlagsPtr = 0;
2255 trueZ = trueFunction( &genCases_extF80_a, roundingMode, exact );
2256 trueFlags = *genLoops_trueFlagsPtr;
2257 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
2258 }
2259
2260}
2261
2262void
2263 gen_a_extF80_z_ui32_x(
2264 uint_fast32_t trueFunction( const extFloat80_t *, bool ), bool exact )
2265{
2266 uint_fast32_t trueZ;
2267 uint_fast8_t trueFlags;
2268
2269 genCases_extF80_a_init();
2270 checkEnoughCases();
2271 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2272 genCases_extF80_a_next();
2273 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2274 *genLoops_trueFlagsPtr = 0;
2275 trueZ = trueFunction( &genCases_extF80_a, exact );
2276 trueFlags = *genLoops_trueFlagsPtr;
2277 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
2278 }
2279
2280}
2281
2282void
2283 gen_a_extF80_z_ui64_x(
2284 uint_fast64_t trueFunction( const extFloat80_t *, bool ), bool exact )
2285{
2286 uint_fast64_t trueZ;
2287 uint_fast8_t trueFlags;
2288
2289 genCases_extF80_a_init();
2290 checkEnoughCases();
2291 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2292 genCases_extF80_a_next();
2293 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2294 *genLoops_trueFlagsPtr = 0;
2295 trueZ = trueFunction( &genCases_extF80_a, exact );
2296 trueFlags = *genLoops_trueFlagsPtr;
2297 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
2298 }
2299
2300}
2301
2302void
2303 gen_a_extF80_z_i32_x(
2304 int_fast32_t trueFunction( const extFloat80_t *, bool ), bool exact )
2305{
2306 int_fast32_t trueZ;
2307 uint_fast8_t trueFlags;
2308
2309 genCases_extF80_a_init();
2310 checkEnoughCases();
2311 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2312 genCases_extF80_a_next();
2313 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2314 *genLoops_trueFlagsPtr = 0;
2315 trueZ = trueFunction( &genCases_extF80_a, exact );
2316 trueFlags = *genLoops_trueFlagsPtr;
2317 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
2318 }
2319
2320}
2321
2322void
2323 gen_a_extF80_z_i64_x(
2324 int_fast64_t trueFunction( const extFloat80_t *, bool ), bool exact )
2325{
2326 int_fast64_t trueZ;
2327 uint_fast8_t trueFlags;
2328
2329 genCases_extF80_a_init();
2330 checkEnoughCases();
2331 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2332 genCases_extF80_a_next();
2333 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2334 *genLoops_trueFlagsPtr = 0;
2335 trueZ = trueFunction( &genCases_extF80_a, exact );
2336 trueFlags = *genLoops_trueFlagsPtr;
2337 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
2338 }
2339
2340}
2341
2342#ifdef FLOAT16
2343
2344void gen_a_extF80_z_f16( float16_t trueFunction( const extFloat80_t * ) )
2345{
2346 union ui16_f16 uTrueZ;
2347 uint_fast8_t trueFlags;
2348
2349 genCases_extF80_a_init();
2350 checkEnoughCases();
2351 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2352 genCases_extF80_a_next();
2353 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2354 *genLoops_trueFlagsPtr = 0;
2355 uTrueZ.f = trueFunction( &genCases_extF80_a );
2356 trueFlags = *genLoops_trueFlagsPtr;
2357 if ( writeGenOutputs_ui16( uTrueZ.ui, trueFlags ) ) break;
2358 }
2359
2360}
2361
2362#endif
2363
2364void gen_a_extF80_z_f32( float32_t trueFunction( const extFloat80_t * ) )
2365{
2366 union ui32_f32 uTrueZ;
2367 uint_fast8_t trueFlags;
2368
2369 genCases_extF80_a_init();
2370 checkEnoughCases();
2371 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2372 genCases_extF80_a_next();
2373 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2374 *genLoops_trueFlagsPtr = 0;
2375 uTrueZ.f = trueFunction( &genCases_extF80_a );
2376 trueFlags = *genLoops_trueFlagsPtr;
2377 if ( writeGenOutputs_ui32( uTrueZ.ui, trueFlags ) ) break;
2378 }
2379
2380}
2381
2382#ifdef FLOAT64
2383
2384void gen_a_extF80_z_f64( float64_t trueFunction( const extFloat80_t * ) )
2385{
2386 union ui64_f64 uTrueZ;
2387 uint_fast8_t trueFlags;
2388
2389 genCases_extF80_a_init();
2390 checkEnoughCases();
2391 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2392 genCases_extF80_a_next();
2393 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2394 *genLoops_trueFlagsPtr = 0;
2395 uTrueZ.f = trueFunction( &genCases_extF80_a );
2396 trueFlags = *genLoops_trueFlagsPtr;
2397 if ( writeGenOutputs_ui64( uTrueZ.ui, trueFlags ) ) break;
2398 }
2399
2400}
2401
2402#endif
2403
2404#ifdef FLOAT128
2405
2406void
2407 gen_a_extF80_z_f128( void trueFunction( const extFloat80_t *, float128_t * ) )
2408{
2409 float128_t trueZ;
2410 uint_fast8_t trueFlags;
2411
2412 genCases_extF80_a_init();
2413 checkEnoughCases();
2414 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2415 genCases_extF80_a_next();
2416 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2417 *genLoops_trueFlagsPtr = 0;
2418 trueFunction( &genCases_extF80_a, &trueZ );
2419 trueFlags = *genLoops_trueFlagsPtr;
2420 if ( writeGenOutputs_f128M( &trueZ, trueFlags ) ) break;
2421 }
2422
2423}
2424
2425#endif
2426
2427void gen_az_extF80( void trueFunction( const extFloat80_t *, extFloat80_t * ) )
2428{
2429 extFloat80_t trueZ;
2430 uint_fast8_t trueFlags;
2431
2432 genCases_extF80_a_init();
2433 checkEnoughCases();
2434 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2435 genCases_extF80_a_next();
2436 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2437 *genLoops_trueFlagsPtr = 0;
2438 trueFunction( &genCases_extF80_a, &trueZ );
2439 trueFlags = *genLoops_trueFlagsPtr;
2440 if ( writeGenOutputs_extF80M( &trueZ, trueFlags ) ) break;
2441 }
2442
2443}
2444
2445void
2446 gen_az_extF80_rx(
2447 void
2448 trueFunction( const extFloat80_t *, uint_fast8_t, bool, extFloat80_t * ),
2449 uint_fast8_t roundingMode,
2450 bool exact
2451 )
2452{
2453 extFloat80_t trueZ;
2454 uint_fast8_t trueFlags;
2455
2456 genCases_extF80_a_init();
2457 checkEnoughCases();
2458 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2459 genCases_extF80_a_next();
2460 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2461 *genLoops_trueFlagsPtr = 0;
2462 trueFunction( &genCases_extF80_a, roundingMode, exact, &trueZ );
2463 trueFlags = *genLoops_trueFlagsPtr;
2464 if ( writeGenOutputs_extF80M( &trueZ, trueFlags ) ) break;
2465 }
2466
2467}
2468
2469void
2470 gen_abz_extF80(
2471 void
2472 trueFunction(
2473 const extFloat80_t *, const extFloat80_t *, extFloat80_t * )
2474 )
2475{
2476 extFloat80_t trueZ;
2477 uint_fast8_t trueFlags;
2478
2479 genCases_extF80_ab_init();
2480 checkEnoughCases();
2481 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2482 genCases_extF80_ab_next();
2483 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2484 writeHex_uiExtF80M( &genCases_extF80_b, ' ' );
2485 *genLoops_trueFlagsPtr = 0;
2486 trueFunction( &genCases_extF80_a, &genCases_extF80_b, &trueZ );
2487 trueFlags = *genLoops_trueFlagsPtr;
2488 if ( writeGenOutputs_extF80M( &trueZ, trueFlags ) ) break;
2489 }
2490
2491}
2492
2493void
2494 gen_ab_extF80_z_bool(
2495 bool trueFunction( const extFloat80_t *, const extFloat80_t * ) )
2496{
2497 bool trueZ;
2498 uint_fast8_t trueFlags;
2499
2500 genCases_extF80_ab_init();
2501 checkEnoughCases();
2502 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2503 genCases_extF80_ab_next();
2504 writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
2505 writeHex_uiExtF80M( &genCases_extF80_b, ' ' );
2506 *genLoops_trueFlagsPtr = 0;
2507 trueZ = trueFunction( &genCases_extF80_a, &genCases_extF80_b );
2508 trueFlags = *genLoops_trueFlagsPtr;
2509 if ( writeGenOutputs_bool( trueZ, trueFlags ) ) break;
2510 }
2511
2512}
2513
2514#endif
2515
2516#ifdef FLOAT128
2517
2518void
2519 gen_a_f128_z_ui32_rx(
2520 uint_fast32_t trueFunction( const float128_t *, uint_fast8_t, bool ),
2521 uint_fast8_t roundingMode,
2522 bool exact
2523 )
2524{
2525 uint_fast32_t trueZ;
2526 uint_fast8_t trueFlags;
2527
2528 genCases_f128_a_init();
2529 checkEnoughCases();
2530 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2531 genCases_f128_a_next();
2532 writeHex_uiF128M( &genCases_f128_a, ' ' );
2533 *genLoops_trueFlagsPtr = 0;
2534 trueZ = trueFunction( &genCases_f128_a, roundingMode, exact );
2535 trueFlags = *genLoops_trueFlagsPtr;
2536 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
2537 }
2538
2539}
2540
2541void
2542 gen_a_f128_z_ui64_rx(
2543 uint_fast64_t trueFunction( const float128_t *, uint_fast8_t, bool ),
2544 uint_fast8_t roundingMode,
2545 bool exact
2546 )
2547{
2548 uint_fast64_t trueZ;
2549 uint_fast8_t trueFlags;
2550
2551 genCases_f128_a_init();
2552 checkEnoughCases();
2553 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2554 genCases_f128_a_next();
2555 writeHex_uiF128M( &genCases_f128_a, ' ' );
2556 *genLoops_trueFlagsPtr = 0;
2557 trueZ = trueFunction( &genCases_f128_a, roundingMode, exact );
2558 trueFlags = *genLoops_trueFlagsPtr;
2559 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
2560 }
2561
2562}
2563
2564void
2565 gen_a_f128_z_i32_rx(
2566 int_fast32_t trueFunction( const float128_t *, uint_fast8_t, bool ),
2567 uint_fast8_t roundingMode,
2568 bool exact
2569 )
2570{
2571 int_fast32_t trueZ;
2572 uint_fast8_t trueFlags;
2573
2574 genCases_f128_a_init();
2575 checkEnoughCases();
2576 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2577 genCases_f128_a_next();
2578 writeHex_uiF128M( &genCases_f128_a, ' ' );
2579 *genLoops_trueFlagsPtr = 0;
2580 trueZ = trueFunction( &genCases_f128_a, roundingMode, exact );
2581 trueFlags = *genLoops_trueFlagsPtr;
2582 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
2583 }
2584
2585}
2586
2587void
2588 gen_a_f128_z_i64_rx(
2589 int_fast64_t trueFunction( const float128_t *, uint_fast8_t, bool ),
2590 uint_fast8_t roundingMode,
2591 bool exact
2592 )
2593{
2594 int_fast64_t trueZ;
2595 uint_fast8_t trueFlags;
2596
2597 genCases_f128_a_init();
2598 checkEnoughCases();
2599 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2600 genCases_f128_a_next();
2601 writeHex_uiF128M( &genCases_f128_a, ' ' );
2602 *genLoops_trueFlagsPtr = 0;
2603 trueZ = trueFunction( &genCases_f128_a, roundingMode, exact );
2604 trueFlags = *genLoops_trueFlagsPtr;
2605 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
2606 }
2607
2608}
2609
2610void
2611 gen_a_f128_z_ui32_x(
2612 uint_fast32_t trueFunction( const float128_t *, bool ), bool exact )
2613{
2614 uint_fast32_t trueZ;
2615 uint_fast8_t trueFlags;
2616
2617 genCases_f128_a_init();
2618 checkEnoughCases();
2619 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2620 genCases_f128_a_next();
2621 writeHex_uiF128M( &genCases_f128_a, ' ' );
2622 *genLoops_trueFlagsPtr = 0;
2623 trueZ = trueFunction( &genCases_f128_a, exact );
2624 trueFlags = *genLoops_trueFlagsPtr;
2625 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
2626 }
2627
2628}
2629
2630void
2631 gen_a_f128_z_ui64_x(
2632 uint_fast64_t trueFunction( const float128_t *, bool ), bool exact )
2633{
2634 uint_fast64_t trueZ;
2635 uint_fast8_t trueFlags;
2636
2637 genCases_f128_a_init();
2638 checkEnoughCases();
2639 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2640 genCases_f128_a_next();
2641 writeHex_uiF128M( &genCases_f128_a, ' ' );
2642 *genLoops_trueFlagsPtr = 0;
2643 trueZ = trueFunction( &genCases_f128_a, exact );
2644 trueFlags = *genLoops_trueFlagsPtr;
2645 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
2646 }
2647
2648}
2649
2650void
2651 gen_a_f128_z_i32_x(
2652 int_fast32_t trueFunction( const float128_t *, bool ), bool exact )
2653{
2654 int_fast32_t trueZ;
2655 uint_fast8_t trueFlags;
2656
2657 genCases_f128_a_init();
2658 checkEnoughCases();
2659 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2660 genCases_f128_a_next();
2661 writeHex_uiF128M( &genCases_f128_a, ' ' );
2662 *genLoops_trueFlagsPtr = 0;
2663 trueZ = trueFunction( &genCases_f128_a, exact );
2664 trueFlags = *genLoops_trueFlagsPtr;
2665 if ( writeGenOutputs_ui32( trueZ, trueFlags ) ) break;
2666 }
2667
2668}
2669
2670void
2671 gen_a_f128_z_i64_x(
2672 int_fast64_t trueFunction( const float128_t *, bool ), bool exact )
2673{
2674 int_fast64_t trueZ;
2675 uint_fast8_t trueFlags;
2676
2677 genCases_f128_a_init();
2678 checkEnoughCases();
2679 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2680 genCases_f128_a_next();
2681 writeHex_uiF128M( &genCases_f128_a, ' ' );
2682 *genLoops_trueFlagsPtr = 0;
2683 trueZ = trueFunction( &genCases_f128_a, exact );
2684 trueFlags = *genLoops_trueFlagsPtr;
2685 if ( writeGenOutputs_ui64( trueZ, trueFlags ) ) break;
2686 }
2687
2688}
2689
2690#ifdef FLOAT16
2691
2692void gen_a_f128_z_f16( float16_t trueFunction( const float128_t * ) )
2693{
2694 union ui16_f16 uTrueZ;
2695 uint_fast8_t trueFlags;
2696
2697 genCases_f128_a_init();
2698 checkEnoughCases();
2699 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2700 genCases_f128_a_next();
2701 writeHex_uiF128M( &genCases_f128_a, ' ' );
2702 *genLoops_trueFlagsPtr = 0;
2703 uTrueZ.f = trueFunction( &genCases_f128_a );
2704 trueFlags = *genLoops_trueFlagsPtr;
2705 if ( writeGenOutputs_ui16( uTrueZ.ui, trueFlags ) ) break;
2706 }
2707
2708}
2709
2710#endif
2711
2712void gen_a_f128_z_f32( float32_t trueFunction( const float128_t * ) )
2713{
2714 union ui32_f32 uTrueZ;
2715 uint_fast8_t trueFlags;
2716
2717 genCases_f128_a_init();
2718 checkEnoughCases();
2719 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2720 genCases_f128_a_next();
2721 writeHex_uiF128M( &genCases_f128_a, ' ' );
2722 *genLoops_trueFlagsPtr = 0;
2723 uTrueZ.f = trueFunction( &genCases_f128_a );
2724 trueFlags = *genLoops_trueFlagsPtr;
2725 if ( writeGenOutputs_ui32( uTrueZ.ui, trueFlags ) ) break;
2726 }
2727
2728}
2729
2730#ifdef FLOAT64
2731
2732void gen_a_f128_z_f64( float64_t trueFunction( const float128_t * ) )
2733{
2734 union ui64_f64 uTrueZ;
2735 uint_fast8_t trueFlags;
2736
2737 genCases_f128_a_init();
2738 checkEnoughCases();
2739 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2740 genCases_f128_a_next();
2741 writeHex_uiF128M( &genCases_f128_a, ' ' );
2742 *genLoops_trueFlagsPtr = 0;
2743 uTrueZ.f = trueFunction( &genCases_f128_a );
2744 trueFlags = *genLoops_trueFlagsPtr;
2745 if ( writeGenOutputs_ui64( uTrueZ.ui, trueFlags ) ) break;
2746 }
2747
2748}
2749
2750#endif
2751
2752#ifdef EXTFLOAT80
2753
2754void
2755 gen_a_f128_z_extF80( void trueFunction( const float128_t *, extFloat80_t * ) )
2756{
2757 extFloat80_t trueZ;
2758 uint_fast8_t trueFlags;
2759
2760 genCases_f128_a_init();
2761 checkEnoughCases();
2762 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2763 genCases_f128_a_next();
2764 writeHex_uiF128M( &genCases_f128_a, ' ' );
2765 *genLoops_trueFlagsPtr = 0;
2766 trueFunction( &genCases_f128_a, &trueZ );
2767 trueFlags = *genLoops_trueFlagsPtr;
2768 if ( writeGenOutputs_extF80M( &trueZ, trueFlags ) ) break;
2769 }
2770
2771}
2772
2773#endif
2774
2775void gen_az_f128( void trueFunction( const float128_t *, float128_t * ) )
2776{
2777 float128_t trueZ;
2778 uint_fast8_t trueFlags;
2779
2780 genCases_f128_a_init();
2781 checkEnoughCases();
2782 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2783 genCases_f128_a_next();
2784 writeHex_uiF128M( &genCases_f128_a, ' ' );
2785 *genLoops_trueFlagsPtr = 0;
2786 trueFunction( &genCases_f128_a, &trueZ );
2787 trueFlags = *genLoops_trueFlagsPtr;
2788 if ( writeGenOutputs_f128M( &trueZ, trueFlags ) ) break;
2789 }
2790
2791}
2792
2793void
2794 gen_az_f128_rx(
2795 void trueFunction( const float128_t *, uint_fast8_t, bool, float128_t * ),
2796 uint_fast8_t roundingMode,
2797 bool exact
2798 )
2799{
2800 float128_t trueZ;
2801 uint_fast8_t trueFlags;
2802
2803 genCases_f128_a_init();
2804 checkEnoughCases();
2805 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2806 genCases_f128_a_next();
2807 writeHex_uiF128M( &genCases_f128_a, ' ' );
2808 *genLoops_trueFlagsPtr = 0;
2809 trueFunction( &genCases_f128_a, roundingMode, exact, &trueZ );
2810 trueFlags = *genLoops_trueFlagsPtr;
2811 if ( writeGenOutputs_f128M( &trueZ, trueFlags ) ) break;
2812 }
2813
2814}
2815
2816void
2817 gen_abz_f128(
2818 void trueFunction( const float128_t *, const float128_t *, float128_t * )
2819 )
2820{
2821 float128_t trueZ;
2822 uint_fast8_t trueFlags;
2823
2824 genCases_f128_ab_init();
2825 checkEnoughCases();
2826 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2827 genCases_f128_ab_next();
2828 writeHex_uiF128M( &genCases_f128_a, ' ' );
2829 writeHex_uiF128M( &genCases_f128_b, ' ' );
2830 *genLoops_trueFlagsPtr = 0;
2831 trueFunction( &genCases_f128_a, &genCases_f128_b, &trueZ );
2832 trueFlags = *genLoops_trueFlagsPtr;
2833 if ( writeGenOutputs_f128M( &trueZ, trueFlags ) ) break;
2834 }
2835
2836}
2837
2838void
2839 gen_abcz_f128(
2840 void
2841 trueFunction(
2842 const float128_t *,
2843 const float128_t *,
2844 const float128_t *,
2845 float128_t *
2846 )
2847 )
2848{
2849 float128_t trueZ;
2850 uint_fast8_t trueFlags;
2851
2852 genCases_f128_abc_init();
2853 checkEnoughCases();
2854 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2855 genCases_f128_abc_next();
2856 writeHex_uiF128M( &genCases_f128_a, ' ' );
2857 writeHex_uiF128M( &genCases_f128_b, ' ' );
2858 writeHex_uiF128M( &genCases_f128_c, ' ' );
2859 *genLoops_trueFlagsPtr = 0;
2860 trueFunction(
2861 &genCases_f128_a, &genCases_f128_b, &genCases_f128_c, &trueZ );
2862 trueFlags = *genLoops_trueFlagsPtr;
2863 if ( writeGenOutputs_f128M( &trueZ, trueFlags ) ) break;
2864 }
2865
2866}
2867
2868void
2869 gen_ab_f128_z_bool(
2870 bool trueFunction( const float128_t *, const float128_t * ) )
2871{
2872 bool trueZ;
2873 uint_fast8_t trueFlags;
2874
2875 genCases_f128_ab_init();
2876 checkEnoughCases();
2877 while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
2878 genCases_f128_ab_next();
2879 writeHex_uiF128M( &genCases_f128_a, ' ' );
2880 writeHex_uiF128M( &genCases_f128_b, ' ' );
2881 *genLoops_trueFlagsPtr = 0;
2882 trueZ = trueFunction( &genCases_f128_a, &genCases_f128_b );
2883 trueFlags = *genLoops_trueFlagsPtr;
2884 if ( writeGenOutputs_bool( trueZ, trueFlags ) ) break;
2885 }
2886
2887}
2888
2889#endif
2890
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette