mirror of
https://github.com/fluencelabs/musl
synced 2025-06-12 14:31:37 +00:00
Merge remote-tracking branch 'nsz/master'
This commit is contained in:
@ -1,3 +1,5 @@
|
|||||||
|
# use acos(x) = atan2(fabs(sqrt((1-x)*(1+x))), x)
|
||||||
|
|
||||||
.global acosf
|
.global acosf
|
||||||
.type acosf,@function
|
.type acosf,@function
|
||||||
acosf:
|
acosf:
|
||||||
@ -14,17 +16,13 @@ acosl:
|
|||||||
.type acos,@function
|
.type acos,@function
|
||||||
acos:
|
acos:
|
||||||
fldl 4(%esp)
|
fldl 4(%esp)
|
||||||
1: fld1
|
1: fld %st(0)
|
||||||
fld %st(1)
|
|
||||||
fld1
|
fld1
|
||||||
fsubp
|
fsub %st(0),%st(1)
|
||||||
fsqrt
|
fadd %st(2)
|
||||||
fxch %st(2)
|
|
||||||
faddp
|
|
||||||
fsqrt
|
|
||||||
fpatan
|
|
||||||
fld1
|
|
||||||
fld1
|
|
||||||
faddp
|
|
||||||
fmulp
|
fmulp
|
||||||
|
fsqrt
|
||||||
|
fabs # fix sign of zero (matters in downward rounding mode)
|
||||||
|
fxch %st(1)
|
||||||
|
fpatan
|
||||||
ret
|
ret
|
||||||
|
@ -1,18 +1,16 @@
|
|||||||
|
# see ../i386/acos.s
|
||||||
|
|
||||||
.global acosl
|
.global acosl
|
||||||
.type acosl,@function
|
.type acosl,@function
|
||||||
acosl:
|
acosl:
|
||||||
fldt 8(%rsp)
|
fldt 8(%rsp)
|
||||||
|
1: fld %st(0)
|
||||||
fld1
|
fld1
|
||||||
fld %st(1)
|
fsub %st(0),%st(1)
|
||||||
fld1
|
fadd %st(2)
|
||||||
fsubp
|
|
||||||
fsqrt
|
|
||||||
fxch %st(2)
|
|
||||||
faddp
|
|
||||||
fsqrt
|
|
||||||
fpatan
|
|
||||||
fld1
|
|
||||||
fld1
|
|
||||||
faddp
|
|
||||||
fmulp
|
fmulp
|
||||||
|
fsqrt
|
||||||
|
fabs
|
||||||
|
fxch %st(1)
|
||||||
|
fpatan
|
||||||
ret
|
ret
|
||||||
|
Reference in New Issue
Block a user