diff mbox series

Don't provide XXXf128_do_not_use aliases [BZ #31757]

Message ID 20240520122534.3225340-1-hjl.tools@gmail.com
State New
Headers show
Series Don't provide XXXf128_do_not_use aliases [BZ #31757] | expand

Commit Message

H.J. Lu May 20, 2024, 12:25 p.m. UTC
Don't provide __nexttowardf128_do_not_use, nexttowardf128_do_not_use,
finitef128_do_not_use, isinff128_do_not_use and isnanf128_do_not_use.
This fixes BZ #31757.

Signed-off-by: H.J. Lu <hjl.tools@gmail.com>
---
 sysdeps/ieee754/float128/s_isnanf128.c  | 2 ++
 sysdeps/ieee754/ldbl-128/s_finitel.c    | 2 ++
 sysdeps/ieee754/ldbl-128/s_isinfl.c     | 2 ++
 sysdeps/ieee754/ldbl-128/s_nextafterl.c | 4 ++++
 4 files changed, 10 insertions(+)

Comments

Adhemerval Zanella Netto May 22, 2024, 12:47 p.m. UTC | #1
On 20/05/24 09:25, H.J. Lu wrote:
> Don't provide __nexttowardf128_do_not_use, nexttowardf128_do_not_use,
> finitef128_do_not_use, isinff128_do_not_use and isnanf128_do_not_use.
> This fixes BZ #31757.
> 
> Signed-off-by: H.J. Lu <hjl.tools@gmail.com>

LGTM, thanks.

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>

> ---
>  sysdeps/ieee754/float128/s_isnanf128.c  | 2 ++
>  sysdeps/ieee754/ldbl-128/s_finitel.c    | 2 ++
>  sysdeps/ieee754/ldbl-128/s_isinfl.c     | 2 ++
>  sysdeps/ieee754/ldbl-128/s_nextafterl.c | 4 ++++
>  4 files changed, 10 insertions(+)
> 
> diff --git a/sysdeps/ieee754/float128/s_isnanf128.c b/sysdeps/ieee754/float128/s_isnanf128.c
> index 59f71533ce..e6eb2a200e 100644
> --- a/sysdeps/ieee754/float128/s_isnanf128.c
> +++ b/sysdeps/ieee754/float128/s_isnanf128.c
> @@ -12,7 +12,9 @@
>  #if !IS_IN (libm)
>  #include <float128-abi.h>
>  hidden_ver (__isnanf128_impl, __isnanf128)
> +#ifndef isnanl
>  _weak_alias (__isnanf128_impl, isnanl)
> +#endif
>  versioned_symbol (libc, __isnanf128_impl, __isnanf128, GLIBC_2_34);
>  #if (SHLIB_COMPAT (libc, FLOAT128_VERSION_M, GLIBC_2_34))
>  strong_alias (__isnanf128_impl, __isnanf128_alias)
> diff --git a/sysdeps/ieee754/ldbl-128/s_finitel.c b/sysdeps/ieee754/ldbl-128/s_finitel.c
> index bfdd88fbbb..f1fff0ced2 100644
> --- a/sysdeps/ieee754/ldbl-128/s_finitel.c
> +++ b/sysdeps/ieee754/ldbl-128/s_finitel.c
> @@ -32,4 +32,6 @@ int __finitel(_Float128 x)
>  				-0x7fff000000000000LL)>>63);
>  }
>  mathx_hidden_def (__finitel)
> +#ifndef finitel
>  weak_alias (__finitel, finitel)
> +#endif
> diff --git a/sysdeps/ieee754/ldbl-128/s_isinfl.c b/sysdeps/ieee754/ldbl-128/s_isinfl.c
> index baa9a98e80..a0fa0ba659 100644
> --- a/sysdeps/ieee754/ldbl-128/s_isinfl.c
> +++ b/sysdeps/ieee754/ldbl-128/s_isinfl.c
> @@ -24,4 +24,6 @@ __isinfl (_Float128 x)
>  	return ~(lx >> 63) & (hx >> 62);
>  }
>  mathx_hidden_def (__isinfl)
> +#ifndef isinfl
>  weak_alias (__isinfl, isinfl)
> +#endif
> diff --git a/sysdeps/ieee754/ldbl-128/s_nextafterl.c b/sysdeps/ieee754/ldbl-128/s_nextafterl.c
> index 90e71e3907..f3f3b138dd 100644
> --- a/sysdeps/ieee754/ldbl-128/s_nextafterl.c
> +++ b/sysdeps/ieee754/ldbl-128/s_nextafterl.c
> @@ -83,5 +83,9 @@ _Float128 __nextafterl(_Float128 x, _Float128 y)
>  	return x;
>  }
>  libm_alias_ldouble (__nextafter, nextafter)
> +#ifndef __nexttowardl
>  strong_alias (__nextafterl, __nexttowardl)
> +#endif
> +#ifndef nexttowardl
>  weak_alias (__nextafterl, nexttowardl)
> +#endif
diff mbox series

Patch

diff --git a/sysdeps/ieee754/float128/s_isnanf128.c b/sysdeps/ieee754/float128/s_isnanf128.c
index 59f71533ce..e6eb2a200e 100644
--- a/sysdeps/ieee754/float128/s_isnanf128.c
+++ b/sysdeps/ieee754/float128/s_isnanf128.c
@@ -12,7 +12,9 @@ 
 #if !IS_IN (libm)
 #include <float128-abi.h>
 hidden_ver (__isnanf128_impl, __isnanf128)
+#ifndef isnanl
 _weak_alias (__isnanf128_impl, isnanl)
+#endif
 versioned_symbol (libc, __isnanf128_impl, __isnanf128, GLIBC_2_34);
 #if (SHLIB_COMPAT (libc, FLOAT128_VERSION_M, GLIBC_2_34))
 strong_alias (__isnanf128_impl, __isnanf128_alias)
diff --git a/sysdeps/ieee754/ldbl-128/s_finitel.c b/sysdeps/ieee754/ldbl-128/s_finitel.c
index bfdd88fbbb..f1fff0ced2 100644
--- a/sysdeps/ieee754/ldbl-128/s_finitel.c
+++ b/sysdeps/ieee754/ldbl-128/s_finitel.c
@@ -32,4 +32,6 @@  int __finitel(_Float128 x)
 				-0x7fff000000000000LL)>>63);
 }
 mathx_hidden_def (__finitel)
+#ifndef finitel
 weak_alias (__finitel, finitel)
+#endif
diff --git a/sysdeps/ieee754/ldbl-128/s_isinfl.c b/sysdeps/ieee754/ldbl-128/s_isinfl.c
index baa9a98e80..a0fa0ba659 100644
--- a/sysdeps/ieee754/ldbl-128/s_isinfl.c
+++ b/sysdeps/ieee754/ldbl-128/s_isinfl.c
@@ -24,4 +24,6 @@  __isinfl (_Float128 x)
 	return ~(lx >> 63) & (hx >> 62);
 }
 mathx_hidden_def (__isinfl)
+#ifndef isinfl
 weak_alias (__isinfl, isinfl)
+#endif
diff --git a/sysdeps/ieee754/ldbl-128/s_nextafterl.c b/sysdeps/ieee754/ldbl-128/s_nextafterl.c
index 90e71e3907..f3f3b138dd 100644
--- a/sysdeps/ieee754/ldbl-128/s_nextafterl.c
+++ b/sysdeps/ieee754/ldbl-128/s_nextafterl.c
@@ -83,5 +83,9 @@  _Float128 __nextafterl(_Float128 x, _Float128 y)
 	return x;
 }
 libm_alias_ldouble (__nextafter, nextafter)
+#ifndef __nexttowardl
 strong_alias (__nextafterl, __nexttowardl)
+#endif
+#ifndef nexttowardl
 weak_alias (__nextafterl, nexttowardl)
+#endif