[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: gawk 3.1.5h test results on interix
From: |
Aharon Robbins |
Subject: |
Re: gawk 3.1.5h test results on interix |
Date: |
Fri, 19 Oct 2007 03:37:09 +0200 |
In article <address@hidden> you write:
>> It would appear that your library doesn't distinguish negative and
>> positive NAN values.
>> Is that true?
>
>Yes, I verified that now. Interix libc printf doesn't distinguish
>between NaN and -NaN, it always prints "NaN".
OK, good to know I wasn't far off.
>> Andy:
>> This seems rather bewildering to me (that 'sprintf("%f",-nan)'
>> returned '-NaN' in the first instance inside BEGIN, but then behaved
>> differently inside the display function). I hope that I'm reading
>> the code improperly. Does anybody else understand what's going on
>> here?
>
>But Andy is also right. NaN or -NaN isn't the problem, the test
>compensates for it. The real problem is that log(0) isn't -Inf but NaN
>for me. The reason is, however, the libm I'm using. If I use the
>system libm, everything is fine, also the tweakfld test. The system
>libm has other problems with single precision floats, that's why I'm
>now using libm from newlib.
>
>Unfortunaly, newlib's libm has a bug which I just found now. For
>log(0) the docs says it returns -Inf, but the source says it returns
>NaN.
>
>Thank you both.
>
>On Interix there is a problem with "long double", for details see:
>http://www.debian-interix.net/techdocs/#ldbl
>
>Apparently, this is not the case here, but just to verify: Does gawk
>make use of "long double" anywhere, besides in the configure script?
>
>Martin
Gawk uses plain double. It doesn't use float or long double, so it sounds
like you're safe using the system libm.
Thanks!
Arnold
--
Aharon (Arnold) Robbins arnold AT skeeve DOT com
P.O. Box 354 Home Phone: +972 8 979-0381 Fax: +1 206 202 4333
Nof Ayalon Cell Phone: +972 50 729-7545
D.N. Shimshon 99785 ISRAEL