Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

sun-lamp CVS commits



jtc
Fri May 12 00:57:41 EDT 1995
Update of /a/cvsroot/src/lib/libm/src
In directory pain.lcs.mit.edu:/b/tmp/cvs-serv2733

Modified Files:
        e_acos.c e_acosf.c e_acosh.c e_acoshf.c e_asin.c e_asinf.c 
        e_hypot.c e_hypotf.c e_pow.c e_powf.c s_asinh.c s_asinhf.c 
Log Message:
Changed core routines to call __ieee754_sqrt() instead of sqrt().  I
reported this enhancement to fdlibm-comments, and got the following
reply:

Date: Thu, 11 May 1995 14:35:25 -0700
From: Kwok.Ng%Eng.Sun.COM@localhost (KC Ng)
To: fdlibm-comments%sunpro.Eng.Sun.COM@localhost, jtc%cygnus.com@localhost
Subject: Re: fdlibm 5.2: why do core functions use sqrt?

> I noticed that core (e_*.c) fdlibm functions like __ieee754_acos()
> ensure that they call sqrt() with arguments in range (x > 0), when
> they could call __ieee754_sqrt() directly.
> 
> Since sqrt() does a lot more work (verifies x is in range, etc.) is
> there any reason for this?  I'd think that calling __iee754_sqrt()
> would be more appropriate.  ....

You are right. __ieee754_sqrt should be in use with e_*.c.





Home | Main Index | Thread Index | Old Index