Accelerating sine and cosine evaluation with compiler assistance

Some software libraries add special entry points to enable both the sine and cosine to be evaluated with one call for performance purposes. We propose another method which does not involve new function names. By having the compiler front end recognize trigonometric function invocations, and replace them with a call to a common function which executes the code common to all the functions, followed by a short routine to produce the desired computation, it is possible to compute both the sine and cosine, when needed in about the same time as to compute only one of them.