Bruno Haible <[EMAIL PROTECTED]> writes:
> Andreas Schwab wrote:
>> Bruno Haible <[EMAIL PROTECTED]> writes:
>>
>> > union u { unsigned int word[4]; long double value; } x =
>> > { { 0x00000000, 0x40000001, 0x0000ffff, 0x00000000 } };
>>
>> This is not a valid number. The integer bit _must_ be 1 for a valid NaN
>> or Infinity.
>
> The Intel IA-64 documentation does not employ the term "valid". According to
> this doc [1][2], the number is a "Pseudo-NaN". So in some sense it's a
> number outside IEEE-754.
It's definitely not a valid encoding. No valid operation can ever
generate such an encoding.
> While isnanl(X) = 0 may be subject to discussion,
> finitel(X) = 1 and
> printf %g X = "-5.94866e+4931"
> are clearly inappropriate.
You are invoking undefined behaviour by useing an invalid encoding.
There is nothing that can be validly said about this invalid encoding,
so every answer is neither right nor wrong, but just undefined.
Andreas.
--
Andreas Schwab, SuSE Labs, [EMAIL PROTECTED]
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
PGP key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
_______________________________________________
Bug-m4 mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-m4