summaryrefslogtreecommitdiff
path: root/sysdeps/sparc/sparc32/fpu
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/sparc/sparc32/fpu')
-rw-r--r--sysdeps/sparc/sparc32/fpu/e_sqrtl.c2
-rw-r--r--sysdeps/sparc/sparc32/fpu/s_copysign.S9
-rw-r--r--sysdeps/sparc/sparc32/fpu/s_copysignf.S5
-rw-r--r--sysdeps/sparc/sparc32/fpu/s_fabs.S6
-rw-r--r--sysdeps/sparc/sparc32/fpu/s_fabsf.S5
-rw-r--r--sysdeps/sparc/sparc32/fpu/s_fabsl.c3
-rw-r--r--sysdeps/sparc/sparc32/fpu/s_fdim.S42
-rw-r--r--sysdeps/sparc/sparc32/fpu/s_fdimf.S35
-rw-r--r--sysdeps/sparc/sparc32/fpu/s_signbit.S4
-rw-r--r--sysdeps/sparc/sparc32/fpu/s_signbitl.S2
-rw-r--r--sysdeps/sparc/sparc32/fpu/w_sqrt.S53
-rw-r--r--sysdeps/sparc/sparc32/fpu/w_sqrtf.S51
12 files changed, 22 insertions, 195 deletions
diff --git a/sysdeps/sparc/sparc32/fpu/e_sqrtl.c b/sysdeps/sparc/sparc32/fpu/e_sqrtl.c
index b0ce44a579..181a39c1cb 100644
--- a/sysdeps/sparc/sparc32/fpu/e_sqrtl.c
+++ b/sysdeps/sparc/sparc32/fpu/e_sqrtl.c
@@ -1,5 +1,5 @@
/* Long double square root, sparc32 version.
- Copyright (C) 2016 Free Software Foundation, Inc.
+ Copyright (C) 2016-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
diff --git a/sysdeps/sparc/sparc32/fpu/s_copysign.S b/sysdeps/sparc/sparc32/fpu/s_copysign.S
index 402091483a..7743ee0c67 100644
--- a/sysdeps/sparc/sparc32/fpu/s_copysign.S
+++ b/sysdeps/sparc/sparc32/fpu/s_copysign.S
@@ -1,5 +1,5 @@
/* copysign function, sparc32 version.
- Copyright (C) 2012-2016 Free Software Foundation, Inc.
+ Copyright (C) 2012-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by David S. Miller <davem@davemloft.net>, 2012.
@@ -18,6 +18,8 @@
<http://www.gnu.org/licenses/>. */
#include <sysdep.h>
+#include <math_ldbl_opt.h>
+#include <libm-alias-double.h>
ENTRY (__copysign)
sethi %hi(0x80000000), %g1
@@ -28,4 +30,7 @@ ENTRY (__copysign)
retl
ldd [%sp + 72], %f0
END (__copysign)
-weak_alias (__copysign, copysign) \ No newline at end of file
+libm_alias_double (__copysign, copysign)
+#if LONG_DOUBLE_COMPAT (libc, GLIBC_2_0)
+compat_symbol (libc, __copysign, copysignl, GLIBC_2_0);
+#endif
diff --git a/sysdeps/sparc/sparc32/fpu/s_copysignf.S b/sysdeps/sparc/sparc32/fpu/s_copysignf.S
index d60d7c85fd..becfc92e6d 100644
--- a/sysdeps/sparc/sparc32/fpu/s_copysignf.S
+++ b/sysdeps/sparc/sparc32/fpu/s_copysignf.S
@@ -1,5 +1,5 @@
/* float copysign function, sparc32 version.
- Copyright (C) 2012-2016 Free Software Foundation, Inc.
+ Copyright (C) 2012-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by David S. Miller <davem@davemloft.net>, 2012.
@@ -18,6 +18,7 @@
<http://www.gnu.org/licenses/>. */
#include <sysdep.h>
+#include <libm-alias-float.h>
ENTRY (__copysignf)
sethi %hi(0x80000000), %g1
@@ -28,4 +29,4 @@ ENTRY (__copysignf)
retl
ld [%sp + 68], %f0
END (__copysignf)
-weak_alias (__copysignf, copysignf) \ No newline at end of file
+libm_alias_float (__copysign, copysign)
diff --git a/sysdeps/sparc/sparc32/fpu/s_fabs.S b/sysdeps/sparc/sparc32/fpu/s_fabs.S
index d4c88339c9..db639c94c2 100644
--- a/sysdeps/sparc/sparc32/fpu/s_fabs.S
+++ b/sysdeps/sparc/sparc32/fpu/s_fabs.S
@@ -1,5 +1,5 @@
/* Float absolute value, sparc32 version.
- Copyright (C) 2011-2016 Free Software Foundation, Inc.
+ Copyright (C) 2011-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -17,6 +17,8 @@
<http://www.gnu.org/licenses/>. */
#include <sysdep.h>
+#include <math_ldbl_opt.h>
+#include <libm-alias-double.h>
ENTRY (__fabs)
st %o0, [%sp+72]
@@ -25,4 +27,4 @@ ENTRY (__fabs)
retl
fabss %f0, %f0
END (__fabs)
-weak_alias (__fabs, fabs)
+libm_alias_double (__fabs, fabs)
diff --git a/sysdeps/sparc/sparc32/fpu/s_fabsf.S b/sysdeps/sparc/sparc32/fpu/s_fabsf.S
index 9a69af6751..5fcab24125 100644
--- a/sysdeps/sparc/sparc32/fpu/s_fabsf.S
+++ b/sysdeps/sparc/sparc32/fpu/s_fabsf.S
@@ -1,5 +1,5 @@
/* Float absolute value, sparc32 version.
- Copyright (C) 2006-2016 Free Software Foundation, Inc.
+ Copyright (C) 2006-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Jakub Jelinek <jakub@redhat.com>, 2006.
@@ -18,6 +18,7 @@
<http://www.gnu.org/licenses/>. */
#include <sysdep.h>
+#include <libm-alias-float.h>
ENTRY (__fabsf)
st %o0, [%sp+68]
@@ -25,4 +26,4 @@ ENTRY (__fabsf)
retl
fabss %f0, %f0
END (__fabsf)
-weak_alias (__fabsf, fabsf)
+libm_alias_float (__fabs, fabs)
diff --git a/sysdeps/sparc/sparc32/fpu/s_fabsl.c b/sysdeps/sparc/sparc32/fpu/s_fabsl.c
index 3c03b92828..411a2e1511 100644
--- a/sysdeps/sparc/sparc32/fpu/s_fabsl.c
+++ b/sysdeps/sparc/sparc32/fpu/s_fabsl.c
@@ -1,8 +1,9 @@
#include <math.h>
#include <math_ldbl_opt.h>
+#include <libm-alias-ldouble.h>
long double __fabsl (long double x)
{
return __builtin_fabsl (x);
}
-long_double_symbol (libm, __fabsl, fabsl);
+libm_alias_ldouble (__fabs, fabs)
diff --git a/sysdeps/sparc/sparc32/fpu/s_fdim.S b/sysdeps/sparc/sparc32/fpu/s_fdim.S
deleted file mode 100644
index e93970faae..0000000000
--- a/sysdeps/sparc/sparc32/fpu/s_fdim.S
+++ /dev/null
@@ -1,42 +0,0 @@
-/* Compute positive difference, sparc 32-bit.
- Copyright (C) 2013-2016 Free Software Foundation, Inc.
- This file is part of the GNU C Library.
- Contributed by David S. Miller <davem@davemloft.net>.
-
- The GNU C Library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- The GNU C Library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, see
- <http://www.gnu.org/licenses/>. */
-
-#include <sysdep.h>
-#include <math_ldbl_opt.h>
-
-ENTRY(__fdim)
- std %o0, [%sp + 72]
- std %o2, [%sp + 80]
- ldd [%sp + 72], %f0
- ldd [%sp + 80], %f2
- fcmpd %f0, %f2
- st %g0, [%sp + 72]
- fbug 1f
- st %g0, [%sp + 76]
- ldd [%sp + 72], %f0
- fnegs %f0, %f2
- fmovs %f1, %f3
-1: retl
- fsubd %f0, %f2, %f0
-END(__fdim)
-weak_alias (__fdim, fdim)
-
-#if LONG_DOUBLE_COMPAT(libm, GLIBC_2_1)
-compat_symbol (libm, __fdim, fdiml, GLIBC_2_1);
-#endif
diff --git a/sysdeps/sparc/sparc32/fpu/s_fdimf.S b/sysdeps/sparc/sparc32/fpu/s_fdimf.S
deleted file mode 100644
index c3fe8afa98..0000000000
--- a/sysdeps/sparc/sparc32/fpu/s_fdimf.S
+++ /dev/null
@@ -1,35 +0,0 @@
-/* Compute positive difference, sparc 32-bit.
- Copyright (C) 2013-2016 Free Software Foundation, Inc.
- This file is part of the GNU C Library.
- Contributed by David S. Miller <davem@davemloft.net>.
-
- The GNU C Library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- The GNU C Library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, see
- <http://www.gnu.org/licenses/>. */
-
-#include <sysdep.h>
-
-ENTRY(__fdimf)
- st %o0, [%sp + 72]
- st %o1, [%sp + 76]
- ld [%sp + 72], %f0
- ld [%sp + 76], %f1
- fcmps %f0, %f1
- fbug 1f
- st %g0, [%sp + 72]
- ld [%sp + 72], %f0
- fnegs %f0, %f1
-1: retl
- fsubs %f0, %f1, %f0
-END(__fdimf)
-weak_alias (__fdimf, fdimf)
diff --git a/sysdeps/sparc/sparc32/fpu/s_signbit.S b/sysdeps/sparc/sparc32/fpu/s_signbit.S
index c048b45556..341d668aa5 100644
--- a/sysdeps/sparc/sparc32/fpu/s_signbit.S
+++ b/sysdeps/sparc/sparc32/fpu/s_signbit.S
@@ -1,5 +1,5 @@
/* signbit(). sparc32 version.
- Copyright (C) 2012-2016 Free Software Foundation, Inc.
+ Copyright (C) 2012-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -22,11 +22,9 @@ ENTRY (__signbit)
retl
srl %o0, 31, %o0
END (__signbit)
-weak_alias (__signbit, signbit)
/* On 32-bit the double version will also always work for
single-precision since in both cases the word with the
sign bit in it is passed always in register %o0. */
strong_alias (__signbit, __signbitf)
hidden_def (__signbitf)
-weak_alias (__signbitf, signbitf)
diff --git a/sysdeps/sparc/sparc32/fpu/s_signbitl.S b/sysdeps/sparc/sparc32/fpu/s_signbitl.S
index 782b121b9d..8f0832a60e 100644
--- a/sysdeps/sparc/sparc32/fpu/s_signbitl.S
+++ b/sysdeps/sparc/sparc32/fpu/s_signbitl.S
@@ -1,5 +1,5 @@
/* signbitl(). sparc32 version.
- Copyright (C) 2012-2016 Free Software Foundation, Inc.
+ Copyright (C) 2012-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
diff --git a/sysdeps/sparc/sparc32/fpu/w_sqrt.S b/sysdeps/sparc/sparc32/fpu/w_sqrt.S
deleted file mode 100644
index 9c66b5c356..0000000000
--- a/sysdeps/sparc/sparc32/fpu/w_sqrt.S
+++ /dev/null
@@ -1,53 +0,0 @@
-/* sqrt function. sparc32 version.
- Copyright (C) 2012-2016 Free Software Foundation, Inc.
- This file is part of the GNU C Library.
-
- The GNU C Library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- The GNU C Library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, see
- <http://www.gnu.org/licenses/>. */
-
-#include <sysdep.h>
-
-ENTRY (__sqrt)
- clr %g1
- std %g0, [%sp + 72]
- std %o0, [%sp + 80]
- ldd [%sp + 72], %f8
- ldd [%sp + 80], %f0
- fcmpd %f0, %f8
- fbl 1f
- nop
-8: retl
- fsqrtd %f0, %f0
-1:
-#ifdef SHARED
- SETUP_PIC_REG_LEAF(o5, g1)
- sethi %gdop_hix22(_LIB_VERSION), %g1
- xor %g1, %gdop_lox10(_LIB_VERSION), %g1
- ld [%o5 + %g1], %g1, %gdop(_LIB_VERSION)
-#else
- sethi %hi(_LIB_VERSION), %g1
- or %g1, %lo(_LIB_VERSION), %g1
-#endif
- ld [%g1], %g1
- cmp %g1, -1
- be 8b
- mov %o0, %o2
- mov %o1, %o3
- mov 26, %o4
- mov %o7, %g1
- call __kernel_standard
- mov %g1, %o7
-END (__sqrt)
-
-weak_alias (__sqrt, sqrt)
diff --git a/sysdeps/sparc/sparc32/fpu/w_sqrtf.S b/sysdeps/sparc/sparc32/fpu/w_sqrtf.S
deleted file mode 100644
index a16ab4240a..0000000000
--- a/sysdeps/sparc/sparc32/fpu/w_sqrtf.S
+++ /dev/null
@@ -1,51 +0,0 @@
-/* sqrtf function. sparc32 version.
- Copyright (C) 2012-2016 Free Software Foundation, Inc.
- This file is part of the GNU C Library.
-
- The GNU C Library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- The GNU C Library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, see
- <http://www.gnu.org/licenses/>. */
-
-#include <sysdep.h>
-
-ENTRY (__sqrtf)
- st %g0, [%sp + 68]
- st %o0, [%sp + 72]
- ld [%sp + 68], %f8
- ld [%sp + 72], %f0
- fcmps %f0, %f8
- fbl 1f
- nop
-8: retl
- fsqrts %f0, %f0
-1:
-#ifdef SHARED
- SETUP_PIC_REG_LEAF(o5, g1)
- sethi %gdop_hix22(_LIB_VERSION), %g1
- xor %g1, %gdop_lox10(_LIB_VERSION), %g1
- ld [%o5 + %g1], %g1, %gdop(_LIB_VERSION)
-#else
- sethi %hi(_LIB_VERSION), %g1
- or %g1, %lo(_LIB_VERSION), %g1
-#endif
- ld [%g1], %g1
- cmp %g1, -1
- be 8b
- mov %o0, %o1
- mov 126, %o2
- mov %o7, %g1
- call __kernel_standard_f
- mov %g1, %o7
-END (__sqrtf)
-
-weak_alias (__sqrtf, sqrtf)