Re: [AD] get_clip()

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


Eric Botcazou wrote:
Post it to the list.

OK, here is a gcc/i386 version, the only one I can find.

Sven
/* al_sincos:
 *  Simultaneously calculates sin and cos of x.
 */
AL_INLINE(void, al_sincos, (double x, double *s, double *c))
{
   asm (
	"  fldl %0 ; "              /* load x to fp stack */
	"  fsincos ; "
	"  fstpl (%1) ; "           /* pop cos value off stack */
	"  fstpl (%2) ; "           /* pop sin value off stack */
       :
       : "m" (x),                    /* x in memory */
	"r" (c),                    /* results in registers */
	"r" (s)                     /* results in registers */
       : "%cc"                       /* clobbers what? */
	);
}


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/