C language hacking

Doug Gwyn <gwyn> gwyn at brl-tgr.ARPA
Wed Nov 21 03:32:07 AEST 1984


> > 	"It would also be nice if sin( x ) and cos( x ) could be
> > 	computed simultaneously with reduced cost.  ...
> 
> It's easy.  Buggering the compiler to do it solves *one* case fast, at the
> expense of still having garbage code.

Sorry, John, but you missed the point of my inquiry.  I was not
suggesting that the compiler should have anything to do with this.
I want a speedy algorithm that computes both functions simultaneously.
The majority of the time spent is NOT in the function linkage but
rather in the guts of the computation (which is usually range
reduction followed by a rational approximation).

The reason why this matters should be pretty obvious to anyone who
does graphics programming for a living.



More information about the Comp.lang.c mailing list