Implementation of expl()
das at FreeBSD.ORG
Sun Dec 9 14:39:46 PST 2007
On Sun, Dec 09, 2007, Steve Kargl wrote:
> On Sun, Dec 09, 2007 at 04:25:05PM -0500, David Schultz wrote:
> > On Fri, Nov 02, 2007, Steve Kargl wrote:
> > > With all the success of developing several other missing
> > > C99 math routines, I decided to tackle expl() (which I
> > > need to tackle tanhl()).
> > Hmm, great, but where's the patch? :) Maybe the mailing list
> > software ate it.
> This is the current version. I need to revise how I computed
> the ploynomial coefficient. In short, I mapped r in
> [-ln(2)/2:ln(2)/2] into the range x in [-1,1] for the Chebyshev
> interpolation, but I never scaled x back into r. This is the
> reason why the lines "r = r * TOLN2;" exists.
Some minor fixes (mostly whitespace) are below.
Also, don't you lose precision when you do stuff like this?
z.e = 1 / z.e;
In any case, if you can get me the appropriate constants for the
128-bit format, I'll clean everything up and check it in, which
will make a lot of ports maintainers happy. That will pave the way
to other stuff (e.g., MD versions of this) as well. We can worry
about subnormals later.
More information about the freebsd-standards