Subject: lib/75: libm/common_source/pow.c doesn't compile under -O2
To: None <gnats-admin>
From: None <thomas@mathematik.uni-Bremen.de>
List: netbsd-bugs
Date: 01/13/1994 13:05:11
>Number: 75
>Category: lib
>Synopsis: libm/common_source/pow.c doesn't compile under -O2
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: gnats-admin (Library Bug People)
>State: open
>Class: change-request
>Submitter-Id: net
>Arrival-Date: Thu Jan 13 13:05:08 1994
>Originator: Thomas Eberhardt
>Organization:
CeVis, University of Bremen, Germany
>Release:
>Environment:
System: NetBSD ed209 0.9a ED209#0 i386
Machine: i386
>Description:
libm/common_source/pow.c doesn't compile under -O2 since the
compiler tries to evaluate the huge*huge expression and
aborts with an floating point error message.
>How-To-Repeat:
>Fix:
*** pow.c- Fri Dec 17 07:30:57 1993
--- pow.c Thu Jan 6 12:24:03 1994
***************
*** 121,126 ****
--- 121,127 ----
#endif /* vax or tahoe */
const static double zero=0.0, one=1.0, two=2.0, negone= -1.0;
+ const static double huge=1e300, tiny=1e-300;
static double pow_P __P((double, double));
***************
*** 175,181 ****
#endif
{
struct Double s, t, log__D();
! double exp__D(), huge = 1e300, tiny = 1e-300;
if (x == zero)
if (y > zero)
--- 176,182 ----
#endif
{
struct Double s, t, log__D();
! double exp__D();
if (x == zero)
if (y > zero)
>Audit-Trail:
>Unformatted:
------------------------------------------------------------------------------