qemu/fpu/softfloat-specialize.h
/*----------------------------------------------------------------------------
| The pattern for a default generated deconstructed floating-point NaN.
*----------------------------------------------------------------------------*/
| The pattern for a default generated deconstructed floating-point NaN.
| The pattern for a default generated deconstructed floating - point NaN .
static FloatParts parts_default_nan(float_status *status)
{
    bool sign = 0;
    uint64_t frac;
#if defined(TARGET_SPARC) || defined(TARGET_M68K)
    frac = (1ULL << DECOMPOSED_BINARY_POINT) - 1;
#elif defined(TARGET_I386) || defined(TARGET_X86_64) \
    || defined(TARGET_MICROBLAZE)
    frac = 1ULL << (DECOMPOSED_BINARY_POINT - 1);
    sign = 1;
#elif defined(TARGET_HPPA)
    frac = 1ULL << (DECOMPOSED_BINARY_POINT - 2);
#else
    if (snan_bit_is_one(status)) {
        frac = (1ULL << (DECOMPOSED_BINARY_POINT - 1)) - 1;
    } else {
        frac = 1ULL << (DECOMPOSED_BINARY_POINT - 1);
    }
#endif
    return (FloatParts) {
        .cls = float_class_qnan,
        .sign = sign,
        .exp = INT_MAX,
        .frac = frac
    };
}
static FloatParts parts_default_nan ( float_status * status ) { bool sign = 0 ; uint64_t frac ; #if defined ( TARGET_SPARC ) || defined ( TARGET_M68K ) frac = ( 1ULL << DECOMPOSED_BINARY_POINT ) - 1 ; #elif defined ( TARGET_I386 ) || defined ( TARGET_X86_64 ) || defined ( TARGET_MICROBLAZE ) frac = 1ULL << ( DECOMPOSED_BINARY_POINT - 1 ) ; sign = 1 ; #elif defined ( TARGET_HPPA ) frac = 1ULL << ( DECOMPOSED_BINARY_POINT - 2 ) ; #else if ( snan_bit_is_one ( status ) ) { frac = ( 1ULL << ( DECOMPOSED_BINARY_POINT - 1 ) ) - 1 ; } else { frac = 1ULL << ( DECOMPOSED_BINARY_POINT - 1 ) ; } #endif return ( FloatParts ) { . cls = float_class_qnan , . sign = sign , . exp = INT_MAX , . frac = frac } ; }
| The pattern for a default generated deconstructed floating-point NaN.
| The pattern for a default generated deconstructed floating - point NaN .
/* !snan_bit_is_one, set all bits */ /* !snan_bit_is_one, set sign and msb */ /* snan_bit_is_one, set msb-1.  */ /* This case is true for Alpha, ARM, MIPS, OpenRISC, PPC, RISC-V,
     * S390, SH4, TriCore, and Xtensa.  I cannot find documentation
     * for Unicore32; the choice from the original commit is unchanged.
     * Our other supported targets, CRIS, LM32, Moxie, Nios2, and Tile,
     * do not have floating-point.
     */ /* set all bits other than msb */ /* set msb */