[gcc(refs/users/meissner/heads/work169-bugs)] Revert changes
Michael Meissner
meissner@gcc.gnu.org
Tue Jun 18 18:27:23 GMT 2024
https://gcc.gnu.org/g:0e66a6400cf99e965e679362eac65483f938b138
commit 0e66a6400cf99e965e679362eac65483f938b138
Author: Michael Meissner <meissner@linux.ibm.com>
Date: Tue Jun 18 14:27:18 2024 -0400
Revert changes
Diff:
---
libgfortran/configure | 7 +---
libgfortran/configure.ac | 3 --
libgfortran/kinds-override.h | 2 +-
libgfortran/libgfortran.h | 2 +-
libstdc++-v3/configure | 68 +++++++++----------------------
libstdc++-v3/configure.ac | 58 ++++++++++----------------
libstdc++-v3/include/ext/numeric_traits.h | 2 +-
7 files changed, 46 insertions(+), 96 deletions(-)
diff --git a/libgfortran/configure b/libgfortran/configure
index 2708e5c7eca4..11a1bc5f0708 100755
--- a/libgfortran/configure
+++ b/libgfortran/configure
@@ -5981,9 +5981,6 @@ if test "x$GCC" = "xyes"; then
#if __SIZEOF_LONG_DOUBLE__ != 16
#error long double is double
#endif
- #if !defined(__VSX__)
- #error VSX is not available
- #endif
int
main ()
{
@@ -12850,7 +12847,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 12853 "configure"
+#line 12850 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -12956,7 +12953,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 12959 "configure"
+#line 12956 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
diff --git a/libgfortran/configure.ac b/libgfortran/configure.ac
index cfaeb9717ab8..cca1ea0ea970 100644
--- a/libgfortran/configure.ac
+++ b/libgfortran/configure.ac
@@ -148,9 +148,6 @@ if test "x$GCC" = "xyes"; then
AC_PREPROC_IFELSE(
[AC_LANG_PROGRAM([[#if __SIZEOF_LONG_DOUBLE__ != 16
#error long double is double
- #endif
- #if !defined(__VSX__)
- #error VSX is not available
#endif]],
[[(void) 0;]])],
[AM_FCFLAGS="$AM_FCFLAGS -mabi=ibmlongdouble -mno-gnu-attribute";
diff --git a/libgfortran/kinds-override.h b/libgfortran/kinds-override.h
index 51f440e53232..f6b4956c5caa 100644
--- a/libgfortran/kinds-override.h
+++ b/libgfortran/kinds-override.h
@@ -30,7 +30,7 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
#endif
/* Keep these conditions on one line so grep can filter it out. */
-#if defined(__powerpc64__) && __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__ && __SIZEOF_LONG_DOUBLE__ == 16 && defined(__VSX__)
+#if defined(__powerpc64__) && __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__ && __SIZEOF_LONG_DOUBLE__ == 16
typedef _Float128 GFC_REAL_17;
typedef _Complex _Float128 GFC_COMPLEX_17;
#define HAVE_GFC_REAL_17
diff --git a/libgfortran/libgfortran.h b/libgfortran/libgfortran.h
index 236603352435..5c59ec26e16c 100644
--- a/libgfortran/libgfortran.h
+++ b/libgfortran/libgfortran.h
@@ -104,7 +104,7 @@ typedef off_t gfc_offset;
#endif
#if defined(__powerpc64__) && __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__ \
- && defined __GLIBC_PREREQ && defined(__VSX__)
+ && defined __GLIBC_PREREQ
#if __GLIBC_PREREQ (2, 32)
#define POWER_IEEE128 1
#endif
diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure
index 706dcbefe11a..5645e991af7a 100755
--- a/libstdc++-v3/configure
+++ b/libstdc++-v3/configure
@@ -51355,31 +51355,8 @@ $as_echo "#define _GLIBCXX_LONG_DOUBLE_COMPAT 1" >>confdefs.h
case "$target" in
powerpc*-*-linux*)
LONG_DOUBLE_COMPAT_FLAGS="$LONG_DOUBLE_COMPAT_FLAGS -mno-gnu-attribute"
- # Eliminate little endian systems without VSX
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- #if __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__ && !defined(__VSX__)
- #error "IEEE 128-bit cannot be supported on non-VSX little endian systems"
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_ieee128_possible=yes
-else
- ac_ieee128_possible=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- if test $ac_ieee128_possible = yes; then
- # Check for IEEE128 support in libm:
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __frexpieee128 in -lm" >&5
+ # Check for IEEE128 support in libm:
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __frexpieee128 in -lm" >&5
$as_echo_n "checking for __frexpieee128 in -lm... " >&6; }
if ${ac_cv_lib_m___frexpieee128+:} false; then :
$as_echo_n "(cached) " >&6
@@ -51424,18 +51401,18 @@ else
ac_ldbl_ieee128_in_libc=no
fi
- if test $ac_ldbl_ieee128_in_libc = yes; then
- # Determine which long double format is the compiler's default:
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ if test $ac_ldbl_ieee128_in_libc = yes; then
+ # Determine which long double format is the compiler's default:
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
main ()
{
- #ifndef __LONG_DOUBLE_IEEE128__
- #error compiler defaults to ibm128
- #endif
+ #ifndef __LONG_DOUBLE_IEEE128__
+ #error compiler defaults to ibm128
+ #endif
;
return 0;
@@ -51447,28 +51424,21 @@ else
ac_ldbl_ieee128_default=no
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- # Library objects should use default long double format.
- if test "$ac_ldbl_ieee128_default" = yes; then
- LONG_DOUBLE_128_FLAGS="-mno-gnu-attribute"
- # Except for the ones that explicitly use these flags:
- LONG_DOUBLE_ALT128_COMPAT_FLAGS="-mabi=ibmlongdouble -mno-gnu-attribute -Wno-psabi"
- else
- LONG_DOUBLE_128_FLAGS="-mno-gnu-attribute"
- LONG_DOUBLE_ALT128_COMPAT_FLAGS="-mabi=ieeelongdouble -mno-gnu-attribute -Wno-psabi"
- fi
-
-$as_echo "#define _GLIBCXX_LONG_DOUBLE_ALT128_COMPAT 1" >>confdefs.h
-
- port_specific_symbol_files="$port_specific_symbol_files \$(top_srcdir)/config/os/gnu-linux/ldbl-ieee128-extra.ver"
- ac_ldbl_alt128_compat=yes
+ # Library objects should use default long double format.
+ if test "$ac_ldbl_ieee128_default" = yes; then
+ LONG_DOUBLE_128_FLAGS="-mno-gnu-attribute"
+ # Except for the ones that explicitly use these flags:
+ LONG_DOUBLE_ALT128_COMPAT_FLAGS="-mabi=ibmlongdouble -mno-gnu-attribute -Wno-psabi"
else
- ac_ldbl_alt128_compat=no
+ LONG_DOUBLE_128_FLAGS="-mno-gnu-attribute"
+ LONG_DOUBLE_ALT128_COMPAT_FLAGS="-mabi=ieeelongdouble -mno-gnu-attribute -Wno-psabi"
fi
- # IEEE 128-bit not possible
+$as_echo "#define _GLIBCXX_LONG_DOUBLE_ALT128_COMPAT 1" >>confdefs.h
+
+ port_specific_symbol_files="$port_specific_symbol_files \$(top_srcdir)/config/os/gnu-linux/ldbl-ieee128-extra.ver"
+ ac_ldbl_alt128_compat=yes
else
- acl_ldbl_ieee128_in_libc=no
- acl_ldbl_ieee128_default=no
ac_ldbl_alt128_compat=no
fi
;;
diff --git a/libstdc++-v3/configure.ac b/libstdc++-v3/configure.ac
index d5d42a4766a6..ccb24a82be79 100644
--- a/libstdc++-v3/configure.ac
+++ b/libstdc++-v3/configure.ac
@@ -479,45 +479,31 @@ case "$target" in
case "$target" in
powerpc*-*-linux*)
LONG_DOUBLE_COMPAT_FLAGS="$LONG_DOUBLE_COMPAT_FLAGS -mno-gnu-attribute"
- # Eliminate little endian systems without VSX
- AC_TRY_COMPILE(, [
- #if __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__ && !defined(__VSX__)
- #error "IEEE 128-bit cannot be supported on non-VSX little endian systems"
- #endif
- ], [ac_ieee128_possible=yes], [ac_ieee128_possible=no])
- if test $ac_ieee128_possible = yes; then
- # Check for IEEE128 support in libm:
- AC_CHECK_LIB(m, __frexpieee128,
- [ac_ldbl_ieee128_in_libc=yes],
- [ac_ldbl_ieee128_in_libc=no])
- if test $ac_ldbl_ieee128_in_libc = yes; then
- # Determine which long double format is the compiler's default:
- AC_TRY_COMPILE(, [
- #ifndef __LONG_DOUBLE_IEEE128__
- #error compiler defaults to ibm128
- #endif
- ], [ac_ldbl_ieee128_default=yes], [ac_ldbl_ieee128_default=no])
- # Library objects should use default long double format.
- if test "$ac_ldbl_ieee128_default" = yes; then
- LONG_DOUBLE_128_FLAGS="-mno-gnu-attribute"
- # Except for the ones that explicitly use these flags:
- LONG_DOUBLE_ALT128_COMPAT_FLAGS="-mabi=ibmlongdouble -mno-gnu-attribute -Wno-psabi"
- else
- LONG_DOUBLE_128_FLAGS="-mno-gnu-attribute"
- LONG_DOUBLE_ALT128_COMPAT_FLAGS="-mabi=ieeelongdouble -mno-gnu-attribute -Wno-psabi"
- fi
- AC_DEFINE([_GLIBCXX_LONG_DOUBLE_ALT128_COMPAT],1,
- [Define if compatibility should be provided for alternative 128-bit long double formats.])
- port_specific_symbol_files="$port_specific_symbol_files \$(top_srcdir)/config/os/gnu-linux/ldbl-ieee128-extra.ver"
- ac_ldbl_alt128_compat=yes
+ # Check for IEEE128 support in libm:
+ AC_CHECK_LIB(m, __frexpieee128,
+ [ac_ldbl_ieee128_in_libc=yes],
+ [ac_ldbl_ieee128_in_libc=no])
+ if test $ac_ldbl_ieee128_in_libc = yes; then
+ # Determine which long double format is the compiler's default:
+ AC_TRY_COMPILE(, [
+ #ifndef __LONG_DOUBLE_IEEE128__
+ #error compiler defaults to ibm128
+ #endif
+ ], [ac_ldbl_ieee128_default=yes], [ac_ldbl_ieee128_default=no])
+ # Library objects should use default long double format.
+ if test "$ac_ldbl_ieee128_default" = yes; then
+ LONG_DOUBLE_128_FLAGS="-mno-gnu-attribute"
+ # Except for the ones that explicitly use these flags:
+ LONG_DOUBLE_ALT128_COMPAT_FLAGS="-mabi=ibmlongdouble -mno-gnu-attribute -Wno-psabi"
else
- ac_ldbl_alt128_compat=no
+ LONG_DOUBLE_128_FLAGS="-mno-gnu-attribute"
+ LONG_DOUBLE_ALT128_COMPAT_FLAGS="-mabi=ieeelongdouble -mno-gnu-attribute -Wno-psabi"
fi
-
- # IEEE 128-bit not possible
+ AC_DEFINE([_GLIBCXX_LONG_DOUBLE_ALT128_COMPAT],1,
+ [Define if compatibility should be provided for alternative 128-bit long double formats.])
+ port_specific_symbol_files="$port_specific_symbol_files \$(top_srcdir)/config/os/gnu-linux/ldbl-ieee128-extra.ver"
+ ac_ldbl_alt128_compat=yes
else
- acl_ldbl_ieee128_in_libc=no
- acl_ldbl_ieee128_default=no
ac_ldbl_alt128_compat=no
fi
;;
diff --git a/libstdc++-v3/include/ext/numeric_traits.h b/libstdc++-v3/include/ext/numeric_traits.h
index 0f00abb3db66..b2723bfabfa5 100644
--- a/libstdc++-v3/include/ext/numeric_traits.h
+++ b/libstdc++-v3/include/ext/numeric_traits.h
@@ -218,7 +218,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
struct __numeric_traits<__ibm128>
: public __numeric_traits_floating<__ibm128>
{ };
-# elif defined __LONG_DOUBLE_IBM128__ && defined __VSX__
+# elif defined __LONG_DOUBLE_IBM128__
// long double is __ibm128, define traits for __ieee128
template<>
struct __numeric_traits_floating<__ieee128>
More information about the Gcc-cvs
mailing list