Sender: rich AT phekda DOT freeserve DOT co DOT uk Message-ID: <3EFEF32B.D01A3C0E@phekda.freeserve.co.uk> Date: Sun, 29 Jun 2003 15:09:47 +0100 From: Richard Dawe X-Mailer: Mozilla 4.77 [en] (X11; U; Linux 2.2.23 i586) X-Accept-Language: de,fr MIME-Version: 1.0 To: DJGPP workers Subject: strtod test takes a long time Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Reply-To: djgpp-workers AT delorie DOT com Hello. The strtod test (tests/libc/ansi/stdlib/strtod.c) seems to take a long time. DJGPP CVS built with gcc 3.2.2, binutils 2.13 on an Athlon 850MHz: bash-2.04$ time ./strtod.exe 0e20 -> 0 1e200 -> 1e+200 0e2000000000 -> 0 1e6000000000 -> inf strtod: Output of function out of range (ERANGE) 1e400 -> inf strtod: Output of function out of range (ERANGE) 1e-400 -> 0 strtod: Output of function out of range (ERANGE) InF -> inf -inf -> -inf infinity -> inf -inFinitY -> -inf nAn -> nan(0xfffffe0000000) -nan -> -nan Nan() -> nan nan(0) -> nan Nan(1) -> nan(0x8000000000001) -NaN(0xfffff) -> -nan(0x80000000fffff) real 0m16.100s user 0m32.198s sys 0m0.000s FWIW it takes about the same amount of time when compiled with gcc 3.3. Is this expected? I'm wondering if we could exit strto* faster, when the exponent is larger than one we support (*_MAX_EXP from . Bye, Rich =] -- Richard Dawe [ http://www.phekda.freeserve.co.uk/richdawe/ ]