i386: ulp update for SSE2 --disable-multi-arch configurations
[glibc.git] / sysdeps / i386 / fpu / e_asin.S
blob3be8fc5316c487fde79641098b75038e6f9b91cf
1 /*
2  * Public domain.
3  */
5 #include <machine/asm.h>
6 #include <i386-math-asm.h>
7 #include <libm-alias-finite.h>
9 RCSID("$NetBSD: e_asin.S,v 1.4 1995/05/08 23:45:40 jtc Exp $")
11 DEFINE_DBL_MIN
13 #ifdef PIC
14 # define MO(op) op##@GOTOFF(%ecx)
15 #else
16 # define MO(op) op
17 #endif
19         .text
21 /* asin = atan (x / sqrt((1-x) (1+x))) */
22 ENTRY(__ieee754_asin)
23 #ifdef  PIC
24         LOAD_PIC_REG (cx)
25 #endif
26         fldl    4(%esp)                 /* x */
27         fld     %st
28         fld1                            /* 1 : x : x */
29         fsubp                           /* 1 - x : x */
30         fld1                            /* 1 : 1 - x : x */
31         fadd    %st(2)                  /* 1 + x : 1 - x : x */
32         fmulp                           /* 1 - x^2 */
33         fsqrt                           /* sqrt (1 - x^2) */
34         fpatan
35         DBL_CHECK_FORCE_UFLOW
36         ret
37 END (__ieee754_asin)
38 libm_alias_finite (__ieee754_asin, __asin)