Home | History | Annotate | Download | only in math
      1 /*
      2  * pow.S
      3  *
      4  * double pow(double base, double exponent)
      5  */
      6 
      7 	.text
      8 	.globl	pow
      9 	.type	pow,@function
     10 pow:
     11 	fldl	12(%esp)
     12 	fldl	4(%esp)
     13 	fyl2x
     14 	fld	%st(0)
     15 	frndint
     16 	fsubr	%st,%st(1)
     17 	fxch	%st(1)
     18 	f2xm1
     19 	fld1
     20 	faddp	%st,%st(1)
     21 	fscale
     22 	fstp	%st(1)
     23 	ret
     24 
     25 	.size	pow,.-pow
     26