Testing math library (libm) for new processor?

Henry Spencer henry at utzoo.uucp
Fri Jun 30 01:53:25 AEST 1989


In article <2035 at dataio.Data-IO.COM> bright at dataio.Data-IO.COM (Walter Bright) writes:
><I am writing a math library (equivalent to libm.a on most UNiX systems) for
><a new processor.  (Functions like sin, cos, log, etc.) ...
>
>The best one is:
>	"Software Manual For The Elementary Functions"

Note, however, that Cody&Waite is old.  If your machine uses IEEE floating
point (fairly likely these days), you should not be writing your own math
library -- you should be picking up the freely-redistributable 4.3BSD math
library, which had input from people like Kahan and is almost certainly
better than anything you can do yourself in any reasonable length of time.
Kahan commented, as I recall, that there is nothing wrong with Cody&Waite,
but their stuff is aimed at old, ill-behaved floating-point hardware, and
on IEEE hardware you can do better.

The 4.3 math library appeared in comp.sources.unix late last year.
-- 
NASA is to spaceflight as the  |     Henry Spencer at U of Toronto Zoology
US government is to freedom.   | uunet!attcan!utzoo!henry henry at zoo.toronto.edu



More information about the Comp.lang.c mailing list