1 /* Copyright (C) 2007 Free Software Foundation, Inc.
3 This file is part of GCC.
5 GCC is free software; you can redistribute it and/or modify it under
6 the terms of the GNU General Public License as published by the Free
7 Software Foundation; either version 2, or (at your option) any later
10 In addition to the permissions in the GNU General Public License, the
11 Free Software Foundation gives you unlimited permission to link the
12 compiled version of this file into combinations with other programs,
13 and to distribute those combinations without any restriction coming
14 from the use of this file. (The General Public License restrictions
15 do apply in other respects; for example, they cover modification of
16 the file, and distribution when not linked into a combine
19 GCC is distributed in the hope that it will be useful, but WITHOUT ANY
20 WARRANTY; without even the implied warranty of MERCHANTABILITY or
21 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
24 You should have received a copy of the GNU General Public License
25 along with GCC; see the file COPYING. If not, write to the Free
26 Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA
29 #ifndef _BID_FUNCTIONS_H
30 #define _BID_FUNCTIONS_H
33 // When we are built as the part of the gcc runtime library, libgcc,
34 // we will use gcc types defined in bid_gcc_intrinsics.h.
35 #include "bid_gcc_intrinsics.h"
37 #define ALIGN(n) __attribute__ ((aligned(n)))
40 typedef unsigned char UINT8
;
41 typedef unsigned UINT32
;
42 typedef signed SINT32
;
45 #define __int64 long long
48 #if __GNUC__ || defined LINUX || defined SUNOS
49 typedef unsigned long long UINT64
;
50 typedef signed long long SINT64
;
52 typedef unsigned __int64 UINT64
;
53 typedef signed __int64 SINT64
;
57 #if defined _M_IX86 && !defined __INTEL_COMPILER // Win IA-32, MS compiler
60 #define ALIGN(n) __declspec(align(n))
63 #define ALIGN(n) __attribute__ ((aligned(n)))
66 // bid_gcc_intrinsics.h will also define this.
75 #if !defined _MSC_VER || defined __INTEL_COMPILER
76 #define __ENABLE_BINARY80__ 1
80 #define BINARY80 long double
81 #define BINARY128 UINT128
84 #define BINARY80 __float80
85 #define BINARY128 __float128
97 typedef unsigned int FPSC
; // floating-point status and control
100 #define BID128_MAXDIGITS 34
101 #define BID64_MAXDIGITS 16
102 #define BID32_MAXDIGITS 7
105 #define ROUNDING_TO_NEAREST 0x00000
106 #define ROUNDING_DOWN 0x00001
107 #define ROUNDING_UP 0x00002
108 #define ROUNDING_TO_ZERO 0x00003
109 #define ROUNDING_TIES_AWAY 0x00004
111 #define RMODE_MASK (ROUNDING_TO_NEAREST | ROUNDING_DOWN | ROUNDING_UP | ROUNDING_TO_ZERO | ROUNDING_TIES_AWAY)
114 #define FLAG_MASK 0x0000003f
115 #define BID_IEEE_FLAGS 0x0000003d
116 #define EXACT_STATUS 0x00000000
117 #define INEXACT_EXCEPTION 0x00000020
118 #define UNDERFLOW_EXCEPTION 0x00000010
119 #define OVERFLOW_EXCEPTION 0x00000008
120 #define ZERO_DIVIDE_EXCEPTION 0x00000004
121 #define DENORMAL_EXCEPTION 0x00000002
122 #define INVALID_EXCEPTION 0x00000001
124 #define MODE_MASK 0x00001f80
125 #define INEXACT_MODE 0x00001000
126 #define UNDERFLOW_MODE 0x00000800
127 #define OVERFLOW_MODE 0x00000400
128 #define ZERO_DIVIDE_MODE 0x00000200
129 #define DENORMAL_MODE 0x00000100
130 #define INVALID_MODE 0x00000080
132 #if defined LINUX || defined SUNOS
133 #define LX16 "%016llx"
136 #define LD16 "%016lld"
139 #define LUD16 "%016llu"
143 #define FMT_LLX16 "%016llx"
144 #define FMT_LLX "%llx"
145 #define FMT_LLU4 "%4llu"
146 #define FMT_LLD16 "%016lld"
147 #define FMT_LLD "%lld"
148 #define FMT_LLU "%llu"
149 #define FMT_LLU16 "%016llu"
150 #define FMT_X8 "%08x"
151 #define FMT_X4 "%04x"
153 #define LX16 "%016I64x"
155 #define LD16 "%016I64d"
159 #define LUD16 "%016I64u"
163 #define FMT_LLX16 "%016I64x"
164 #define FMT_LLX "%I64x"
165 #define FMT_LLD16 "%016I64d"
166 #define FMT_LLU4 "%4I64u"
167 #define FMT_LLD "%I64d"
168 #define FMT_LLU "%I64u"
169 #define FMT_LLU16 "%016I64u"
170 #define FMT_X8 "%08x"
171 #define FMT_X4 "%04x"
174 #define decNumberIsSNaN(dn) (((dn)->bits&(DECSNAN))!=0)
175 int __signbitf (float);
176 int __signbit (double);
178 #define __IMFC99MACRO_( __x__, __func__ ) \
179 (( sizeof( __x__ ) > sizeof( float )) \
180 ? __func__( (double)(__x__) ) \
181 : __func__##f( (float)(__x__) ))
183 #define signbit( __x__ ) __IMFC99MACRO_( __x__, __signbit )
185 #if !defined(__INTEL_COMPILER)
189 #define isinf( __x__ ) __IMFC99MACRO_( __x__, __isinf )
190 #define isnan( __x__ ) __IMFC99MACRO_( __x__, __isnan )
192 int __isnanf (float);
193 int __isnan (double);
195 int __isinff (float);
196 int __isinf (double);
201 // typedef unsigned int _IDEC_round;
202 extern _IDEC_round _IDEC_gblround
; // initialized to ROUNDING_TO_NEAREST
204 /* exception flags */
205 // typedef unsigned int _IDEC_flags; // could be a struct with diagnostic info
206 extern _IDEC_flags _IDEC_gblflags
; // initialized to EXACT_STATUS
208 /* exception masks */
209 typedef unsigned int _IDEC_exceptionmasks
;
210 extern _IDEC_exceptionmasks _IDEC_gblexceptionmasks
; // initialized to MODE_MASK
212 #if DECIMAL_ALTERNATE_EXCEPTION_HANDLING
214 /* exception information */
217 unsigned int inexact_result
:1;
218 unsigned int underflow
:1;
219 unsigned int overflow
:1;
220 unsigned int zero_divide
:1;
221 unsigned int invalid_operation
:1;
222 } fpieee_exception_flags_t
;
226 _fp_round_minus_infinity
,
227 _fp_round_plus_infinity
,
230 } fpieee_rounding_mode_t
;
239 } _fpieee_precision_t
;
242 _fp_code_unspecified
,
247 _fp_code_square_root
,
250 _fp_code_convert_to_integer_neareven
,
251 _fp_code_convert_to_integer_down
,
252 _fp_code_convert_to_integer_up
,
253 _fp_code_convert_to_integer_truncate
,
254 _fp_code_convert_to_integer_nearaway
,
260 _fp_code_round_to_integral
,
272 } fp_operation_code_t
;
278 _fp_compare_unordered
279 } fpieee_compare_result_t
;
288 _fp_format_dec_fp128
,
289 _fp_format_i8
, /* 8-bit integer */
290 _fp_format_i16
, /* 16-bit integer */
291 _fp_format_i32
, /* 32-bit integer */
292 _fp_format_i64
, /* 64-bit integer */
293 _fp_format_u8
, /* 8-bit unsigned integer */
294 _fp_format_u16
, /* 16-bit unsigned integer */
295 _fp_format_u32
, /* 32-bit unsigned integer */
296 _fp_format_u64
, /* 64-bit unsigned integer */
297 _fp_format_compare
, /* compare value format */
298 _fp_format_decimal_char
, /* decimal character */
299 _fp_format_string
/* string */
314 _float80_t fp80_value
;
315 _float128_t fp128_value
;
316 UINT32 decfp32_value
;
317 UINT64 decfp64_value
;
318 UINT128 decfp128_value
;
323 unsigned char u8_value
;
324 unsigned short u16_value
;
325 unsigned int u32_value
;
326 unsigned long u64_value
;
327 fpieee_compare_result_t compare_value
;
328 unsigned char s
[256];
330 unsigned int operand_valid
:1;
331 fpieee_format_t format
:5;
335 unsigned int rounding_mode
:3;
336 unsigned int precision
:3;
337 unsigned int operation
:26;
338 fpieee_exception_flags_t cause
;
339 fpieee_exception_flags_t enable
;
340 fpieee_exception_flags_t status
;
341 fpieee_value_t operand1
;
342 fpieee_value_t operand2
;
343 fpieee_value_t operand3
;
344 fpieee_value_t result
;
345 } _IDEC_excepthandling
;
346 extern _IDEC_excepthandling _IDEC_glbexcepthandling
;
350 #if DECIMAL_CALL_BY_REFERENCE
352 extern void bid_to_dpd32 (UINT32
* pres
, UINT32
* px
);
353 extern void bid_to_dpd64 (UINT64
* pres
, UINT64
* px
);
354 extern void bid_to_dpd128 (UINT128
* pres
, UINT128
* px
);
355 extern void dpd_to_bid32 (UINT32
* pres
, UINT32
* px
);
356 extern void dpd_to_bid64 (UINT64
* pres
, UINT64
* px
);
357 extern void dpd_to_bid128 (UINT128
* pres
, UINT128
* px
);
359 extern void bid128dd_add (UINT128
* pres
, UINT64
* px
,
361 _RND_MODE_PARAM _EXC_FLAGS_PARAM
362 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
363 extern void bid128dq_add (UINT128
* pres
, UINT64
* px
,
365 _RND_MODE_PARAM _EXC_FLAGS_PARAM
366 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
367 extern void bid128qd_add (UINT128
* pres
, UINT128
* px
,
369 _RND_MODE_PARAM _EXC_FLAGS_PARAM
370 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
371 extern void bid128_add (UINT128
* pres
, UINT128
* px
,
373 py _RND_MODE_PARAM _EXC_FLAGS_PARAM
374 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
375 extern void bid128dd_sub (UINT128
* pres
, UINT64
* px
,
377 _RND_MODE_PARAM _EXC_FLAGS_PARAM
378 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
379 extern void bid128dq_sub (UINT128
* pres
, UINT64
* px
,
381 _RND_MODE_PARAM _EXC_FLAGS_PARAM
382 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
383 extern void bid128qd_sub (UINT128
* pres
, UINT128
* px
,
385 _RND_MODE_PARAM _EXC_FLAGS_PARAM
386 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
387 extern void bid128_sub (UINT128
* pres
, UINT128
* px
,
389 py _RND_MODE_PARAM _EXC_FLAGS_PARAM
390 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
391 extern void bid128dd_mul (UINT128
* pres
, UINT64
* px
,
393 _RND_MODE_PARAM _EXC_FLAGS_PARAM
394 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
395 extern void bid128dq_mul (UINT128
* pres
, UINT64
* px
,
397 _RND_MODE_PARAM _EXC_FLAGS_PARAM
398 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
399 extern void bid128qd_mul (UINT128
* pres
, UINT128
* px
,
401 _RND_MODE_PARAM _EXC_FLAGS_PARAM
402 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
403 extern void bid128_mul (UINT128
* pres
, UINT128
* px
,
405 _RND_MODE_PARAM _EXC_FLAGS_PARAM
406 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
407 extern void bid128_div (UINT128
* pres
, UINT128
* px
,
409 py _RND_MODE_PARAM _EXC_FLAGS_PARAM
410 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
411 extern void bid128dd_div (UINT128
* pres
, UINT64
* px
,
413 _RND_MODE_PARAM _EXC_FLAGS_PARAM
414 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
415 extern void bid128dq_div (UINT128
* pres
, UINT64
* px
,
417 _RND_MODE_PARAM _EXC_FLAGS_PARAM
418 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
419 extern void bid128qd_div (UINT128
* pres
, UINT128
* px
,
421 _RND_MODE_PARAM _EXC_FLAGS_PARAM
422 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
423 extern void bid128_fma (UINT128
* pres
, UINT128
* px
,
424 UINT128
* py
, UINT128
* pz
425 _RND_MODE_PARAM _EXC_FLAGS_PARAM
426 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
427 extern void bid128ddd_fma (UINT128
* pres
, UINT64
* px
,
428 UINT64
* py
, UINT64
* pz
429 _RND_MODE_PARAM _EXC_FLAGS_PARAM
430 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
431 extern void bid128ddq_fma (UINT128
* pres
, UINT64
* px
,
432 UINT64
* py
, UINT128
* pz
433 _RND_MODE_PARAM _EXC_FLAGS_PARAM
434 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
435 extern void bid128dqd_fma (UINT128
* pres
, UINT64
* px
,
436 UINT128
* py
, UINT64
* pz
437 _RND_MODE_PARAM _EXC_FLAGS_PARAM
438 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
439 extern void bid128dqq_fma (UINT128
* pres
, UINT64
* px
,
440 UINT128
* py
, UINT128
* pz
441 _RND_MODE_PARAM _EXC_FLAGS_PARAM
442 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
443 extern void bid128qdd_fma (UINT128
* pres
, UINT128
* px
,
444 UINT64
* py
, UINT64
* pz
445 _RND_MODE_PARAM _EXC_FLAGS_PARAM
446 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
447 extern void bid128qdq_fma (UINT128
* pres
, UINT128
* px
,
448 UINT64
* py
, UINT128
* pz
449 _RND_MODE_PARAM _EXC_FLAGS_PARAM
450 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
451 extern void bid128qqd_fma (UINT128
* pres
, UINT128
* px
,
452 UINT128
* py
, UINT64
* pz
453 _RND_MODE_PARAM _EXC_FLAGS_PARAM
454 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
455 // Note: bid128qqq_fma is represented by bid128_fma
456 // Note: bid64ddd_fma is represented by bid64_fma
457 extern void bid64ddq_fma (UINT64
* pres
, UINT64
* px
,
458 UINT64
* py
, UINT128
* pz
459 _RND_MODE_PARAM _EXC_FLAGS_PARAM
460 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
461 extern void bid64dqd_fma (UINT64
* pres
, UINT64
* px
,
462 UINT128
* py
, UINT64
* pz
463 _RND_MODE_PARAM _EXC_FLAGS_PARAM
464 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
465 extern void bid64dqq_fma (UINT64
* pres
, UINT64
* px
,
466 UINT128
* py
, UINT128
* pz
467 _RND_MODE_PARAM _EXC_FLAGS_PARAM
468 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
469 extern void bid64qdd_fma (UINT64
* pres
, UINT128
* px
,
470 UINT64
* py
, UINT64
* pz
471 _RND_MODE_PARAM _EXC_FLAGS_PARAM
472 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
473 extern void bid64qdq_fma (UINT64
* pres
, UINT128
* px
,
474 UINT64
* py
, UINT128
* pz
475 _RND_MODE_PARAM _EXC_FLAGS_PARAM
476 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
477 extern void bid64qqd_fma (UINT64
* pres
, UINT128
* px
,
478 UINT128
* py
, UINT64
* pz
479 _RND_MODE_PARAM _EXC_FLAGS_PARAM
480 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
481 extern void bid64qqq_fma (UINT64
* pres
, UINT128
* px
,
482 UINT128
* py
, UINT128
* pz
483 _RND_MODE_PARAM _EXC_FLAGS_PARAM
484 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
486 extern void bid128_sqrt (UINT128
* pres
,
488 px _RND_MODE_PARAM _EXC_FLAGS_PARAM
489 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
490 extern void bid128d_sqrt (UINT128
* pres
, UINT64
* px
491 _RND_MODE_PARAM _EXC_FLAGS_PARAM
492 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
494 extern void bid64_add (UINT64
* pres
, UINT64
* px
,
496 py _RND_MODE_PARAM _EXC_FLAGS_PARAM
497 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
498 extern void bid64dq_add (UINT64
* pres
, UINT64
* px
,
500 _RND_MODE_PARAM _EXC_FLAGS_PARAM
501 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
502 extern void bid64qd_add (UINT64
* pres
, UINT128
* px
,
504 _RND_MODE_PARAM _EXC_FLAGS_PARAM
505 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
506 extern void bid64qq_add (UINT64
* pres
, UINT128
* px
,
508 _RND_MODE_PARAM _EXC_FLAGS_PARAM
509 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
510 extern void bid64_sub (UINT64
* pres
, UINT64
* px
,
512 py _RND_MODE_PARAM _EXC_FLAGS_PARAM
513 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
514 extern void bid64dq_sub (UINT64
* pres
, UINT64
* px
,
516 _RND_MODE_PARAM _EXC_FLAGS_PARAM
517 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
518 extern void bid64qd_sub (UINT64
* pres
, UINT128
* px
,
520 _RND_MODE_PARAM _EXC_FLAGS_PARAM
521 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
522 extern void bid64qq_sub (UINT64
* pres
, UINT128
* px
,
524 _RND_MODE_PARAM _EXC_FLAGS_PARAM
525 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
526 extern void bid64_mul (UINT64
* pres
, UINT64
* px
,
528 _RND_MODE_PARAM _EXC_FLAGS_PARAM
529 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
530 extern void bid64dq_mul (UINT64
* pres
, UINT64
* px
,
532 _RND_MODE_PARAM _EXC_FLAGS_PARAM
533 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
534 extern void bid64qd_mul (UINT64
* pres
, UINT128
* px
,
536 _RND_MODE_PARAM _EXC_FLAGS_PARAM
537 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
538 extern void bid64qq_mul (UINT64
* pres
, UINT128
* px
,
540 _RND_MODE_PARAM _EXC_FLAGS_PARAM
541 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
542 extern void bid64_div (UINT64
* pres
, UINT64
* px
,
544 py _RND_MODE_PARAM _EXC_FLAGS_PARAM
545 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
546 extern void bid64dq_div (UINT64
* pres
, UINT64
* px
,
548 _RND_MODE_PARAM _EXC_FLAGS_PARAM
549 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
550 extern void bid64qd_div (UINT64
* pres
, UINT128
* px
,
552 _RND_MODE_PARAM _EXC_FLAGS_PARAM
553 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
554 extern void bid64qq_div (UINT64
* pres
, UINT128
* px
,
556 _RND_MODE_PARAM _EXC_FLAGS_PARAM
557 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
558 extern void bid64_fma (UINT64
* pres
, UINT64
* px
,
561 pz _RND_MODE_PARAM _EXC_FLAGS_PARAM
562 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
563 extern void bid64_sqrt (UINT64
* pres
,
565 px _RND_MODE_PARAM _EXC_FLAGS_PARAM
566 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
567 extern void bid64q_sqrt (UINT64
* pres
, UINT128
* px
568 _RND_MODE_PARAM _EXC_FLAGS_PARAM
569 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
571 extern void bid128_to_int8_rnint (char *pres
,
576 extern void bid128_to_int8_xrnint (char *pres
,
581 extern void bid128_to_int8_rninta (char *pres
,
586 extern void bid128_to_int8_xrninta (char *pres
,
591 extern void bid128_to_int8_int (char *pres
,
594 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
595 extern void bid128_to_int8_xint (char *pres
,
598 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
599 extern void bid128_to_int8_floor (char *pres
,
604 extern void bid128_to_int8_xfloor (char *pres
,
609 extern void bid128_to_int8_ceil (char *pres
,
612 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
613 extern void bid128_to_int8_xceil (char *pres
,
618 extern void bid128_to_int16_rnint (short *pres
,
623 extern void bid128_to_int16_xrnint (short *pres
,
628 extern void bid128_to_int16_rninta (short *pres
,
633 extern void bid128_to_int16_xrninta (short *pres
,
638 extern void bid128_to_int16_int (short *pres
,
641 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
642 extern void bid128_to_int16_xint (short *pres
,
647 extern void bid128_to_int16_floor (short *pres
,
652 extern void bid128_to_int16_xfloor (short *pres
,
657 extern void bid128_to_int16_ceil (short *pres
,
662 extern void bid128_to_int16_xceil (short *pres
,
667 extern void bid128_to_uint8_rnint (unsigned char *pres
,
672 extern void bid128_to_uint8_xrnint (unsigned char *pres
,
677 extern void bid128_to_uint8_rninta (unsigned char *pres
,
682 extern void bid128_to_uint8_xrninta (unsigned char *pres
,
687 extern void bid128_to_uint8_int (unsigned char *pres
,
690 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
691 extern void bid128_to_uint8_xint (unsigned char *pres
,
696 extern void bid128_to_uint8_floor (unsigned char *pres
,
701 extern void bid128_to_uint8_xfloor (unsigned char *pres
,
706 extern void bid128_to_uint8_ceil (unsigned char *pres
,
711 extern void bid128_to_uint8_xceil (unsigned char *pres
,
716 extern void bid128_to_uint16_rnint (unsigned short *pres
,
721 extern void bid128_to_uint16_xrnint (unsigned short *pres
,
726 extern void bid128_to_uint16_rninta (unsigned short *pres
,
731 extern void bid128_to_uint16_xrninta (unsigned short *pres
,
736 extern void bid128_to_uint16_int (unsigned short *pres
,
741 extern void bid128_to_uint16_xint (unsigned short *pres
,
746 extern void bid128_to_uint16_floor (unsigned short *pres
,
751 extern void bid128_to_uint16_xfloor (unsigned short *pres
,
756 extern void bid128_to_uint16_ceil (unsigned short *pres
,
761 extern void bid128_to_uint16_xceil (unsigned short *pres
,
766 extern void bid128_to_int32_rnint (int *pres
,
771 extern void bid128_to_int32_xrnint (int *pres
,
776 extern void bid128_to_int32_rninta (int *pres
,
781 extern void bid128_to_int32_xrninta (int *pres
,
786 extern void bid128_to_int32_int (int *pres
,
789 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
790 extern void bid128_to_int32_xint (int *pres
,
795 extern void bid128_to_int32_floor (int *pres
,
800 extern void bid128_to_int32_xfloor (int *pres
,
805 extern void bid128_to_int32_ceil (int *pres
,
810 extern void bid128_to_int32_xceil (int *pres
,
815 extern void bid128_to_uint32_rnint (unsigned int *pres
,
820 extern void bid128_to_uint32_xrnint (unsigned int *pres
,
825 extern void bid128_to_uint32_rninta (unsigned int *pres
,
830 extern void bid128_to_uint32_xrninta (unsigned int *pres
,
835 extern void bid128_to_uint32_int (unsigned int *pres
,
840 extern void bid128_to_uint32_xint (unsigned int *pres
,
845 extern void bid128_to_uint32_floor (unsigned int *pres
,
850 extern void bid128_to_uint32_xfloor (unsigned int *pres
,
855 extern void bid128_to_uint32_ceil (unsigned int *pres
,
860 extern void bid128_to_uint32_xceil (unsigned int *pres
,
865 extern void bid128_to_int64_rnint (SINT64
* pres
,
870 extern void bid128_to_int64_xrnint (SINT64
* pres
,
875 extern void bid128_to_int64_rninta (SINT64
* pres
,
880 extern void bid128_to_int64_xrninta (SINT64
* pres
,
885 extern void bid128_to_int64_int (SINT64
* pres
,
888 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
889 extern void bid128_to_int64_xint (SINT64
* pres
,
894 extern void bid128_to_int64_floor (SINT64
* pres
,
899 extern void bid128_to_int64_xfloor (SINT64
* pres
,
904 extern void bid128_to_int64_ceil (SINT64
* pres
,
909 extern void bid128_to_int64_xceil (SINT64
* pres
,
914 extern void bid128_to_uint64_rnint (UINT64
* pres
,
919 extern void bid128_to_uint64_xrnint (UINT64
* pres
,
924 extern void bid128_to_uint64_rninta (UINT64
* pres
,
929 extern void bid128_to_uint64_xrninta (UINT64
* pres
,
934 extern void bid128_to_uint64_int (UINT64
* pres
,
939 extern void bid128_to_uint64_xint (UINT64
* pres
,
944 extern void bid128_to_uint64_floor (UINT64
* pres
,
949 extern void bid128_to_uint64_xfloor (UINT64
* pres
,
954 extern void bid128_to_uint64_ceil (UINT64
* pres
,
959 extern void bid128_to_uint64_xceil (UINT64
* pres
,
964 extern void bid64_to_int32_rnint (int *pres
,
969 extern void bid64_to_int32_xrnint (int *pres
,
974 extern void bid64_to_int32_rninta (int *pres
,
979 extern void bid64_to_int32_xrninta (int *pres
,
984 extern void bid64_to_int32_int (int *pres
,
987 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
988 extern void bid64_to_int32_xint (int *pres
,
991 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
992 extern void bid64_to_int32_floor (int *pres
,
997 extern void bid64_to_int32_xfloor (int *pres
,
1002 extern void bid64_to_int32_ceil (int *pres
,
1005 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1006 extern void bid64_to_int32_xceil (int *pres
,
1011 extern void bid64_to_int8_rnint (char *pres
,
1014 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1015 extern void bid64_to_int8_xrnint (char *pres
,
1020 extern void bid64_to_int8_rninta (char *pres
,
1025 extern void bid64_to_int8_xrninta (char *pres
,
1030 extern void bid64_to_int8_int (char *pres
,
1032 px _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
1034 extern void bid64_to_int8_xint (char *pres
,
1037 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1038 extern void bid64_to_int8_floor (char *pres
,
1041 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1042 extern void bid64_to_int8_xfloor (char *pres
,
1047 extern void bid64_to_int8_ceil (char *pres
,
1050 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1051 extern void bid64_to_int8_xceil (char *pres
,
1054 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1055 extern void bid64_to_int16_rnint (short *pres
,
1060 extern void bid64_to_int16_xrnint (short *pres
,
1065 extern void bid64_to_int16_rninta (short *pres
,
1070 extern void bid64_to_int16_xrninta (short *pres
,
1075 extern void bid64_to_int16_int (short *pres
,
1078 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1079 extern void bid64_to_int16_xint (short *pres
,
1082 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1083 extern void bid64_to_int16_floor (short *pres
,
1088 extern void bid64_to_int16_xfloor (short *pres
,
1093 extern void bid64_to_int16_ceil (short *pres
,
1096 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1097 extern void bid64_to_int16_xceil (short *pres
,
1102 extern void bid64_to_uint8_rnint (unsigned char *pres
,
1107 extern void bid64_to_uint8_xrnint (unsigned char *pres
,
1112 extern void bid64_to_uint8_rninta (unsigned char *pres
,
1117 extern void bid64_to_uint8_xrninta (unsigned char *pres
,
1122 extern void bid64_to_uint8_int (unsigned char *pres
,
1125 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1126 extern void bid64_to_uint8_xint (unsigned char *pres
,
1129 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1130 extern void bid64_to_uint8_floor (unsigned char *pres
,
1135 extern void bid64_to_uint8_xfloor (unsigned char *pres
,
1140 extern void bid64_to_uint8_ceil (unsigned char *pres
,
1143 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1144 extern void bid64_to_uint8_xceil (unsigned char *pres
,
1149 extern void bid64_to_uint16_rnint (unsigned short *pres
,
1154 extern void bid64_to_uint16_xrnint (unsigned short *pres
,
1159 extern void bid64_to_uint16_rninta (unsigned short *pres
,
1164 extern void bid64_to_uint16_xrninta (unsigned short *pres
,
1169 extern void bid64_to_uint16_int (unsigned short *pres
,
1172 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1173 extern void bid64_to_uint16_xint (unsigned short *pres
,
1178 extern void bid64_to_uint16_floor (unsigned short *pres
,
1183 extern void bid64_to_uint16_xfloor (unsigned short *pres
,
1188 extern void bid64_to_uint16_ceil (unsigned short *pres
,
1193 extern void bid64_to_uint16_xceil (unsigned short *pres
,
1198 extern void bid64_to_uint32_rnint (unsigned int *pres
,
1203 extern void bid64_to_uint32_xrnint (unsigned int *pres
,
1208 extern void bid64_to_uint32_rninta (unsigned int *pres
,
1213 extern void bid64_to_uint32_xrninta (unsigned int *pres
,
1218 extern void bid64_to_uint32_int (unsigned int *pres
,
1221 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1222 extern void bid64_to_uint32_xint (unsigned int *pres
,
1227 extern void bid64_to_uint32_floor (unsigned int *pres
,
1232 extern void bid64_to_uint32_xfloor (unsigned int *pres
,
1237 extern void bid64_to_uint32_ceil (unsigned int *pres
,
1242 extern void bid64_to_uint32_xceil (unsigned int *pres
,
1247 extern void bid64_to_int64_rnint (SINT64
* pres
,
1252 extern void bid64_to_int64_xrnint (SINT64
* pres
,
1257 extern void bid64_to_int64_rninta (SINT64
* pres
,
1262 extern void bid64_to_int64_xrninta (SINT64
* pres
,
1267 extern void bid64_to_int64_int (SINT64
* pres
,
1270 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1271 extern void bid64_to_int64_xint (SINT64
* pres
,
1274 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1275 extern void bid64_to_int64_floor (SINT64
* pres
,
1280 extern void bid64_to_int64_xfloor (SINT64
* pres
,
1285 extern void bid64_to_int64_ceil (SINT64
* pres
,
1288 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1289 extern void bid64_to_int64_xceil (SINT64
* pres
,
1294 extern void bid64_to_uint64_rnint (UINT64
* pres
,
1299 extern void bid64_to_uint64_xrnint (UINT64
* pres
,
1304 extern void bid64_to_uint64_rninta (UINT64
* pres
,
1309 extern void bid64_to_uint64_xrninta (UINT64
* pres
,
1314 extern void bid64_to_uint64_int (UINT64
* pres
,
1317 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1318 extern void bid64_to_uint64_xint (UINT64
* pres
,
1323 extern void bid64_to_uint64_floor (UINT64
* pres
,
1328 extern void bid64_to_uint64_xfloor (UINT64
* pres
,
1333 extern void bid64_to_uint64_ceil (UINT64
* pres
,
1338 extern void bid64_to_uint64_xceil (UINT64
* pres
,
1344 extern void bid64_quiet_equal (int *pres
, UINT64
* px
, UINT64
* py
1345 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
1347 extern void bid64_quiet_greater (int *pres
, UINT64
* px
,
1350 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1351 extern void bid64_quiet_greater_equal (int *pres
, UINT64
* px
,
1356 extern void bid64_quiet_greater_unordered (int *pres
, UINT64
* px
,
1361 extern void bid64_quiet_less (int *pres
, UINT64
* px
,
1363 py _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
1365 extern void bid64_quiet_less_equal (int *pres
, UINT64
* px
,
1370 extern void bid64_quiet_less_unordered (int *pres
, UINT64
* px
,
1375 extern void bid64_quiet_not_equal (int *pres
, UINT64
* px
,
1380 extern void bid64_quiet_not_greater (int *pres
, UINT64
* px
,
1385 extern void bid64_quiet_not_less (int *pres
, UINT64
* px
,
1390 extern void bid64_quiet_ordered (int *pres
, UINT64
* px
,
1393 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1394 extern void bid64_quiet_unordered (int *pres
, UINT64
* px
,
1399 extern void bid64_signaling_greater (int *pres
, UINT64
* px
,
1404 extern void bid64_signaling_greater_equal (int *pres
, UINT64
* px
,
1409 extern void bid64_signaling_greater_unordered (int *pres
,
1415 extern void bid64_signaling_less (int *pres
, UINT64
* px
,
1420 extern void bid64_signaling_less_equal (int *pres
, UINT64
* px
,
1425 extern void bid64_signaling_less_unordered (int *pres
, UINT64
* px
,
1430 extern void bid64_signaling_not_greater (int *pres
, UINT64
* px
,
1435 extern void bid64_signaling_not_less (int *pres
, UINT64
* px
,
1441 extern void bid128_quiet_equal (int *pres
, UINT128
* px
,
1444 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1445 extern void bid128_quiet_greater (int *pres
, UINT128
* px
,
1450 extern void bid128_quiet_greater_equal (int *pres
, UINT128
* px
,
1455 extern void bid128_quiet_greater_unordered (int *pres
,
1461 extern void bid128_quiet_less (int *pres
, UINT128
* px
,
1463 py _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
1465 extern void bid128_quiet_less_equal (int *pres
, UINT128
* px
,
1470 extern void bid128_quiet_less_unordered (int *pres
, UINT128
* px
,
1475 extern void bid128_quiet_not_equal (int *pres
, UINT128
* px
,
1480 extern void bid128_quiet_not_greater (int *pres
, UINT128
* px
,
1485 extern void bid128_quiet_not_less (int *pres
, UINT128
* px
,
1490 extern void bid128_quiet_ordered (int *pres
, UINT128
* px
,
1495 extern void bid128_quiet_unordered (int *pres
, UINT128
* px
,
1500 extern void bid128_signaling_greater (int *pres
, UINT128
* px
,
1505 extern void bid128_signaling_greater_equal (int *pres
,
1511 extern void bid128_signaling_greater_unordered (int *pres
,
1517 extern void bid128_signaling_less (int *pres
, UINT128
* px
,
1522 extern void bid128_signaling_less_equal (int *pres
, UINT128
* px
,
1527 extern void bid128_signaling_less_unordered (int *pres
,
1533 extern void bid128_signaling_not_greater (int *pres
, UINT128
* px
,
1538 extern void bid128_signaling_not_less (int *pres
, UINT128
* px
,
1544 extern void bid64_round_integral_exact (UINT64
* pres
, UINT64
* px
1549 extern void bid64_round_integral_nearest_even (UINT64
* pres
,
1554 extern void bid64_round_integral_negative (UINT64
* pres
,
1559 extern void bid64_round_integral_positive (UINT64
* pres
,
1564 extern void bid64_round_integral_zero (UINT64
* pres
,
1569 extern void bid64_round_integral_nearest_away (UINT64
* pres
,
1575 extern void bid128_round_integral_exact (UINT128
* pres
,
1581 extern void bid128_round_integral_nearest_even (UINT128
* pres
,
1586 extern void bid128_round_integral_negative (UINT128
* pres
,
1591 extern void bid128_round_integral_positive (UINT128
* pres
,
1596 extern void bid128_round_integral_zero (UINT128
* pres
,
1601 extern void bid128_round_integral_nearest_away (UINT128
* pres
,
1607 extern void bid64_nextup (UINT64
* pres
, UINT64
* px
1608 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
1610 extern void bid64_nextdown (UINT64
* pres
,
1612 px _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
1614 extern void bid64_nextafter (UINT64
* pres
, UINT64
* px
,
1616 py _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
1619 extern void bid128_nextup (UINT128
* pres
, UINT128
* px
1620 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
1622 extern void bid128_nextdown (UINT128
* pres
,
1624 px _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
1626 extern void bid128_nextafter (UINT128
* pres
, UINT128
* px
,
1628 py _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
1631 extern void bid64_minnum (UINT64
* pres
, UINT64
* px
, UINT64
* py
1633 extern void bid64_minnum_mag (UINT64
* pres
, UINT64
* px
,
1634 UINT64
* py _EXC_FLAGS_PARAM
);
1635 extern void bid64_maxnum (UINT64
* pres
, UINT64
* px
, UINT64
* py
1637 extern void bid64_maxnum_mag (UINT64
* pres
, UINT64
* px
,
1638 UINT64
* py _EXC_FLAGS_PARAM
);
1640 extern void bid128_minnum (UINT128
* pres
, UINT128
* px
,
1641 UINT128
* py _EXC_FLAGS_PARAM
);
1642 extern void bid128_minnum_mag (UINT128
* pres
, UINT128
* px
,
1643 UINT128
* py _EXC_FLAGS_PARAM
);
1644 extern void bid128_maxnum (UINT128
* pres
, UINT128
* px
,
1645 UINT128
* py _EXC_FLAGS_PARAM
);
1646 extern void bid128_maxnum_mag (UINT128
* pres
, UINT128
* px
,
1647 UINT128
* py _EXC_FLAGS_PARAM
);
1649 extern void bid64_from_int32 (UINT64
* pres
, int *px
1650 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1651 extern void bid64_from_uint32 (UINT64
* pres
, unsigned int *px
1652 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1653 extern void bid64_from_int64 (UINT64
* pres
, SINT64
* px
1654 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1655 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1656 extern void bid64_from_uint64 (UINT64
* pres
,
1658 px _RND_MODE_PARAM _EXC_FLAGS_PARAM
1659 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1660 extern void bid128_from_int32 (UINT128
* pres
,
1661 int *px _EXC_MASKS_PARAM
1663 extern void bid128_from_uint32 (UINT128
* pres
,
1664 unsigned int *px _EXC_MASKS_PARAM
1666 extern void bid128_from_int64 (UINT128
* pres
,
1670 extern void bid128_from_uint64 (UINT128
* pres
,
1675 extern void bid64_isSigned (int *pres
, UINT64
* px
1676 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1677 extern void bid64_isNormal (int *pres
, UINT64
* px
1678 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1679 extern void bid64_isSubnormal (int *pres
, UINT64
* px
1680 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1681 extern void bid64_isFinite (int *pres
, UINT64
* px
1682 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1683 extern void bid64_isZero (int *pres
, UINT64
* px
1684 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1685 extern void bid64_isInf (int *pres
, UINT64
* px
1686 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1687 extern void bid64_isSignaling (int *pres
, UINT64
* px
1688 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1689 extern void bid64_isCanonical (int *pres
, UINT64
* px
1690 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1691 extern void bid64_isNaN (int *pres
, UINT64
* px
1692 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1693 extern void bid64_copy (UINT64
* pres
, UINT64
* px
1694 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1695 extern void bid64_negate (UINT64
* pres
, UINT64
* px
1696 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1697 extern void bid64_abs (UINT64
* pres
, UINT64
* px
1698 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1699 extern void bid64_copySign (UINT64
* pres
, UINT64
* px
, UINT64
* py
1700 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1701 extern void bid64_class (int *pres
, UINT64
* px
1702 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1703 extern void bid64_sameQuantum (int *pres
, UINT64
* px
, UINT64
* py
1704 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1705 extern void bid64_totalOrder (int *pres
, UINT64
* px
, UINT64
* py
1706 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1707 extern void bid64_totalOrderMag (int *pres
, UINT64
* px
,
1711 extern void bid64_radix (int *pres
,
1713 px _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1715 extern void bid128_isSigned (int *pres
, UINT128
* px
1716 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1717 extern void bid128_isNormal (int *pres
, UINT128
* px
1718 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1719 extern void bid128_isSubnormal (int *pres
, UINT128
* px
1720 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1721 extern void bid128_isFinite (int *pres
, UINT128
* px
1722 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1723 extern void bid128_isZero (int *pres
, UINT128
* px
1724 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1725 extern void bid128_isInf (int *pres
, UINT128
* px
1726 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1727 extern void bid128_isSignaling (int *pres
, UINT128
* px
1728 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1729 extern void bid128_isCanonical (int *pres
, UINT128
* px
1730 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1731 extern void bid128_isNaN (int *pres
, UINT128
* px
1732 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1733 extern void bid128_copy (UINT128
* pres
, UINT128
* px
1734 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1735 extern void bid128_negate (UINT128
* pres
, UINT128
* px
1736 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1737 extern void bid128_abs (UINT128
* pres
, UINT128
* px
1738 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1739 extern void bid128_copySign (UINT128
* pres
, UINT128
* px
,
1741 py _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1742 extern void bid128_class (int *pres
,
1744 px _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1745 extern void bid128_sameQuantum (int *pres
, UINT128
* px
,
1749 extern void bid128_totalOrder (int *pres
, UINT128
* px
,
1753 extern void bid128_totalOrderMag (int *pres
, UINT128
* px
,
1757 extern void bid128_radix (int *pres
,
1759 px _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1761 extern void bid64_rem (UINT64
* pres
, UINT64
* px
, UINT64
* py
1763 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1764 extern void bid64_logb (int * pres
, UINT64
* px
1765 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
1767 extern void bid64_scalb (UINT64
* pres
, UINT64
* px
,
1768 int *pn _RND_MODE_PARAM _EXC_FLAGS_PARAM
1769 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1771 extern void bid128_rem (UINT128
* pres
, UINT128
* px
, UINT128
* py
1773 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1774 extern void bid128_logb (int * pres
, UINT128
* px
1776 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1777 extern void bid128_scalb (UINT128
* pres
, UINT128
* px
,
1778 int *pn _RND_MODE_PARAM _EXC_FLAGS_PARAM
1779 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1781 extern void bid32_to_bid64 (UINT64
* pres
,
1783 px _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
1785 extern void bid32_to_bid128 (UINT128
* pres
,
1787 px _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
1789 extern void bid64_to_bid128 (UINT128
* pres
,
1791 px _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
1793 extern void bid64_to_bid32 (UINT32
* pres
,
1795 px _RND_MODE_PARAM _EXC_FLAGS_PARAM
1796 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1797 extern void bid128_to_bid32 (UINT32
* pres
,
1799 px _RND_MODE_PARAM _EXC_FLAGS_PARAM
1800 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1801 extern void bid128_to_bid64 (UINT64
* pres
,
1803 px _RND_MODE_PARAM _EXC_FLAGS_PARAM
1804 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1806 extern void bid64_from_string (UINT64
* pres
, char *ps
1807 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1808 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1809 extern void bid64_to_string (char *ps
, UINT64
* px
1811 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1812 extern void bid128_from_string (UINT128
* pres
, char *ps
1813 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1814 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1815 extern void bid128_to_string (char *str
, UINT128
* px
1817 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1819 extern void bid64_quantize (UINT64
* pres
, UINT64
* px
,
1821 py _RND_MODE_PARAM _EXC_FLAGS_PARAM
1822 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1824 extern void bid128_quantize (UINT128
* pres
, UINT128
* px
,
1826 py _RND_MODE_PARAM _EXC_FLAGS_PARAM
1827 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1829 extern void bid128_to_binary32 (float *pres
, UINT128
* px
1830 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1831 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1833 extern void bid128_to_binary64 (double *pres
, UINT128
* px
1834 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1835 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1837 extern void bid128_to_binary80 (BINARY80
* pres
, UINT128
* px
1838 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1839 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1841 extern void bid128_to_binary128 (BINARY128
* pres
, UINT128
* px
1842 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1843 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1845 extern void binary128_to_bid32 (UINT32
* pres
, BINARY128
* px
1846 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1847 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1849 extern void binary128_to_bid64 (UINT64
* pres
, BINARY128
* px
1850 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1851 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1853 extern void binary128_to_bid128 (UINT128
* pres
, BINARY128
* px
1854 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1855 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1857 extern void bid64_to_binary32 (float *pres
, UINT64
* px
1858 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1859 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1861 extern void bid64_to_binary64 (double *pres
, UINT64
* px
1862 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1863 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1865 extern void bid64_to_binary80 (BINARY80
* pres
, UINT64
* px
1866 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1867 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1869 extern void bid64_to_binary128 (BINARY128
* pres
, UINT64
* px
1870 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1871 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1873 extern void binary64_to_bid32 (UINT32
* pres
, double *px
1874 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1875 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1877 extern void binary64_to_bid64 (UINT64
* pres
, double *px
1878 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1879 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1881 extern void binary64_to_bid128 (UINT128
* pres
, double *px
1882 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1883 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1885 extern void bid32_to_binary32 (float *pres
, UINT32
* px
1886 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1887 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1889 extern void bid32_to_binary64 (double *pres
, UINT32
* px
1890 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1891 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1893 extern void bid32_to_binary80 (BINARY80
* pres
, UINT32
* px
1894 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1895 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1897 extern void bid32_to_binary128 (BINARY128
* pres
, UINT32
* px
1898 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1899 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1901 extern void binary32_to_bid32 (UINT32
* pres
, float *px
1902 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1903 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1905 extern void binary32_to_bid64 (UINT64
* pres
, float *px
1906 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1907 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1909 extern void binary32_to_bid128 (UINT128
* pres
, float *px
1910 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1911 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1913 extern void binary80_to_bid32 (UINT32
* pres
, BINARY80
* px
1914 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1915 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1917 extern void binary80_to_bid64 (UINT64
* pres
, BINARY80
* px
1918 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1919 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1921 extern void binary80_to_bid128 (UINT128
* pres
, BINARY80
* px
1922 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1923 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1925 extern void is754 (int *retval
);
1927 extern void is754R (int *retval
);
1929 extern void signalException (_IDEC_flags
*
1930 pflagsmask _EXC_FLAGS_PARAM
);
1932 extern void lowerFlags (_IDEC_flags
* pflagsmask _EXC_FLAGS_PARAM
);
1934 extern void testFlags (_IDEC_flags
* praised
,
1935 _IDEC_flags
* pflagsmask _EXC_FLAGS_PARAM
);
1937 extern void testSavedFlags (_IDEC_flags
* praised
,
1938 _IDEC_flags
* psavedflags
,
1939 _IDEC_flags
* pflagsmask
);
1941 extern void restoreFlags (_IDEC_flags
* pflagsvalues
,
1943 pflagsmask _EXC_FLAGS_PARAM
);
1945 extern void saveFlags (_IDEC_flags
* pflagsvalues
,
1946 _IDEC_flags
* pflagsmask _EXC_FLAGS_PARAM
);
1948 void getDecimalRoundingDirection (_IDEC_round
*
1949 rounding_mode _RND_MODE_PARAM
);
1951 void setDecimalRoundingDirection (_IDEC_round
*
1952 rounding_mode _RND_MODE_PARAM
);
1956 extern UINT32
bid_to_dpd32 (UINT32 px
);
1957 extern UINT64
bid_to_dpd64 (UINT64 px
);
1958 extern UINT128
bid_to_dpd128 (UINT128 px
);
1959 extern UINT32
dpd_to_bid32 (UINT32 px
);
1960 extern UINT64
dpd_to_bid64 (UINT64 px
);
1961 extern UINT128
dpd_to_bid128 (UINT128 px
);
1963 extern UINT128
bid128dd_add (UINT64 x
, UINT64 y
1964 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1965 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1966 extern UINT128
bid128dq_add (UINT64 x
, UINT128 y
1967 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1968 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1969 extern UINT128
bid128qd_add (UINT128 x
, UINT64 y
1970 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1971 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1972 extern UINT128
bid128_add (UINT128 x
, UINT128 y
1973 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1974 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1975 extern UINT128
bid128dd_sub (UINT64 x
, UINT64 y
1976 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1977 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1978 extern UINT128
bid128dq_sub (UINT64 x
, UINT128 y
1979 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1980 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1981 extern UINT128
bid128qd_sub (UINT128 x
, UINT64 y
1982 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1983 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1984 extern UINT128
bid128_sub (UINT128 x
,
1985 UINT128 y _RND_MODE_PARAM
1986 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
1988 extern UINT128
bid128dd_mul (UINT64 x
, UINT64 y
1989 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1990 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1991 extern UINT128
bid128dq_mul (UINT64 x
, UINT128 y
1992 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1993 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1994 extern UINT128
bid128qd_mul (UINT128 x
, UINT64 y
1995 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1996 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
1997 extern UINT128
bid128_mul (UINT128 x
, UINT128 y
1998 _RND_MODE_PARAM _EXC_FLAGS_PARAM
1999 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2000 extern UINT128
bid128_div (UINT128 x
,
2001 UINT128 y _RND_MODE_PARAM
2002 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
2004 extern UINT128
bid128dd_div (UINT64 x
, UINT64 y
2005 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2006 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2007 extern UINT128
bid128dq_div (UINT64 x
, UINT128 y
2008 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2009 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2010 extern UINT128
bid128qd_div (UINT128 x
, UINT64 y
2011 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2012 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2013 extern UINT128
bid128_fma (UINT128 x
, UINT128 y
, UINT128 z
2014 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2015 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2016 extern UINT128
bid128ddd_fma (UINT64 x
, UINT64 y
, UINT64 z
2017 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2018 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2019 extern UINT128
bid128ddq_fma (UINT64 x
, UINT64 y
, UINT128 z
2020 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2021 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2022 extern UINT128
bid128dqd_fma (UINT64 x
, UINT128 y
, UINT64 z
2023 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2024 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2025 extern UINT128
bid128dqq_fma (UINT64 x
, UINT128 y
,
2027 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2028 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2029 extern UINT128
bid128qdd_fma (UINT128 x
, UINT64 y
, UINT64 z
2030 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2031 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2032 extern UINT128
bid128qdq_fma (UINT128 x
, UINT64 y
,
2034 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2035 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2036 extern UINT128
bid128qqd_fma (UINT128 x
, UINT128 y
,
2038 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2039 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2040 // Note: bid128qqq_fma is represented by bid128_fma
2041 // Note: bid64ddd_fma is represented by bid64_fma
2042 extern UINT64
bid64ddq_fma (UINT64 x
, UINT64 y
,
2044 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2045 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2046 extern UINT64
bid64dqd_fma (UINT64 x
, UINT128 y
,
2048 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2049 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2050 extern UINT64
bid64dqq_fma (UINT64 x
, UINT128 y
,
2052 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2053 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2054 extern UINT64
bid64qdd_fma (UINT128 x
, UINT64 y
,
2056 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2057 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2058 extern UINT64
bid64qdq_fma (UINT128 x
, UINT64 y
,
2060 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2061 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2062 extern UINT64
bid64qqd_fma (UINT128 x
, UINT128 y
,
2064 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2065 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2066 extern UINT64
bid64qqq_fma (UINT128 x
, UINT128 y
,
2068 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2069 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2071 extern UINT128
bid128_sqrt (UINT128 x _RND_MODE_PARAM
2072 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
2074 extern UINT128
bid128d_sqrt (UINT64 x
2075 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2076 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2078 extern UINT64
bid64_add (UINT64 x
, UINT64 y
2079 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2080 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2081 extern UINT64
bid64dq_add (UINT64 x
, UINT128 y
2082 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2083 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2084 extern UINT64
bid64qd_add (UINT128 x
, UINT64 y
2085 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2086 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2087 extern UINT64
bid64qq_add (UINT128 x
, UINT128 y
2088 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2089 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2090 extern UINT64
bid64_sub (UINT64 x
,
2091 UINT64 y _RND_MODE_PARAM
2092 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
2094 extern UINT64
bid64dq_sub (UINT64 x
, UINT128 y
2095 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2096 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2097 extern UINT64
bid64qd_sub (UINT128 x
, UINT64 y
2098 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2099 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2100 extern UINT64
bid64qq_sub (UINT128 x
, UINT128 y
2101 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2102 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2103 extern UINT64
bid64_mul (UINT64 x
, UINT64 y
2104 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2105 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2106 extern UINT64
bid64dq_mul (UINT64 x
, UINT128 y
2107 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2108 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2109 extern UINT64
bid64qd_mul (UINT128 x
, UINT64 y
2110 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2111 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2112 extern UINT64
bid64qq_mul (UINT128 x
, UINT128 y
2113 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2114 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2115 extern UINT64
bid64_div (UINT64 x
,
2116 UINT64 y _RND_MODE_PARAM
2117 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
2119 extern UINT64
bid64dq_div (UINT64 x
, UINT128 y
2120 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2121 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2122 extern UINT64
bid64qd_div (UINT128 x
, UINT64 y
2123 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2124 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2125 extern UINT64
bid64qq_div (UINT128 x
, UINT128 y
2126 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2127 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2128 extern UINT64
bid64_fma (UINT64 x
, UINT64 y
,
2129 UINT64 z _RND_MODE_PARAM
2130 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
2132 extern UINT64
bid64_sqrt (UINT64 x _RND_MODE_PARAM
2133 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
2135 extern UINT64
bid64q_sqrt (UINT128 x
2136 _RND_MODE_PARAM _EXC_FLAGS_PARAM
2137 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2139 extern char bid128_to_int8_rnint (UINT128 x
2143 extern char bid128_to_int8_xrnint (UINT128 x
2147 extern char bid128_to_int8_rninta (UINT128 x
2151 extern char bid128_to_int8_xrninta (UINT128 x
2155 extern char bid128_to_int8_int (UINT128 x _EXC_FLAGS_PARAM
2156 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2157 extern char bid128_to_int8_xint (UINT128 x _EXC_FLAGS_PARAM
2158 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2159 extern char bid128_to_int8_floor (UINT128 x
2163 extern char bid128_to_int8_xfloor (UINT128 x
2167 extern char bid128_to_int8_ceil (UINT128 x _EXC_FLAGS_PARAM
2168 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2169 extern char bid128_to_int8_xceil (UINT128 x
2173 extern short bid128_to_int16_rnint (UINT128 x
2177 extern short bid128_to_int16_xrnint (UINT128 x
2181 extern short bid128_to_int16_rninta (UINT128 x
2185 extern short bid128_to_int16_xrninta (UINT128 x
2189 extern short bid128_to_int16_int (UINT128 x _EXC_FLAGS_PARAM
2192 extern short bid128_to_int16_xint (UINT128 x _EXC_FLAGS_PARAM
2195 extern short bid128_to_int16_floor (UINT128 x
2199 extern short bid128_to_int16_xfloor (UINT128 x
2203 extern short bid128_to_int16_ceil (UINT128 x _EXC_FLAGS_PARAM
2206 extern short bid128_to_int16_xceil (UINT128 x
2210 extern unsigned char bid128_to_uint8_rnint (UINT128 x
2214 extern unsigned char bid128_to_uint8_xrnint (UINT128 x
2218 extern unsigned char bid128_to_uint8_rninta (UINT128 x
2222 extern unsigned char bid128_to_uint8_xrninta (UINT128 x
2226 extern unsigned char bid128_to_uint8_int (UINT128 x
2230 extern unsigned char bid128_to_uint8_xint (UINT128 x
2234 extern unsigned char bid128_to_uint8_floor (UINT128 x
2238 extern unsigned char bid128_to_uint8_xfloor (UINT128 x
2242 extern unsigned char bid128_to_uint8_ceil (UINT128 x
2246 extern unsigned char bid128_to_uint8_xceil (UINT128 x
2250 extern unsigned short bid128_to_uint16_rnint (UINT128 x
2254 extern unsigned short bid128_to_uint16_xrnint (UINT128 x
2258 extern unsigned short bid128_to_uint16_rninta (UINT128 x
2262 extern unsigned short bid128_to_uint16_xrninta (UINT128 x
2266 extern unsigned short bid128_to_uint16_int (UINT128 x
2270 extern unsigned short bid128_to_uint16_xint (UINT128 x
2274 extern unsigned short bid128_to_uint16_floor (UINT128 x
2278 extern unsigned short bid128_to_uint16_xfloor (UINT128 x
2282 extern unsigned short bid128_to_uint16_ceil (UINT128 x
2286 extern unsigned short bid128_to_uint16_xceil (UINT128 x
2290 extern int bid128_to_int32_rnint (UINT128 x _EXC_FLAGS_PARAM
2293 extern int bid128_to_int32_xrnint (UINT128 x _EXC_FLAGS_PARAM
2296 extern int bid128_to_int32_rninta (UINT128 x _EXC_FLAGS_PARAM
2299 extern int bid128_to_int32_xrninta (UINT128 x _EXC_FLAGS_PARAM
2302 extern int bid128_to_int32_int (UINT128 x _EXC_FLAGS_PARAM
2303 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2304 extern int bid128_to_int32_xint (UINT128 x _EXC_FLAGS_PARAM
2305 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2306 extern int bid128_to_int32_floor (UINT128 x _EXC_FLAGS_PARAM
2309 extern int bid128_to_int32_xfloor (UINT128 x _EXC_FLAGS_PARAM
2312 extern int bid128_to_int32_ceil (UINT128 x _EXC_FLAGS_PARAM
2313 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2314 extern int bid128_to_int32_xceil (UINT128 x _EXC_FLAGS_PARAM
2317 extern unsigned int bid128_to_uint32_rnint (UINT128 x
2321 extern unsigned int bid128_to_uint32_xrnint (UINT128 x
2325 extern unsigned int bid128_to_uint32_rninta (UINT128 x
2329 extern unsigned int bid128_to_uint32_xrninta (UINT128 x
2333 extern unsigned int bid128_to_uint32_int (UINT128 x
2337 extern unsigned int bid128_to_uint32_xint (UINT128 x
2341 extern unsigned int bid128_to_uint32_floor (UINT128 x
2345 extern unsigned int bid128_to_uint32_xfloor (UINT128 x
2349 extern unsigned int bid128_to_uint32_ceil (UINT128 x
2353 extern unsigned int bid128_to_uint32_xceil (UINT128 x
2357 extern SINT64
bid128_to_int64_rnint (UINT128 x _EXC_FLAGS_PARAM
2360 extern SINT64
bid128_to_int64_xrnint (UINT128 x _EXC_FLAGS_PARAM
2363 extern SINT64
bid128_to_int64_rninta (UINT128 x _EXC_FLAGS_PARAM
2366 extern SINT64
bid128_to_int64_xrninta (UINT128 x _EXC_FLAGS_PARAM
2369 extern SINT64
bid128_to_int64_int (UINT128 x _EXC_FLAGS_PARAM
2372 extern SINT64
bid128_to_int64_xint (UINT128 x _EXC_FLAGS_PARAM
2375 extern SINT64
bid128_to_int64_floor (UINT128 x _EXC_FLAGS_PARAM
2378 extern SINT64
bid128_to_int64_xfloor (UINT128 x _EXC_FLAGS_PARAM
2381 extern SINT64
bid128_to_int64_ceil (UINT128 x _EXC_FLAGS_PARAM
2384 extern SINT64
bid128_to_int64_xceil (UINT128 x _EXC_FLAGS_PARAM
2387 extern UINT64
bid128_to_uint64_rnint (UINT128 x _EXC_FLAGS_PARAM
2390 extern UINT64
bid128_to_uint64_xrnint (UINT128 x _EXC_FLAGS_PARAM
2393 extern UINT64
bid128_to_uint64_rninta (UINT128 x _EXC_FLAGS_PARAM
2396 extern UINT64
bid128_to_uint64_xrninta (UINT128 x _EXC_FLAGS_PARAM
2399 extern UINT64
bid128_to_uint64_int (UINT128 x _EXC_FLAGS_PARAM
2402 extern UINT64
bid128_to_uint64_xint (UINT128 x _EXC_FLAGS_PARAM
2405 extern UINT64
bid128_to_uint64_floor (UINT128 x _EXC_FLAGS_PARAM
2408 extern UINT64
bid128_to_uint64_xfloor (UINT128 x _EXC_FLAGS_PARAM
2411 extern UINT64
bid128_to_uint64_ceil (UINT128 x _EXC_FLAGS_PARAM
2414 extern UINT64
bid128_to_uint64_xceil (UINT128 x _EXC_FLAGS_PARAM
2417 extern int bid64_to_int32_rnint (UINT64 x _EXC_FLAGS_PARAM
2418 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2419 extern int bid64_to_int32_xrnint (UINT64 x _EXC_FLAGS_PARAM
2422 extern int bid64_to_int32_rninta (UINT64 x _EXC_FLAGS_PARAM
2425 extern int bid64_to_int32_xrninta (UINT64 x _EXC_FLAGS_PARAM
2428 extern int bid64_to_int32_int (UINT64 x _EXC_FLAGS_PARAM
2429 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2430 extern int bid64_to_int32_xint (UINT64 x _EXC_FLAGS_PARAM
2431 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2432 extern int bid64_to_int32_floor (UINT64 x _EXC_FLAGS_PARAM
2433 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2434 extern int bid64_to_int32_xfloor (UINT64 x _EXC_FLAGS_PARAM
2437 extern int bid64_to_int32_ceil (UINT64 x _EXC_FLAGS_PARAM
2438 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2439 extern int bid64_to_int32_xceil (UINT64 x _EXC_FLAGS_PARAM
2440 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2441 extern char bid64_to_int8_rnint (UINT64 x _EXC_FLAGS_PARAM
2442 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2443 extern char bid64_to_int8_xrnint (UINT64 x _EXC_FLAGS_PARAM
2446 extern char bid64_to_int8_rninta (UINT64 x _EXC_FLAGS_PARAM
2449 extern char bid64_to_int8_xrninta (UINT64 x _EXC_FLAGS_PARAM
2452 extern char bid64_to_int8_int (UINT64 x _EXC_FLAGS_PARAM
2453 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2454 extern char bid64_to_int8_xint (UINT64 x _EXC_FLAGS_PARAM
2455 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2456 extern char bid64_to_int8_floor (UINT64 x _EXC_FLAGS_PARAM
2457 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2458 extern char bid64_to_int8_xfloor (UINT64 x _EXC_FLAGS_PARAM
2461 extern char bid64_to_int8_ceil (UINT64 x _EXC_FLAGS_PARAM
2462 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2463 extern char bid64_to_int8_xceil (UINT64 x _EXC_FLAGS_PARAM
2464 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2465 extern short bid64_to_int16_rnint (UINT64 x _EXC_FLAGS_PARAM
2468 extern short bid64_to_int16_xrnint (UINT64 x _EXC_FLAGS_PARAM
2471 extern short bid64_to_int16_rninta (UINT64 x _EXC_FLAGS_PARAM
2474 extern short bid64_to_int16_xrninta (UINT64 x _EXC_FLAGS_PARAM
2477 extern short bid64_to_int16_int (UINT64 x _EXC_FLAGS_PARAM
2478 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2479 extern short bid64_to_int16_xint (UINT64 x _EXC_FLAGS_PARAM
2482 extern short bid64_to_int16_floor (UINT64 x _EXC_FLAGS_PARAM
2485 extern short bid64_to_int16_xfloor (UINT64 x _EXC_FLAGS_PARAM
2488 extern short bid64_to_int16_ceil (UINT64 x _EXC_FLAGS_PARAM
2491 extern short bid64_to_int16_xceil (UINT64 x _EXC_FLAGS_PARAM
2494 extern unsigned char bid64_to_uint8_rnint (UINT64 x
2498 extern unsigned char bid64_to_uint8_xrnint (UINT64 x
2502 extern unsigned char bid64_to_uint8_rninta (UINT64 x
2506 extern unsigned char bid64_to_uint8_xrninta (UINT64 x
2510 extern unsigned char bid64_to_uint8_int (UINT64 x _EXC_FLAGS_PARAM
2513 extern unsigned char bid64_to_uint8_xint (UINT64 x _EXC_FLAGS_PARAM
2516 extern unsigned char bid64_to_uint8_floor (UINT64 x
2520 extern unsigned char bid64_to_uint8_xfloor (UINT64 x
2524 extern unsigned char bid64_to_uint8_ceil (UINT64 x _EXC_FLAGS_PARAM
2527 extern unsigned char bid64_to_uint8_xceil (UINT64 x
2531 extern unsigned short bid64_to_uint16_rnint (UINT64 x
2535 extern unsigned short bid64_to_uint16_xrnint (UINT64 x
2539 extern unsigned short bid64_to_uint16_rninta (UINT64 x
2543 extern unsigned short bid64_to_uint16_xrninta (UINT64 x
2547 extern unsigned short bid64_to_uint16_int (UINT64 x
2551 extern unsigned short bid64_to_uint16_xint (UINT64 x
2555 extern unsigned short bid64_to_uint16_floor (UINT64 x
2559 extern unsigned short bid64_to_uint16_xfloor (UINT64 x
2563 extern unsigned short bid64_to_uint16_ceil (UINT64 x
2567 extern unsigned short bid64_to_uint16_xceil (UINT64 x
2571 extern unsigned int bid64_to_uint32_rnint (UINT64 x
2575 extern unsigned int bid64_to_uint32_xrnint (UINT64 x
2579 extern unsigned int bid64_to_uint32_rninta (UINT64 x
2583 extern unsigned int bid64_to_uint32_xrninta (UINT64 x
2587 extern unsigned int bid64_to_uint32_int (UINT64 x _EXC_FLAGS_PARAM
2590 extern unsigned int bid64_to_uint32_xint (UINT64 x _EXC_FLAGS_PARAM
2593 extern unsigned int bid64_to_uint32_floor (UINT64 x
2597 extern unsigned int bid64_to_uint32_xfloor (UINT64 x
2601 extern unsigned int bid64_to_uint32_ceil (UINT64 x _EXC_FLAGS_PARAM
2604 extern unsigned int bid64_to_uint32_xceil (UINT64 x
2608 extern SINT64
bid64_to_int64_rnint (UINT64 x _EXC_FLAGS_PARAM
2611 extern SINT64
bid64_to_int64_xrnint (UINT64 x _EXC_FLAGS_PARAM
2614 extern SINT64
bid64_to_int64_rninta (UINT64 x _EXC_FLAGS_PARAM
2617 extern SINT64
bid64_to_int64_xrninta (UINT64 x _EXC_FLAGS_PARAM
2620 extern SINT64
bid64_to_int64_int (UINT64 x _EXC_FLAGS_PARAM
2623 extern SINT64
bid64_to_int64_xint (UINT64 x _EXC_FLAGS_PARAM
2626 extern SINT64
bid64_to_int64_floor (UINT64 x _EXC_FLAGS_PARAM
2629 extern SINT64
bid64_to_int64_xfloor (UINT64 x _EXC_FLAGS_PARAM
2632 extern SINT64
bid64_to_int64_ceil (UINT64 x _EXC_FLAGS_PARAM
2635 extern SINT64
bid64_to_int64_xceil (UINT64 x _EXC_FLAGS_PARAM
2638 extern UINT64
bid64_to_uint64_rnint (UINT64 x _EXC_FLAGS_PARAM
2641 extern UINT64
bid64_to_uint64_xrnint (UINT64 x _EXC_FLAGS_PARAM
2644 extern UINT64
bid64_to_uint64_rninta (UINT64 x _EXC_FLAGS_PARAM
2647 extern UINT64
bid64_to_uint64_xrninta (UINT64 x _EXC_FLAGS_PARAM
2650 extern UINT64
bid64_to_uint64_int (UINT64 x _EXC_FLAGS_PARAM
2653 extern UINT64
bid64_to_uint64_xint (UINT64 x _EXC_FLAGS_PARAM
2656 extern UINT64
bid64_to_uint64_floor (UINT64 x _EXC_FLAGS_PARAM
2659 extern UINT64
bid64_to_uint64_xfloor (UINT64 x _EXC_FLAGS_PARAM
2662 extern UINT64
bid64_to_uint64_ceil (UINT64 x _EXC_FLAGS_PARAM
2665 extern UINT64
bid64_to_uint64_xceil (UINT64 x _EXC_FLAGS_PARAM
2669 extern int bid64_quiet_equal (UINT64 x
, UINT64 y
2670 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
2672 extern int bid64_quiet_greater (UINT64 x
,
2673 UINT64 y _EXC_FLAGS_PARAM
2674 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2675 extern int bid64_quiet_greater_equal (UINT64 x
,
2676 UINT64 y _EXC_FLAGS_PARAM
2679 extern int bid64_quiet_greater_unordered (UINT64 x
,
2680 UINT64 y _EXC_FLAGS_PARAM
2683 extern int bid64_quiet_less (UINT64 x
,
2684 UINT64 y _EXC_FLAGS_PARAM
2685 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2686 extern int bid64_quiet_less_equal (UINT64 x
,
2687 UINT64 y _EXC_FLAGS_PARAM
2690 extern int bid64_quiet_less_unordered (UINT64 x
,
2691 UINT64 y _EXC_FLAGS_PARAM
2694 extern int bid64_quiet_not_equal (UINT64 x
,
2695 UINT64 y _EXC_FLAGS_PARAM
2698 extern int bid64_quiet_not_greater (UINT64 x
,
2699 UINT64 y _EXC_FLAGS_PARAM
2702 extern int bid64_quiet_not_less (UINT64 x
,
2703 UINT64 y _EXC_FLAGS_PARAM
2704 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2705 extern int bid64_quiet_ordered (UINT64 x
,
2706 UINT64 y _EXC_FLAGS_PARAM
2707 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2708 extern int bid64_quiet_unordered (UINT64 x
,
2709 UINT64 y _EXC_FLAGS_PARAM
2712 extern int bid64_signaling_greater (UINT64 x
,
2713 UINT64 y _EXC_FLAGS_PARAM
2716 extern int bid64_signaling_greater_equal (UINT64 x
,
2717 UINT64 y _EXC_FLAGS_PARAM
2720 extern int bid64_signaling_greater_unordered (UINT64 x
,
2725 extern int bid64_signaling_less (UINT64 x
,
2726 UINT64 y _EXC_FLAGS_PARAM
2727 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2728 extern int bid64_signaling_less_equal (UINT64 x
,
2729 UINT64 y _EXC_FLAGS_PARAM
2732 extern int bid64_signaling_less_unordered (UINT64 x
,
2737 extern int bid64_signaling_not_greater (UINT64 x
,
2738 UINT64 y _EXC_FLAGS_PARAM
2741 extern int bid64_signaling_not_less (UINT64 x
,
2742 UINT64 y _EXC_FLAGS_PARAM
2746 extern int bid128_quiet_equal (UINT128 x
, UINT128 y
2747 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
2749 extern int bid128_quiet_greater (UINT128 x
,
2750 UINT128 y _EXC_FLAGS_PARAM
2751 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2752 extern int bid128_quiet_greater_equal (UINT128 x
,
2753 UINT128 y _EXC_FLAGS_PARAM
2756 extern int bid128_quiet_greater_unordered (UINT128 x
,
2761 extern int bid128_quiet_less (UINT128 x
,
2762 UINT128 y _EXC_FLAGS_PARAM
2763 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2764 extern int bid128_quiet_less_equal (UINT128 x
,
2765 UINT128 y _EXC_FLAGS_PARAM
2768 extern int bid128_quiet_less_unordered (UINT128 x
,
2769 UINT128 y _EXC_FLAGS_PARAM
2772 extern int bid128_quiet_not_equal (UINT128 x
,
2773 UINT128 y _EXC_FLAGS_PARAM
2776 extern int bid128_quiet_not_greater (UINT128 x
,
2777 UINT128 y _EXC_FLAGS_PARAM
2780 extern int bid128_quiet_not_less (UINT128 x
,
2781 UINT128 y _EXC_FLAGS_PARAM
2784 extern int bid128_quiet_ordered (UINT128 x
,
2785 UINT128 y _EXC_FLAGS_PARAM
2786 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2787 extern int bid128_quiet_unordered (UINT128 x
,
2788 UINT128 y _EXC_FLAGS_PARAM
2791 extern int bid128_signaling_greater (UINT128 x
,
2792 UINT128 y _EXC_FLAGS_PARAM
2795 extern int bid128_signaling_greater_equal (UINT128 x
,
2800 extern int bid128_signaling_greater_unordered (UINT128 x
,
2805 extern int bid128_signaling_less (UINT128 x
,
2806 UINT128 y _EXC_FLAGS_PARAM
2809 extern int bid128_signaling_less_equal (UINT128 x
,
2810 UINT128 y _EXC_FLAGS_PARAM
2813 extern int bid128_signaling_less_unordered (UINT128 x
,
2818 extern int bid128_signaling_not_greater (UINT128 x
,
2819 UINT128 y _EXC_FLAGS_PARAM
2822 extern int bid128_signaling_not_less (UINT128 x
,
2823 UINT128 y _EXC_FLAGS_PARAM
2827 extern UINT64
bid64_round_integral_exact (UINT64 x
2832 extern UINT64
bid64_round_integral_nearest_even (UINT64 x
2836 extern UINT64
bid64_round_integral_negative (UINT64 x
2840 extern UINT64
bid64_round_integral_positive (UINT64 x
2844 extern UINT64
bid64_round_integral_zero (UINT64 x _EXC_FLAGS_PARAM
2847 extern UINT64
bid64_round_integral_nearest_away (UINT64 x
2852 extern UINT128
bid128_round_integral_exact (UINT128 x
2857 extern UINT128
bid128_round_integral_nearest_even (UINT128 x
2861 extern UINT128
bid128_round_integral_negative (UINT128 x
2865 extern UINT128
bid128_round_integral_positive (UINT128 x
2869 extern UINT128
bid128_round_integral_zero (UINT128 x
2873 extern UINT128
bid128_round_integral_nearest_away (UINT128 x
2878 extern UINT64
bid64_nextup (UINT64 x
2879 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
2881 extern UINT64
bid64_nextdown (UINT64 x _EXC_FLAGS_PARAM
2882 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2883 extern UINT64
bid64_nextafter (UINT64 x
,
2884 UINT64 y _EXC_FLAGS_PARAM
2885 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2887 extern UINT128
bid128_nextup (UINT128 x
2888 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
2890 extern UINT128
bid128_nextdown (UINT128 x _EXC_FLAGS_PARAM
2891 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2892 extern UINT128
bid128_nextafter (UINT128 x
,
2893 UINT128 y _EXC_FLAGS_PARAM
2894 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2896 extern UINT64
bid64_minnum (UINT64 x
, UINT64 y _EXC_FLAGS_PARAM
);
2897 extern UINT64
bid64_minnum_mag (UINT64 x
,
2898 UINT64 y _EXC_FLAGS_PARAM
);
2899 extern UINT64
bid64_maxnum (UINT64 x
, UINT64 y _EXC_FLAGS_PARAM
);
2900 extern UINT64
bid64_maxnum_mag (UINT64 x
,
2901 UINT64 y _EXC_FLAGS_PARAM
);
2903 extern UINT128
bid128_minnum (UINT128 x
,
2904 UINT128 y _EXC_FLAGS_PARAM
);
2905 extern UINT128
bid128_minnum_mag (UINT128 x
,
2906 UINT128 y _EXC_FLAGS_PARAM
);
2907 extern UINT128
bid128_maxnum (UINT128 x
,
2908 UINT128 y _EXC_FLAGS_PARAM
);
2909 extern UINT128
bid128_maxnum_mag (UINT128 x
,
2910 UINT128 y _EXC_FLAGS_PARAM
);
2912 extern UINT64
bid64_from_int32 (int x _EXC_MASKS_PARAM
2914 extern UINT64
bid64_from_uint32 (unsigned int x _EXC_MASKS_PARAM
2916 extern UINT64
bid64_from_int64 (SINT64 x _RND_MODE_PARAM
2917 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
2919 extern UINT64
bid64_from_uint64 (UINT64 _RND_MODE_PARAM
2920 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
2922 extern UINT128
bid128_from_int32 (int x _EXC_MASKS_PARAM
2924 extern UINT128
bid128_from_uint32 (unsigned int x _EXC_MASKS_PARAM
2926 extern UINT128
bid128_from_int64 (SINT64 x _EXC_MASKS_PARAM
2928 extern UINT128
bid128_from_uint64 (UINT64 x _EXC_MASKS_PARAM
2931 extern int bid64_isSigned (UINT64 x _EXC_MASKS_PARAM
2933 extern int bid64_isNormal (UINT64 x _EXC_MASKS_PARAM
2935 extern int bid64_isSubnormal (UINT64 x _EXC_MASKS_PARAM
2937 extern int bid64_isFinite (UINT64 x _EXC_MASKS_PARAM
2939 extern int bid64_isZero (UINT64 x _EXC_MASKS_PARAM
2941 extern int bid64_isInf (UINT64 x _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2942 extern int bid64_isSignaling (UINT64 x _EXC_MASKS_PARAM
2944 extern int bid64_isCanonical (UINT64 x _EXC_MASKS_PARAM
2946 extern int bid64_isNaN (UINT64 x _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2947 extern UINT64
bid64_copy (UINT64 x _EXC_MASKS_PARAM
2949 extern UINT64
bid64_negate (UINT64 x _EXC_MASKS_PARAM
2951 extern UINT64
bid64_abs (UINT64 x _EXC_MASKS_PARAM
2953 extern UINT64
bid64_copySign (UINT64 x
,
2954 UINT64 y _EXC_MASKS_PARAM
2956 extern int bid64_class (UINT64 x _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2957 extern int bid64_sameQuantum (UINT64 x
, UINT64 y
2958 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2959 extern int bid64_totalOrder (UINT64 x
, UINT64 y
2960 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2961 extern int bid64_totalOrderMag (UINT64 x
, UINT64 y
2962 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2963 extern int bid64_radix (UINT64 x _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
2965 extern int bid128_isSigned (UINT128 x _EXC_MASKS_PARAM
2967 extern int bid128_isNormal (UINT128 x _EXC_MASKS_PARAM
2969 extern int bid128_isSubnormal (UINT128 x _EXC_MASKS_PARAM
2971 extern int bid128_isFinite (UINT128 x _EXC_MASKS_PARAM
2973 extern int bid128_isZero (UINT128 x _EXC_MASKS_PARAM
2975 extern int bid128_isInf (UINT128 x _EXC_MASKS_PARAM
2977 extern int bid128_isSignaling (UINT128 x _EXC_MASKS_PARAM
2979 extern int bid128_isCanonical (UINT128 x _EXC_MASKS_PARAM
2981 extern int bid128_isNaN (UINT128 x _EXC_MASKS_PARAM
2983 extern UINT128
bid128_copy (UINT128 x _EXC_MASKS_PARAM
2985 extern UINT128
bid128_negate (UINT128 x _EXC_MASKS_PARAM
2987 extern UINT128
bid128_abs (UINT128 x _EXC_MASKS_PARAM
2989 extern UINT128
bid128_copySign (UINT128 x
,
2990 UINT128 y _EXC_MASKS_PARAM
2992 extern int bid128_class (UINT128 x _EXC_MASKS_PARAM
2994 extern int bid128_sameQuantum (UINT128 x
,
2995 UINT128 y _EXC_MASKS_PARAM
2997 extern int bid128_totalOrder (UINT128 x
,
2998 UINT128 y _EXC_MASKS_PARAM
3000 extern int bid128_totalOrderMag (UINT128 x
,
3001 UINT128 y _EXC_MASKS_PARAM
3003 extern int bid128_radix (UINT128 x _EXC_MASKS_PARAM
3006 extern UINT64
bid64_rem (UINT64 x
, UINT64 y
3008 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3009 extern int bid64_logb (UINT64 x _EXC_FLAGS_PARAM
3010 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3011 extern UINT64
bid64_scalb (UINT64 x
,
3012 int n _RND_MODE_PARAM _EXC_FLAGS_PARAM
3013 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3015 extern UINT128
bid128_rem (UINT128 x
, UINT128 y
3017 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3018 extern int bid128_logb (UINT128 x
3019 _EXC_FLAGS_PARAM _EXC_MASKS_PARAM
3021 extern UINT128
bid128_scalb (UINT128 x
,
3022 int n _RND_MODE_PARAM _EXC_FLAGS_PARAM
3023 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3025 extern UINT64
bid32_to_bid64 (UINT32 x _EXC_FLAGS_PARAM
3026 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3027 extern UINT128
bid32_to_bid128 (UINT32 x _EXC_FLAGS_PARAM
3028 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3029 extern UINT128
bid64_to_bid128 (UINT64 x _EXC_FLAGS_PARAM
3030 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3031 extern UINT32
bid64_to_bid32 (UINT64 x
3032 _RND_MODE_PARAM _EXC_FLAGS_PARAM
3033 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3034 extern UINT32
bid128_to_bid32 (UINT128 x _RND_MODE_PARAM
3036 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3037 extern UINT64
bid128_to_bid64 (UINT128 x _RND_MODE_PARAM
3039 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3041 extern void bid64_to_string (char *ps
, UINT64 x
3043 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3044 extern UINT64
bid64_from_string (char *ps
3045 _RND_MODE_PARAM _EXC_FLAGS_PARAM
3046 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3047 extern void bid128_to_string (char *str
, UINT128 x
3049 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3050 extern UINT128
bid128_from_string (char *ps
3051 _RND_MODE_PARAM _EXC_FLAGS_PARAM
3055 extern UINT64
bid64_quantize (UINT64 x
, UINT64 y
3056 _RND_MODE_PARAM _EXC_FLAGS_PARAM
3057 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3059 extern UINT128
bid128_quantize (UINT128 x
, UINT128 y
3062 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3065 extern UINT32
binary128_to_bid32 (BINARY128 x
3071 extern UINT64
binary128_to_bid64 (BINARY128 x
3077 extern UINT128
binary128_to_bid128 (BINARY128 x
3083 extern UINT32
binary64_to_bid32 (double x
3086 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3088 extern UINT64
binary64_to_bid64 (double x
3091 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3093 extern UINT128
binary64_to_bid128 (double x
3099 extern UINT32
binary80_to_bid32 (BINARY80 x
3102 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3104 extern UINT64
binary80_to_bid64 (BINARY80 x
3107 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3109 extern UINT128
binary80_to_bid128 (BINARY80 x
3115 extern UINT32
binary32_to_bid32 (float x
3118 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3120 extern UINT64
binary32_to_bid64 (float x
3123 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3125 extern UINT128
binary32_to_bid128 (float x
3131 extern float bid128_to_binary32 (UINT128 x
3132 _RND_MODE_PARAM _EXC_FLAGS_PARAM
3133 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3135 extern double bid128_to_binary64 (UINT128 x
3136 _RND_MODE_PARAM _EXC_FLAGS_PARAM
3140 extern BINARY80
bid128_to_binary80 (UINT128 x
3146 extern BINARY128
bid128_to_binary128 (UINT128 x
3152 extern float bid64_to_binary32 (UINT64 x
3153 _RND_MODE_PARAM _EXC_FLAGS_PARAM
3154 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3156 extern double bid64_to_binary64 (UINT64 x
3157 _RND_MODE_PARAM _EXC_FLAGS_PARAM
3158 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3160 extern BINARY80
bid64_to_binary80 (UINT64 x
3166 extern BINARY128
bid64_to_binary128 (UINT64 x
3172 extern float bid32_to_binary32 (UINT32 x
3173 _RND_MODE_PARAM _EXC_FLAGS_PARAM
3174 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3176 extern double bid32_to_binary64 (UINT32 x
3177 _RND_MODE_PARAM _EXC_FLAGS_PARAM
3178 _EXC_MASKS_PARAM _EXC_INFO_PARAM
);
3180 extern BINARY80
bid32_to_binary80 (UINT32 x
3186 extern BINARY128
bid32_to_binary128 (UINT32 x
3192 extern int is754 (void);
3194 extern int is754R (void);
3196 extern void signalException (_IDEC_flags flagsmask
3199 extern void lowerFlags (_IDEC_flags flagsmask _EXC_FLAGS_PARAM
);
3201 extern _IDEC_flags
testFlags (_IDEC_flags flagsmask
3204 extern _IDEC_flags
testSavedFlags (_IDEC_flags savedflags
,
3205 _IDEC_flags flagsmask
);
3207 extern void restoreFlags (_IDEC_flags flagsvalues
,
3208 _IDEC_flags flagsmask _EXC_FLAGS_PARAM
);
3210 extern _IDEC_flags
saveFlags (_IDEC_flags flagsmask
3213 #if !DECIMAL_GLOBAL_ROUNDING
3214 _IDEC_round
getDecimalRoundingDirection (_IDEC_round rnd_mode
);
3216 _IDEC_round
getDecimalRoundingDirection (void);
3219 #if !DECIMAL_GLOBAL_ROUNDING
3220 _IDEC_round
setDecimalRoundingDirection (_IDEC_round
3224 void setDecimalRoundingDirection (_IDEC_round rounding_mode
);
3229 // Internal Functions
3232 round64_2_18 (int q
,
3237 int *ptr_is_midpoint_lt_even
,
3238 int *ptr_is_midpoint_gt_even
,
3239 int *ptr_is_inexact_lt_midpoint
,
3240 int *ptr_is_inexact_gt_midpoint
);
3243 round128_19_38 (int q
,
3246 UINT128
* ptr_Cstar
,
3248 int *ptr_is_midpoint_lt_even
,
3249 int *ptr_is_midpoint_gt_even
,
3250 int *ptr_is_inexact_lt_midpoint
,
3251 int *ptr_is_inexact_gt_midpoint
);
3254 round192_39_57 (int q
,
3257 UINT192
* ptr_Cstar
,
3259 int *ptr_is_midpoint_lt_even
,
3260 int *ptr_is_midpoint_gt_even
,
3261 int *ptr_is_inexact_lt_midpoint
,
3262 int *ptr_is_inexact_gt_midpoint
);
3265 round256_58_76 (int q
,
3268 UINT256
* ptr_Cstar
,
3270 int *ptr_is_midpoint_lt_even
,
3271 int *ptr_is_midpoint_gt_even
,
3272 int *ptr_is_inexact_lt_midpoint
,
3273 int *ptr_is_inexact_gt_midpoint
);
3277 // Prototypes for Internal Functions
3279 extern UINT32
bid_to_bid32 (UINT32
);
3280 extern UINT64
bid_to_bid64 (UINT64
);
3281 extern UINT128
bid_to_bid128 (UINT128
);
3282 extern UINT32
bid32_canonize (UINT32
);
3283 extern UINT64
bid64_canonize (UINT64
);
3284 extern UINT128
bid128_canonize (UINT128
);