Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 14 Jul 1999 01:06:37 +0900
From:      Hidetoshi Shimokawa <simokawa@sat.t.u-tokyo.ac.jp>
To:        m.seaman@inpharmatica.co.uk
Cc:        FreeBSD-gnats-submit@FreeBSD.ORG, freebsd-alpha@freebsd.org
Subject:   Re: alpha/12623: strtod(3) FPE on alphaev56
Message-ID:  <14219.25613.478914.44162J@ett.sat.t.u-tokyo.ac.jp>
In-Reply-To: In your message of "Tue, 13 Jul 1999 12:27:40 %2B0100 (BST)" <199907131127.MAA09770@b0.farm.inpharmatica.co.uk>
References:  <199907131127.MAA09770@b0.farm.inpharmatica.co.uk>

next in thread | previous in thread | raw e-mail | index | archive | help
At Tue, 13 Jul 1999 12:27:40 +0100 (BST),
m.seaman@inpharmatica.co.uk wrote:
> >Description:
> 
> Attempting to convert the string "2.49521e-297" into a double
> precision value via strtod(3) results in a floating point exception on
> the alphaev56 CPU.  The problem doesn't occur on i586.

/usr/src/lib/libc/stdlib/strtod.c seems broken on alpha in three ways.

1) IEEE_8087 should be defined instead of IEEE_MC68k.

2) It assumes long is 32bit, but long is 64bit on alpha.
	s/unsigned long/u_int32_t/, s/long/int32_t/.

3) It generates denormal numbers which can not be treaded by the hardware
   on alpha. It should be compiled with the option
   `-mtrap-precision=i -mfp-trap-mode=su' to enable software completion.

-- 
/\ Hidetoshi Shimokawa
\/  simokawa@sat.t.u-tokyo.ac.jp
PGP public key: finger -l simokawa@sat.t.u-tokyo.ac.jp


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-alpha" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?14219.25613.478914.44162J>