summaryrefslogtreecommitdiffstats
path: root/lib/msun
diff options
context:
space:
mode:
authordas <das@FreeBSD.org>2008-03-02 01:48:17 +0000
committerdas <das@FreeBSD.org>2008-03-02 01:48:17 +0000
commit635be493045e4d2da841ce8f5762e525fbd6807b (patch)
treed6912bdb1f86e4d1cc3488f71c6d19e78c4cd913 /lib/msun
parent09521f824a63fb4b052b6051255d1733d714428a (diff)
downloadFreeBSD-src-635be493045e4d2da841ce8f5762e525fbd6807b.zip
FreeBSD-src-635be493045e4d2da841ce8f5762e525fbd6807b.tar.gz
Hook up sqrtl() to the build.
Diffstat (limited to 'lib/msun')
-rw-r--r--lib/msun/Makefile4
-rw-r--r--lib/msun/Symbol.map1
-rw-r--r--lib/msun/amd64/Makefile.inc2
-rw-r--r--lib/msun/i387/Makefile.inc2
-rw-r--r--lib/msun/man/sqrt.328
5 files changed, 24 insertions, 13 deletions
diff --git a/lib/msun/Makefile b/lib/msun/Makefile
index c870352..2f86fb3 100644
--- a/lib/msun/Makefile
+++ b/lib/msun/Makefile
@@ -79,7 +79,7 @@ SYMBOL_MAPS= ${SYM_MAPS}
COMMON_SRCS+= s_copysignl.c s_fabsl.c s_llrintl.c s_lrintl.c s_modfl.c
.if ${LDBL_PREC} != 53
# If long double != double use these; otherwise, we alias the double versions.
-COMMON_SRCS+= k_cosl.c k_sinl.c k_tanl.c s_ceill.c s_cosl.c \
+COMMON_SRCS+= e_sqrtl.c k_cosl.c k_sinl.c k_tanl.c s_ceill.c s_cosl.c \
s_exp2l.c s_floorl.c s_fmal.c \
s_frexpl.c s_logbl.c s_nanl.c s_nextafterl.c s_nexttoward.c \
s_rintl.c s_scalbnl.c s_sinl.c s_tanl.c s_truncl.c
@@ -171,7 +171,7 @@ MLINKS+=scalbn.3 scalbln.3 scalbn.3 scalblnf.3 scalbn.3 scalblnl.3
MLINKS+=scalbn.3 scalbnf.3 scalbn.3 scalbnl.3
MLINKS+=sin.3 sinf.3 sin.3 sinl.3
MLINKS+=sinh.3 sinhf.3
-MLINKS+=sqrt.3 cbrt.3 sqrt.3 cbrtf.3 sqrt.3 sqrtf.3
+MLINKS+=sqrt.3 cbrt.3 sqrt.3 cbrtf.3 sqrt.3 sqrtf.3 sqrt.3 sqrtl.3
MLINKS+=tan.3 tanf.3 tan.3 tanl.3
MLINKS+=tanh.3 tanhf.3
MLINKS+=trunc.3 truncf.3 trunc.3 truncl.3
diff --git a/lib/msun/Symbol.map b/lib/msun/Symbol.map
index 1c47130..309b45a 100644
--- a/lib/msun/Symbol.map
+++ b/lib/msun/Symbol.map
@@ -202,4 +202,5 @@ FBSD_1.1 {
cosl;
tanl;
tgammaf;
+ sqrtl;
};
diff --git a/lib/msun/amd64/Makefile.inc b/lib/msun/amd64/Makefile.inc
index b450112..f9570c2 100644
--- a/lib/msun/amd64/Makefile.inc
+++ b/lib/msun/amd64/Makefile.inc
@@ -1,6 +1,6 @@
# $FreeBSD$
-ARCH_SRCS = e_sqrt.S e_sqrtf.S s_llrint.S s_llrintf.S s_llrintl.S \
+ARCH_SRCS = e_sqrt.S e_sqrtf.S e_sqrtl.S s_llrint.S s_llrintf.S s_llrintl.S \
s_logbl.S s_lrint.S s_lrintf.S s_lrintl.S \
e_remainder.S e_remainderf.S s_remquo.S s_remquof.S \
s_rintl.S s_scalbn.S s_scalbnf.S s_scalbnl.S
diff --git a/lib/msun/i387/Makefile.inc b/lib/msun/i387/Makefile.inc
index 2fe0bcf..934889c 100644
--- a/lib/msun/i387/Makefile.inc
+++ b/lib/msun/i387/Makefile.inc
@@ -13,7 +13,7 @@ ARCH_SRCS+= e_log10f.S e_logf.S e_remainderf.S \
s_remquof.S s_rintf.S s_scalbnf.S s_significandf.S s_truncf.S
# long double counterparts
-ARCH_SRCS+= s_ceill.S s_copysignl.S s_floorl.S s_llrintl.S \
+ARCH_SRCS+= e_sqrtl.S s_ceill.S s_copysignl.S s_floorl.S s_llrintl.S \
s_logbl.S s_lrintl.S s_rintl.S s_scalbnl.S s_truncl.S
LDBL_PREC = 64 # XXX 64-bit format, but truncated to 53 bits
diff --git a/lib/msun/man/sqrt.3 b/lib/msun/man/sqrt.3
index 6d003a8..71460fa 100644
--- a/lib/msun/man/sqrt.3
+++ b/lib/msun/man/sqrt.3
@@ -28,14 +28,15 @@
.\" from: @(#)sqrt.3 6.4 (Berkeley) 5/6/91
.\" $FreeBSD$
.\"
-.Dd December 14, 2007
+.Dd March 1, 2008
.Dt SQRT 3
.Os
.Sh NAME
.Nm cbrt ,
.Nm cbrtf ,
.Nm sqrt ,
-.Nm sqrtf
+.Nm sqrtf ,
+.Nm sqrtl
.Nd cube root and square root functions
.Sh LIBRARY
.Lb libm
@@ -49,6 +50,8 @@
.Fn sqrt "double x"
.Ft float
.Fn sqrtf "float x"
+.Ft long double
+.Fn sqrtl "long double x"
.Sh DESCRIPTION
The
.Fn cbrt
@@ -59,9 +62,10 @@ the cube root of
.Ar x .
.Pp
The
-.Fn sqrt
-and the
-.Fn sqrtf
+.Fn sqrt ,
+.Fn sqrtf ,
+and
+.Fn sqrtl
functions compute the
non-negative square root of x.
.Sh RETURN VALUES
@@ -71,9 +75,10 @@ and the
.Fn cbrtf
functions return the requested cube root.
The
-.Fn sqrt
-and the
-.Fn sqrtf
+.Fn sqrt ,
+.Fn sqrtf ,
+and
+.Fn sqrtl
functions return the requested square root
unless an error occurs.
An attempt to take the
@@ -90,8 +95,9 @@ The
.Fn cbrt ,
.Fn cbrtf ,
.Fn sqrt ,
+.Fn sqrtf ,
and
-.Fn sqrtf
+.Fn sqrtl
functions conform to
.St -isoC-99 .
.Sh HISTORY
@@ -99,3 +105,7 @@ The
.Fn cbrt
function appeared in
.Bx 4.3 .
+The
+.Fn sqrtl
+function appeared in
+.Fx 8.0 .
OpenPOWER on IntegriCloud