38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync/*************************************************************************
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * $Id: trionan.c 2219 2003-10-15 08:18:00Z veillard $
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Copyright (C) 2001 Bjorn Reese <breese@users.sourceforge.net>
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Permission to use, copy, modify, and distribute this software for any
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * purpose with or without fee is hereby granted, provided that the above
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * copyright notice and this permission notice appear in all copies.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE AUTHORS AND
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * CONTRIBUTORS ACCEPT NO RESPONSIBILITY IN ANY CONCEIVABLE MANNER.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync ************************************************************************
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Functions to handle special quantities in floating-point numbers
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * (that is, NaNs and infinity). They provide the capability to detect
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * and fabricate special quantities.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Although written to be as portable as possible, it can never be
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * guaranteed to work on all platforms, as not all hardware supports
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * special quantities.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * The approach used here (approximately) is to:
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * 1. Use C99 functionality when available.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * 2. Use IEEE 754 bit-patterns if possible.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * 3. Use platform-specific techniques.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync ************************************************************************/
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * o Put all the magic into trio_fpclassify_and_signbit(), and use this from
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * trio_isnan() etc.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync/*************************************************************************
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Include files
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync/** @addtogroup SpecialQuantities
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync/*************************************************************************
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Definitions
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * We must enable IEEE floating-point on Alpha
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync# error "Must be compiled with option /IEEE_MODE=UNDERFLOW_TO_ZERO/FLOAT=IEEE"
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync# if !defined(_CFE)
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync# elif defined(TRIO_COMPILER_GCC) && (defined(__osf__) || defined(__linux__))
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync#endif /* __alpha && ! _IEEE_FP */
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * In ANSI/IEEE 754-1985 64-bits double format numbers have the
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * following properties (amoungst others)
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * o FLT_RADIX == 2: binary encoding
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * o DBL_MAX_EXP == 1024: 11 bits exponent, where one bit is used
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * to indicate special numbers (e.g. NaN and Infinity), so the
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * maximum exponent is 10 bits wide (2^10 == 1024).
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * o DBL_MANT_DIG == 53: The mantissa is 52 bits wide, but because
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * numbers are normalized the initial binary 1 is represented
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * implicitly (the so-called "hidden bit"), which leaves us with
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * the ability to represent 53 bits wide mantissa.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync#if (FLT_RADIX == 2) && (DBL_MAX_EXP == 1024) && (DBL_MANT_DIG == 53)
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync/*************************************************************************
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Constants
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsyncstatic TRIO_CONST char rcsid[] = "@(#)$Id: trionan.c 2219 2003-10-15 08:18:00Z veillard $";
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Endian-agnostic indexing macro.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * The value of internalEndianMagic, when converted into a 64-bit
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * integer, becomes 0x0706050403020100 (we could have used a 64-bit
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * integer value instead of a double, but not all platforms supports
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * that type). The value is automatically encoded with the correct
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * endianess by the compiler, which means that we can support any
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * kind of endianess. The individual bytes are then used as an index
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * for the IEEE 754 bit-patterns and masks.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync#define TRIO_DOUBLE_INDEX(x) (((unsigned char *)&internalEndianMagic)[7-(x)])
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsyncstatic TRIO_CONST double internalEndianMagic = 7.949928895127363e-275;
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync/* Mask for the exponent */
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsyncstatic TRIO_CONST unsigned char ieee_754_exponent_mask[] = {
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync/* Mask for the mantissa */
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsyncstatic TRIO_CONST unsigned char ieee_754_mantissa_mask[] = {
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync/* Mask for the sign bit */
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsyncstatic TRIO_CONST unsigned char ieee_754_sign_mask[] = {
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync/* Bit-pattern for negative zero */
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsyncstatic TRIO_CONST unsigned char ieee_754_negzero_array[] = {
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync/* Bit-pattern for infinity */
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsyncstatic TRIO_CONST unsigned char ieee_754_infinity_array[] = {
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync/* Bit-pattern for quiet NaN */
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsyncstatic TRIO_CONST unsigned char ieee_754_qnan_array[] = {
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync/*************************************************************************
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Functions
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * trio_make_double
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync for (i = 0; i < (int)sizeof(double); i++) {
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync ((TRIO_VOLATILE unsigned char *)&result)[TRIO_DOUBLE_INDEX(i)] = values[i];
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * trio_is_special_quantity
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync unsigned int i;
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync for (i = 0; i < (unsigned int)sizeof(double); i++) {
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync current = ((unsigned char *)&number)[TRIO_DOUBLE_INDEX(i)];
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync &= ((current & ieee_754_exponent_mask[i]) == ieee_754_exponent_mask[i]);
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync *has_mantissa |= (current & ieee_754_mantissa_mask[i]);
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * trio_is_negative
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync unsigned int i;
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync for (i = 0; i < (unsigned int)sizeof(double); i++) {
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync is_negative |= (((unsigned char *)&number)[TRIO_DOUBLE_INDEX(i)]
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync#endif /* USE_IEEE_754 */
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync Generate negative zero.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync @return Floating-point representation of negative zero.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync Generate positive infinity.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync @return Floating-point representation of positive infinity.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync /* Cache the result */
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync result = trio_make_double(ieee_754_infinity_array);
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * If HUGE_VAL is different from DBL_MAX, then HUGE_VAL is used
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * as infinity. Otherwise we have to resort to an overflow
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * operation to generate infinity.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync void (*signal_handler)(int) = signal(SIGFPE, SIG_IGN);
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync /* Force overflow */
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync Generate negative infinity.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync @return Floating-point value of negative infinity.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Negative infinity is calculated by negating positive infinity,
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * which can be done because it is legal to do calculations on
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * infinity (for example, 1 / infinity == 0).
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync Generate NaN.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync @return Floating-point representation of NaN.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync /* Cache the result */
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * There are several ways to generate NaN. The one used here is
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * to divide infinity by infinity. I would have preferred to add
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * negative infinity to positive infinity, but that yields wrong
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * result (infinity) on FreeBSD.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * This may fail if the hardware does not support NaN, or if
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * the Invalid Operation floating-point exception is unmasked.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync void (*signal_handler)(int) = signal(SIGFPE, SIG_IGN);
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync Check for NaN.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync @param number An arbitrary floating-point number.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync @return Boolean value indicating whether or not the number is a NaN.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync#if (defined(TRIO_COMPILER_SUPPORTS_C99) && defined(isnan)) \
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * C99 defines isnan() as a macro. UNIX95 defines isnan() as a
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * function. This function was already present in XPG4, but this
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * is a bit tricky to detect with compiler defines, so we choose
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * the conservative approach and only use it for UNIX95.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync#elif defined(TRIO_COMPILER_MSVC) || defined(TRIO_COMPILER_BCB)
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Microsoft Visual C++ and Borland C++ Builder have an _isnan()
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * function.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Examine IEEE 754 bit-pattern. A NaN must have a special exponent
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * pattern, and a non-empty mantissa.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync is_special_quantity = trio_is_special_quantity(number, &has_mantissa);
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Fallback solution
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync void (*signal_handler)(int) = signal(SIGFPE, SIG_IGN);
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * NaN is the only number which does not compare to itself
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync ((TRIO_VOLATILE double)number != (TRIO_VOLATILE double)number) ||
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Fallback solution if NaN compares to NaN
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync Check for infinity.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync @param number An arbitrary floating-point number.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync @return 1 if positive infinity, -1 if negative infinity, 0 otherwise.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync#if defined(TRIO_COMPILER_DECC) && !defined(__linux__)
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * DECC has an isinf() macro, but it works differently than that
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * of C99, so we use the fp_class() function instead.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * C99 defines isinf() as a macro.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync#elif defined(TRIO_COMPILER_MSVC) || defined(TRIO_COMPILER_BCB)
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Microsoft Visual C++ and Borland C++ Builder have an _fpclass()
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * function that can be used to detect infinity.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Examine IEEE 754 bit-pattern. Infinity must have a special exponent
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * pattern, and an empty mantissa.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync is_special_quantity = trio_is_special_quantity(number, &has_mantissa);
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Fallback solution.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync void (*signal_handler)(int) = signal(SIGFPE, SIG_IGN);
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync /* Temporary fix - this routine is not used anywhere */
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync Check for finity.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync @param number An arbitrary floating-point number.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync @return Boolean value indicating whether or not the number is a finite.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync#if defined(TRIO_COMPILER_SUPPORTS_C99) && defined(isfinite)
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * C99 defines isfinite() as a macro.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync#elif defined(TRIO_COMPILER_MSVC) || defined(TRIO_COMPILER_BCB)
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Microsoft Visual C++ and Borland C++ Builder use _finite().
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Examine IEEE 754 bit-pattern. For finity we do not care about the
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * mantissa.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync return (! trio_is_special_quantity(number, &dummy));
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Fallback solution.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync return ((trio_isinf(number) == 0) && (trio_isnan(number) == 0));
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * The sign of NaN is always false
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * C99 defines fpclassify() and signbit() as a macros
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * DECC has an fp_class() function.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync# elif defined(TRIO_COMPILER_MSVC) || defined(TRIO_COMPILER_BCB)
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Microsoft Visual C++ and Borland C++ Builder have an _fpclass()
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * function.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * HP-UX 9.x and 10.x have an fpclassify() function, that is different
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * from the C99 fpclassify() macro supported on HP-UX 11.x.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * AIX has class() for C, and _class() for C++, which returns the
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * same values as the HP-UX fpclassify() function.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync /* Just in case... */
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Fallback solution.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * In IEEE 754 the sign of zero is ignored in comparisons, so we
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * have to handle this as a special case by examining the sign bit
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * directly.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync Examine the sign of a number.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync @param number An arbitrary floating-point number.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync @return Boolean value indicating whether or not the number has the
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync sign bit set (i.e. is negative).
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync (void)trio_fpclassify_and_signbit(number, &is_negative);
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync /* Temporary fix - this routine is not used in libxml */
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync Examine the class of a number.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync @param number An arbitrary floating-point number.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync @return Enumerable value indicating the class of @p number
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync return trio_fpclassify_and_signbit(number, &dummy);
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync/** @} SpecialQuantities */
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync/*************************************************************************
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * For test purposes.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Add the following compiler option to include this test code.
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * Unix : -DSTANDALONE
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync * VMS : /DEFINE=(STANDALONE)
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync return "FP_INFINITE";
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync return "FP_NAN";
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync return "FP_NORMAL";
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync return "FP_SUBNORMAL";
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync return "FP_ZERO";
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync return "FP_UNKNOWN";
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync printf("NaN : %4g 0x%02x%02x%02x%02x%02x%02x%02x%02x (%2d, %2d)\n",
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync ((unsigned char *)&my_nan)[0],
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync printf("PInf: %4g 0x%02x%02x%02x%02x%02x%02x%02x%02x (%2d, %2d)\n",
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync ((unsigned char *)&my_pinf)[0],
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync printf("NInf: %4g 0x%02x%02x%02x%02x%02x%02x%02x%02x (%2d, %2d)\n",
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync ((unsigned char *)&my_ninf)[0],
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync printf("NaN : %4g 0x%02x%02x%02x%02x%02x%02x%02x%02x (%2d, %2d)\n",
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync ((unsigned char *)&my_nan)[0],
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync printf("PInf: %4g 0x%02x%02x%02x%02x%02x%02x%02x%02x (%2d, %2d)\n",
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync ((unsigned char *)&my_pinf)[0],
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync printf("NInf: %4g 0x%02x%02x%02x%02x%02x%02x%02x%02x (%2d, %2d)\n",
38ae7e4efe803ea78b6499cd05a394db32623e41vboxsync ((unsigned char *)&my_ninf)[0],