]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
s390: Remove s390-32 specific code in non s390-32 specific files
authorStefan Liebler <stli@linux.ibm.com>
Thu, 9 Apr 2026 08:47:07 +0000 (10:47 +0200)
committerStefan Liebler <stli@linux.ibm.com>
Mon, 20 Apr 2026 11:54:14 +0000 (13:54 +0200)
This patch removes s390-32 specific code in either common-code files
or shared files between s390-64 and s390-32.

Such code was guarded with preprocessor guards which check the size
of __WORDSIZE or __ELF_NATIVE_CLASS and of course the existance of
__s390x__ and __s390__ macros.

Note, that if __s390x__ is defined then __s390__ is also defined.
This patch also adjust guards for __s390__ only to __s390x__ to
make clear that those are still needed.

Futhermore the macro names for ifunc variants were adjusted from
XYZ_Z900_G5 to XYZ_Z900 as G5 is a pre 64bit machine.

On s390-32 we've used the special assembler directive to enable
zarch instructions:
.machinemode "zarch_nohighgprs"
As this is not needed on s390-64 anymore as zarch is enabled by default,
just drop those lines.
Furthermore we do not check for HWCAP_S390_ZARCH and HWCAP_S390_HIGH_GPRS
anymore. Just simplify those checks for e.g. stfle- or cuXY-instructions.

The 32/64 abi-variants and the corresponding abi-conditions are now also
removed from the s390 Makefiles and thus we now only generate a single
gnu/stubs.h and gnu/lib-names.h file instead of also having the different
ones for both abi-variants.

After removing process_elf32_file in s390 readelflib.c, ldconfig is only
recognizing 64bit ELF files for ld.so.cache.

Various comments mentioning s390 (with meaning s390-32) were removed/adjusted.
Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
137 files changed:
README
elf/elf.h
intl/dcigettext.c
manual/math.texi
stdlib/test-bz22786.c
string/string-inlines.c
support/support_readdir.c
sysdeps/s390/bits/link.h
sysdeps/s390/bits/setjmp.h
sysdeps/s390/configure
sysdeps/s390/configure.ac
sysdeps/s390/cpu-features.c
sysdeps/s390/dl-tls.h
sysdeps/s390/fpu/fenv_private.h
sysdeps/s390/fpu/s_llrint.c
sysdeps/s390/fpu/s_llrintf.c
sysdeps/s390/fpu/s_llrintl.c
sysdeps/s390/fpu/s_llround.c
sysdeps/s390/fpu/s_llroundf.c
sysdeps/s390/fpu/s_llroundl.c
sysdeps/s390/fpu/s_lrint.c
sysdeps/s390/fpu/s_lrintf.c
sysdeps/s390/fpu/s_lrintl.c
sysdeps/s390/fpu/s_lround.c
sysdeps/s390/fpu/s_lroundf.c
sysdeps/s390/fpu/s_lroundl.c
sysdeps/s390/ifunc-memchr.h
sysdeps/s390/ifunc-memcmp.h
sysdeps/s390/ifunc-memcpy.h
sysdeps/s390/ifunc-memset.h
sysdeps/s390/ifunc-strcmp.h
sysdeps/s390/ifunc-strcpy.h
sysdeps/s390/ifunc-strncpy.h
sysdeps/s390/iso-8859-1_cp037_z900.c
sysdeps/s390/jmpbuf-unwind.h
sysdeps/s390/ldsodefs.h
sysdeps/s390/linkmap.h
sysdeps/s390/memccpy-vx.S
sysdeps/s390/memchr-vx.S
sysdeps/s390/memchr-z900.S
sysdeps/s390/memchr.c
sysdeps/s390/memcmp-z900.S
sysdeps/s390/memcmp.c
sysdeps/s390/memcopy.h
sysdeps/s390/memcpy-z900.S
sysdeps/s390/memcpy.c
sysdeps/s390/memmem-arch13.S
sysdeps/s390/mempcpy.c
sysdeps/s390/memrchr-vx.S
sysdeps/s390/memset-z900.S
sysdeps/s390/memset.c
sysdeps/s390/multiarch/8bit-generic.c
sysdeps/s390/multiarch/gconv_simple.c
sysdeps/s390/multiarch/ifunc-impl-list.c
sysdeps/s390/multiarch/ifunc-resolve.h
sysdeps/s390/multiarch/utf8-utf16-z9.c
sysdeps/s390/multiarch/utf8-utf32-z9.c
sysdeps/s390/nptl/bits/struct_mutex.h
sysdeps/s390/nptl/bits/struct_rwlock.h
sysdeps/s390/nptl/pthread-offsets.h
sysdeps/s390/nptl/tls.h
sysdeps/s390/rawmemchr-vx.S
sysdeps/s390/s390-64/bits/wordsize.h
sysdeps/s390/s390-64/stackguard-macros.h
sysdeps/s390/s390-64/strncpy-z900.S
sysdeps/s390/sotruss-lib.c
sysdeps/s390/stpcpy-vx.S
sysdeps/s390/stpncpy-vx.S
sysdeps/s390/strcat-vx.S
sysdeps/s390/strchr-vx.S
sysdeps/s390/strchrnul-vx.S
sysdeps/s390/strcmp-vx.S
sysdeps/s390/strcmp-z900.S
sysdeps/s390/strcmp.c
sysdeps/s390/strcpy-vx.S
sysdeps/s390/strcpy-z900.S
sysdeps/s390/strcpy.c
sysdeps/s390/strcspn-vx.S
sysdeps/s390/strlen-vx.S
sysdeps/s390/strncat-vx.S
sysdeps/s390/strncmp-vx.S
sysdeps/s390/strncpy-vx.S
sysdeps/s390/strncpy.c
sysdeps/s390/strnlen-vx.S
sysdeps/s390/strpbrk-vx.S
sysdeps/s390/strrchr-vx.S
sysdeps/s390/strspn-vx.S
sysdeps/s390/strstr-arch13.S
sysdeps/s390/tst-dl-runtime-mod.S
sysdeps/s390/tst-dl-runtime.c
sysdeps/s390/utf16-utf32-z9.c
sysdeps/s390/utf8-utf16-z9.c
sysdeps/s390/utf8-utf32-z9.c
sysdeps/s390/wcpcpy-vx.S
sysdeps/s390/wcpncpy-vx.S
sysdeps/s390/wcscat-vx.S
sysdeps/s390/wcschr-vx.S
sysdeps/s390/wcschrnul-vx.S
sysdeps/s390/wcscmp-vx.S
sysdeps/s390/wcscpy-vx.S
sysdeps/s390/wcscspn-vx.S
sysdeps/s390/wcslen-vx.S
sysdeps/s390/wcsncat-vx.S
sysdeps/s390/wcsncmp-vx.S
sysdeps/s390/wcsncpy-vx.S
sysdeps/s390/wcsnlen-vx.S
sysdeps/s390/wcspbrk-vx.S
sysdeps/s390/wcsrchr-vx.S
sysdeps/s390/wcsspn-vx.S
sysdeps/s390/wmemchr-vx.S
sysdeps/s390/wmemcmp-vx.S
sysdeps/s390/wmemset-vx.S
sysdeps/unix/sysv/linux/fxstat.c
sysdeps/unix/sysv/linux/fxstatat.c
sysdeps/unix/sysv/linux/ipc_priv.h
sysdeps/unix/sysv/linux/kernel-features.h
sysdeps/unix/sysv/linux/lxstat.c
sysdeps/unix/sysv/linux/lxstat64.c
sysdeps/unix/sysv/linux/posix_fadvise.c
sysdeps/unix/sysv/linux/posix_fadvise64.c
sysdeps/unix/sysv/linux/s390/Makefile
sysdeps/unix/sysv/linux/s390/bits/elfclass.h
sysdeps/unix/sysv/linux/s390/bits/fcntl.h
sysdeps/unix/sysv/linux/s390/bits/sigaction.h
sysdeps/unix/sysv/linux/s390/bits/struct_stat.h
sysdeps/unix/sysv/linux/s390/bits/typesizes.h
sysdeps/unix/sysv/linux/s390/kernel-features.h
sysdeps/unix/sysv/linux/s390/readelflib.c
sysdeps/unix/sysv/linux/s390/s390-64/Makefile
sysdeps/unix/sysv/linux/s390/sigcontextinfo.h
sysdeps/unix/sysv/linux/s390/sys/ucontext.h
sysdeps/unix/sysv/linux/s390/sysconf.c
sysdeps/unix/sysv/linux/s390/sysdep.h
sysdeps/unix/sysv/linux/s390/xstatver.h
sysdeps/unix/sysv/linux/tst-ofdlocks-compat.c
sysdeps/unix/sysv/linux/xstat.c
sysdeps/unix/sysv/linux/xstat64.c

diff --git a/README b/README
index 2e360eb70af875d5b948512c19a88193d3060bbd..570b259de56871e2164e857edd217fe196b0547a 100644 (file)
--- a/README
+++ b/README
@@ -38,7 +38,6 @@ The GNU C Library supports these configurations for using Linux kernels:
        or1k-*-linux-gnu
        powerpc-*-linux-gnu     Hardware or software floating point, BE only.
        powerpc64*-*-linux-gnu  Big-endian and little-endian.
-       s390-*-linux-gnu
        s390x-*-linux-gnu
        riscv32-*-linux-gnu
        riscv64-*-linux-gnu
index 46a01281cb0fb5322d5124f0443c11dea4d5b721..3a60ef36b55e571cb0913425e645581bdc594545 100644 (file)
--- a/elf/elf.h
+++ b/elf/elf.h
@@ -798,7 +798,8 @@ typedef struct
 #define NT_X86_XSTATE  0x202           /* x86 extended state using xsave */
 #define NT_X86_SHSTK   0x204           /* x86 SHSTK state */
 #define NT_X86_XSAVE_LAYOUT    0x205           /* XSAVE layout description.  */
-#define NT_S390_HIGH_GPRS      0x300   /* s390 upper register halves */
+#define NT_S390_HIGH_GPRS      0x300   /* s390 upper register halves.  This was
+                                          used in now removed s390-32 arch.  */
 #define NT_S390_TIMER  0x301           /* s390 timer register */
 #define NT_S390_TODCMP 0x302           /* s390 TOD clock comparator register */
 #define NT_S390_TODPREG        0x303           /* s390 TOD programmable register */
@@ -3470,7 +3471,9 @@ enum
 
 /* Valid values for the e_flags field.  */
 
-#define EF_S390_HIGH_GPRS    0x00000001  /* High GPRs kernel facility needed.  */
+#define EF_S390_HIGH_GPRS    0x00000001  /* High GPRs kernel facility needed.
+                                           This was used in now removed s390-32
+                                           arch.  */
 
 /* Additional s390 relocs */
 
index e70c938566b92b70149424d6a5f0ce8303d82893..9ebc54eeec4d03522e825bfc012f99f1aff3950b 100644 (file)
@@ -72,7 +72,7 @@ extern int errno;
   /* Guess whether integer division by zero raises signal SIGFPE.
      Set to 1 only if you know for sure.  In case of doubt, set to 0.  */
 # if defined __alpha__ || defined __arm__ || defined __i386__ \
-     || defined __m68k__ || defined __s390__
+     || defined __m68k__ || defined __s390x__
 #  define INTDIV0_RAISES_SIGFPE 1
 # else
 #  define INTDIV0_RAISES_SIGFPE 0
index fd7284953d3599021e31da8ea8293ff2553f0a78..cf579379434aee41209293f7cbced73d505b3bd6 100644 (file)
@@ -70,7 +70,7 @@ provided for @code{_Float32}, @code{_Float64} and @code{_Float32x} on
 all platforms.
 It is also provided for @code{_Float128} and @code{_Float64x} on
 powerpc64le (PowerPC 64-bits little-endian), x86_64, x86,
-aarch64, alpha, loongarch, mips64, riscv, s390 and sparc.
+aarch64, alpha, loongarch, mips64, riscv, s390x and sparc.
 
 @menu
 * Mathematical Constants::      Precise numeric values for often-used
index 242a3044db2dc36969a51d5ea562384a421faccd..6e2636d896c6fa8d13df092f82ada2e00245c967 100644 (file)
@@ -46,9 +46,7 @@ do_test (void)
   if (path == NULL)
     {
       printf ("Repeated allocation (%zu bytes): %m\n", path_len);
-      /* On 31-bit s390 the malloc will always fail as we do not have
-        so much memory, and we want to mark the test unsupported.
-        Likewise on systems with little physical memory the test will
+      /* On systems with little physical memory the test will
         fail and should be unsupported.  */
       return EXIT_UNSUPPORTED;
     }
index 7de9ff6aa46af37d450e2e9642504e0a6addc894..bab58c91a20fb643af7e53cc89830000be2b8ed8 100644 (file)
@@ -208,7 +208,7 @@ __old_strpbrk_c3 (const char *__s, int __accept1, int __accept2, int __accept3)
 }
 compat_symbol (libc, __old_strpbrk_c3, __strpbrk_c3, GLIBC_2_1_1);
 
-# if defined __mc68020__ || defined __s390__ || defined __i386__
+# if defined __mc68020__ || defined __s390x__ || defined __i386__
 #  define _STRING_INLINE_unaligned 1
 # else
 #  define _STRING_INLINE_unaligned 0
index 6cb6b6bfcdd3018b497cf21fb9b4bc7012a69759..793b7bc87ebd27aebaff9de1571350839b8355ed 100644 (file)
@@ -42,8 +42,8 @@ static int (*readdir64_r_compat) (DIR *, struct __old_dirent64 *,
 static void __attribute__ ((constructor))
 init (void)
 {
-  /* These compat symbols exists on alpha, i386, m67k , powerpc, s390,
-     sparc. at the same GLIBC_2.1 version. */
+  /* These compat symbols exists on alpha, i386, m67k , powerpc, sparc
+     at the same GLIBC_2.1 version. */
   readdir64_compat = dlvsym (RTLD_DEFAULT, "readdir64", "GLIBC_2.1");
   readdir64_r_compat = dlvsym (RTLD_DEFAULT, "readdir64_r", "GLIBC_2.1");
 }
index c9f6aab63ce75ccce24598ab0b492c513832e7df..794d6ca286fb59780cb060b2247a74fa41854d76 100644 (file)
 typedef char La_s390_vr[16];
 #endif
 
-#if __ELF_NATIVE_CLASS == 32
-
-/* Registers for entry into PLT on s390-32.  */
-typedef struct La_s390_32_regs
-{
-  uint32_t lr_r2;
-  uint32_t lr_r3;
-  uint32_t lr_r4;
-  uint32_t lr_r5;
-  uint32_t lr_r6;
-  double lr_fp0;
-  double lr_fp2;
-# if defined HAVE_S390_VX_ASM_SUPPORT
-  La_s390_vr lr_v24;
-  La_s390_vr lr_v25;
-  La_s390_vr lr_v26;
-  La_s390_vr lr_v27;
-  La_s390_vr lr_v28;
-  La_s390_vr lr_v29;
-  La_s390_vr lr_v30;
-  La_s390_vr lr_v31;
-# endif
-} La_s390_32_regs;
-
-/* Return values for calls from PLT on s390-32.  */
-typedef struct La_s390_32_retval
-{
-  uint32_t lrv_r2;
-  uint32_t lrv_r3;
-  double lrv_fp0;
-# if defined HAVE_S390_VX_ASM_SUPPORT
-  La_s390_vr lrv_v24;
-# endif
-} La_s390_32_retval;
-
-
-__BEGIN_DECLS
-
-extern Elf32_Addr la_s390_32_gnu_pltenter (Elf32_Sym *__sym,
-                                          unsigned int __ndx,
-                                          uintptr_t *__refcook,
-                                          uintptr_t *__defcook,
-                                          La_s390_32_regs *__regs,
-                                          unsigned int *__flags,
-                                          const char *__symname,
-                                          long int *__framesizep);
-extern unsigned int la_s390_32_gnu_pltexit (Elf32_Sym *__sym,
-                                           unsigned int __ndx,
-                                           uintptr_t *__refcook,
-                                           uintptr_t *__defcook,
-                                           const La_s390_32_regs *__inregs,
-                                           La_s390_32_retval *__outregs,
-                                           const char *symname);
-
-__END_DECLS
-
-#else
-
 /* Registers for entry into PLT on s390-64.  */
 typedef struct La_s390_64_regs
 {
@@ -135,5 +77,3 @@ extern unsigned int la_s390_64_gnu_pltexit (Elf64_Sym *__sym,
                                            const char *__symname);
 
 __END_DECLS
-
-#endif
index 4b87fe55a1e0a408513c0c1f9861784be69ee2d2..3afa770bf789b350698a613796be3916bd045822 100644 (file)
@@ -33,13 +33,7 @@ typedef struct __s390_jmp_buf
   /* We save registers 6-15.  */
   long int __gregs[10];
 
-# if __WORDSIZE == 64
-  /* We save fpu registers f8 - f15.  */
   long __fpregs[8];
-# else
-  /* We save fpu registers 4 and 6.  */
-  long __fpregs[4];
-# endif
 } __jmp_buf[1];
 
 #endif
index e3766aa8013b7e31c977e62271c776c518261ee1..f4ec6626101ec1ee632d705b11c1d89665749412 100644 (file)
@@ -15,7 +15,6 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 void testvecinsn ()
 {
     __asm__ (".machine \"z13\" \n\t"
-            ".machinemode \"zarch_nohighgprs\" \n\t"
             "vistrbs %%v16,%%v17 \n\t"
             "locghie %%r1,0" : :);
 }
@@ -91,7 +90,6 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 void testinsn (char *buf)
 {
     __asm__ (".machine \"arch13\" \n\t"
-            ".machinemode \"zarch_nohighgprs\" \n\t"
             "lghi %%r0,16 \n\t"
             "mvcrl 0(%0),32(%0) \n\t"
             "vstrs %%v20,%%v20,%%v20,%%v20,0,2"
index 4265bfd9f47217cea9fa2c4d9f6141eb921d6e93..82e1a4445fd27216d336d6c25b7d0a37e349ef9b 100644 (file)
@@ -6,7 +6,6 @@ AC_COMPILE_IFELSE([AC_LANG_SOURCE([[
 void testvecinsn ()
 {
     __asm__ (".machine \"z13\" \n\t"
-            ".machinemode \"zarch_nohighgprs\" \n\t"
             "vistrbs %%v16,%%v17 \n\t"
             "locghie %%r1,0" : :);
 }
@@ -43,7 +42,6 @@ AC_COMPILE_IFELSE([AC_LANG_SOURCE([[
 void testinsn (char *buf)
 {
     __asm__ (".machine \"arch13\" \n\t"
-            ".machinemode \"zarch_nohighgprs\" \n\t"
             "lghi %%r0,16 \n\t"
             "mvcrl 0(%0),32(%0) \n\t"
             "vstrs %%v20,%%v20,%%v20,%%v20,0,2"
index 76e9079bd403f0adf97e4e69fd148fc35f535e4c..fd6f2357d5127722a7dce9720fafcdb54ff74a11 100644 (file)
@@ -170,15 +170,12 @@ init_cpu_features_no_tunables (struct cpu_features *cpu_features)
   cpu_features->hwcap = GLRO(dl_hwcap);
 
   /* We want just 1 double word to be returned.  */
-  if (__glibc_likely ((cpu_features->hwcap & HWCAP_S390_STFLE)
-                     && (cpu_features->hwcap & HWCAP_S390_ZARCH)
-                     && (cpu_features->hwcap & HWCAP_S390_HIGH_GPRS)))
+  if (__glibc_likely ((cpu_features->hwcap & HWCAP_S390_STFLE)))
     {
       unsigned long long stfle_bits[4] = { 0 };
       register unsigned long reg0 __asm__("0") = 3;
       __asm__ __volatile__(".machine push"        "\n\t"
                           ".machine \"z9-109\""  "\n\t"
-                          ".machinemode \"zarch_nohighgprs\"\n\t"
                           "stfle %0"             "\n\t"
                           ".machine pop"         "\n"
                           : "=QS" (stfle_bits[0]),
index eff8cb61b307ddd32685d4c29c0d25abd3081bf8..4c4f8e7b44b4d0c7435d47237c7853e767ccada8 100644 (file)
@@ -69,7 +69,6 @@ versioned_symbol (ld, __tls_get_addr_internal_tmp,
    2) __tls_get_offset returns the offset of the requested variable to
       the thread descriptor instead of a pointer to the variable.
  */
-#  ifdef __s390x__
 __asm__("\n\
        .text\n\
        .globl __tls_get_offset\n\
@@ -79,20 +78,6 @@ __tls_get_offset:\n\
        la      %r2,0(%r2,%r12)\n\
        jg      __tls_get_addr\n\
 ");
-#  elif defined __s390__
-__asm__("\n\
-       .text\n\
-       .globl __tls_get_offset\n\
-       .type __tls_get_offset, @function\n\
-       .align 4\n\
-__tls_get_offset:\n\
-       basr    %r3,0\n\
-0:     la      %r2,0(%r2,%r12)\n\
-       l       %r4,1f-0b(%r3)\n\
-       b       0(%r4,%r3)\n\
-1:     .long   __tls_get_addr - 0b\n\
-");
-#  endif
 # else /* IS_IN (rtld) */
 extern void *__tls_get_addr_internal (tls_index *ti);
 # endif /* !IS_IN (rtld) */
index fbefc7889cda553464c9651e73b9f55306a389cf..42eb94cd151f4902b354d4686d4c8654129abff6 100644 (file)
@@ -1,4 +1,4 @@
-/* Private floating point rounding and exceptions handling.  390/s390x version.
+/* Private floating point rounding and exceptions handling.  s390x version.
    Copyright (C) 2019-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
index ae628b302594fbfb8e2934a5df8da56e39d18758..03937b79a9df5609c4e9aab7ed5ccf214bba84a8 100644 (file)
    License along with the GNU C Library; if not, see
    <https://www.gnu.org/licenses/>.  */
 
-#if defined __s390x__ && defined HAVE_S390_MIN_Z196_ZARCH_ASM_SUPPORT
-/* We only support s390x as on s390 a long long int refers to a register pair
-   of two 4byte registers instead of a 8byte register which is produced by the
-   instruction.
-   Note: On s390 this instruction would only be used if build with -mzarch.  */
+#ifdef HAVE_S390_MIN_Z196_ZARCH_ASM_SUPPORT
 # include <math.h>
 # include <libm-alias-double.h>
 
index b94705da42f2adbfcf8366536886dd6ac35bd186..c3a8638c7c670a39358337569bc527790fb16bfc 100644 (file)
    License along with the GNU C Library; if not, see
    <https://www.gnu.org/licenses/>.  */
 
-#if defined __s390x__ && defined HAVE_S390_MIN_Z196_ZARCH_ASM_SUPPORT
-/* We only support s390x as on s390 a long long int refers to a register pair
-   of two 4byte registers instead of a 8byte register which is produced by the
-   instruction.
-   Note: On s390 this instruction would only be used if build with -mzarch.  */
+#ifdef HAVE_S390_MIN_Z196_ZARCH_ASM_SUPPORT
 # include <math.h>
 # include <libm-alias-float.h>
 
index 61938b67ee903732d3b307f3005bc9d890eee58a..5c3c0536b007ff4999a0c550d25bf1fc4344b3e1 100644 (file)
    License along with the GNU C Library; if not, see
    <https://www.gnu.org/licenses/>.  */
 
-#if defined __s390x__ && defined HAVE_S390_MIN_Z196_ZARCH_ASM_SUPPORT
-/* We only support s390x as on s390 a long long int refers to a register pair
-   of two 4byte registers instead of a 8byte register which is produced by the
-   instruction.
-   Note: On s390 this instruction would only be used if build with -mzarch.  */
+#ifdef HAVE_S390_MIN_Z196_ZARCH_ASM_SUPPORT
 # include <math.h>
 # include <math_private.h>
 # include <libm-alias-ldouble.h>
index 0d598c4bd52fd9f70db62dad5d7c804ce785df05..c625322384f2705c278822de454dfcf972006f32 100644 (file)
    License along with the GNU C Library; if not, see
    <https://www.gnu.org/licenses/>.  */
 
-#if defined __s390x__ && defined HAVE_S390_MIN_Z196_ZARCH_ASM_SUPPORT
-/* We only support s390x as on s390 a long long int refers to a register pair
-   of two 4byte registers instead of a 8byte register which is produced by the
-   instruction.
-   Note: On s390 this instruction would only be used if build with -mzarch.  */
+#ifdef HAVE_S390_MIN_Z196_ZARCH_ASM_SUPPORT
 # include <math.h>
 # include <libm-alias-double.h>
 
index 5b77705f1a61a57414071707ceaf74890ae00299..cdea8fc4f3304883f4da9ec35a2bfc34348cb651 100644 (file)
    License along with the GNU C Library; if not, see
    <https://www.gnu.org/licenses/>.  */
 
-#if defined __s390x__ && defined HAVE_S390_MIN_Z196_ZARCH_ASM_SUPPORT
-/* We only support s390x as on s390 a long long int refers to a register pair
-   of two 4byte registers instead of a 8byte register which is produced by the
-   instruction.
-   Note: On s390 this instruction would only be used if build with -mzarch.  */
+#ifdef HAVE_S390_MIN_Z196_ZARCH_ASM_SUPPORT
 # include <math.h>
 # include <libm-alias-float.h>
 
index fff507979f7cce58bf5048e7c8ba3d4684387f7b..39d533b36caf3b1d11c05140ec9f0ecd10d28eb2 100644 (file)
    License along with the GNU C Library; if not, see
    <https://www.gnu.org/licenses/>.  */
 
-#if defined __s390x__ && defined HAVE_S390_MIN_Z196_ZARCH_ASM_SUPPORT
-/* We only support s390x as on s390 a long long int refers to a register pair
-   of two 4byte registers instead of a 8byte register which is produced by the
-   instruction.
-   Note: On s390 this instruction would only be used if build with -mzarch.  */
+#ifdef HAVE_S390_MIN_Z196_ZARCH_ASM_SUPPORT
 # include <math.h>
 # include <math_private.h>
 # include <libm-alias-ldouble.h>
index e6c0117dcad3231a6f3eb434eadcc1db3760d70d..6c99bab4b6a6814b51d71e0f9e2c25132fd609e1 100644 (file)
 # include <math.h>
 # include <libm-alias-double.h>
 
-/* The sizeof (long int) differs between s390x (8byte) and s390 (4byte).
-   Thus we need different instructions as the target size is encoded there.
-   Note: On s390 this instruction is only used if build with -mzarch.  */
-# ifdef __s390x__
-#  define INSN "cgdbra"
-# else
-#  define INSN "cfdbra"
-# endif
-
 long int
 __lrint (double x)
 {
@@ -41,9 +32,9 @@ __lrint (double x)
      Note: a nan is also indicated by cc=3).
      If the resulting value is within the target limits, redo
      without suppressing the inexact exception.  */
-  __asm__ (INSN " %0,0,%1,4 \n\t"
+  __asm__ ("cgdbra %0,0,%1,4 \n\t"
           "jo 1f \n\t"
-          INSN " %0,0,%1,0 \n\t"
+          "cgdbra %0,0,%1,0 \n\t"
           "1:"
           : "=&d" (y) : "f" (x) : "cc");
   return y;
index 9e489e9d63edca37ee2386c242fd0237958fbe29..382836c4fbe51586f4780fe65c9b1dcbdb7e2543 100644 (file)
 # include <math.h>
 # include <libm-alias-float.h>
 
-/* The sizeof (long int) differs between s390x (8byte) and s390 (4byte).
-   Thus we need different instructions as the target size is encoded there.
-   Note: On s390 this instruction is only used if build with -mzarch.  */
-# ifdef __s390x__
-#  define INSN "cgebra"
-# else
-#  define INSN "cfebra"
-# endif
-
 long int
 __lrintf (float x)
 {
@@ -41,9 +32,9 @@ __lrintf (float x)
      Note: a nan is also indicated by cc=3).
      If the resulting value is within the target limits, redo
      without suppressing the inexact exception.  */
-  __asm__ (INSN " %0,0,%1,4 \n\t"
+  __asm__ ("cgebra %0,0,%1,4 \n\t"
           "jo 1f \n\t"
-          INSN " %0,0,%1,0 \n\t"
+          "cgebra %0,0,%1,0 \n\t"
           "1:"
           : "=&d" (y) : "f" (x) : "cc");
   return y;
index 417e7bd4dc4d77a6c28637867da5728fd75aa501..bf200a53c946a684acca94fcab157bf57ef2f6e7 100644 (file)
 # include <math_private.h>
 # include <libm-alias-ldouble.h>
 
-/* The sizeof (long int) differs between s390x (8byte) and s390 (4byte).
-   Thus we need different instructions as the target size is encoded there.
-   Note: On s390 this instruction is only used if build with -mzarch.  */
-# ifdef __s390x__
-#  define INSN "cgxbra"
-# else
-#  define INSN "cfxbra"
-# endif
-
 long int
 __lrintl (_Float128 x)
 {
@@ -42,9 +33,9 @@ __lrintl (_Float128 x)
      Note: a nan is also indicated by cc=3).
      If the resulting value is within the target limits, redo
      without suppressing the inexact exception.  */
-  __asm__ (INSN " %0,0,%1,4 \n\t"
+  __asm__ ("cgxbra %0,0,%1,4 \n\t"
           "jo 1f \n\t"
-          INSN " %0,0,%1,0 \n\t"
+          "cgxbra %0,0,%1,0 \n\t"
           "1:"
           : "=&d" (y) : "f" (x) : "cc");
   return y;
index db079c4aebd512317b4d7c71ed37f062c9fd1313..09d203e0c3b53c5e06ed699a1b88845196dc529c 100644 (file)
 # include <math.h>
 # include <libm-alias-double.h>
 
-/* The sizeof (long int) differs between s390x (8byte) and s390 (4byte).
-   Thus we need different instructions as the target size is encoded there.
-   Note: On s390 this instruction is only used if build with -mzarch.  */
-# ifdef __s390x__
-#  define INSN "cgdbra"
-# else
-#  define INSN "cfdbra"
-# endif
-
 long int
 __lround (double x)
 {
@@ -37,7 +28,7 @@ __lround (double x)
   /* The z196 zarch "convert to fixed" (cgdbra) instruction is rounding
      x to the nearest integer with "ties away from 0" rounding mode
      (M3-field: 1) where inexact exceptions are suppressed (M4-field: 4).  */
-  __asm__ (INSN " %0,1,%1,4" : "=d" (y) : "f" (x) : "cc");
+  __asm__ ("cgdbra %0,1,%1,4" : "=d" (y) : "f" (x) : "cc");
   return y;
 }
 libm_alias_double (__lround, lround)
index 4be5a1e1a7d7c56a933abc088ad42433d3a88483..80061d1ac89c7e786465ad8cb5e0cdba11e314cd 100644 (file)
 # include <math.h>
 # include <libm-alias-float.h>
 
-/* The sizeof (long int) differs between s390x (8byte) and s390 (4byte).
-   Thus we need different instructions as the target size is encoded there.
-   Note: On s390 this instruction is only used if build with -mzarch.  */
-# ifdef __s390x__
-#  define INSN "cgebra"
-# else
-#  define INSN "cfebra"
-# endif
-
 long int
 __lroundf (float x)
 {
@@ -37,7 +28,7 @@ __lroundf (float x)
   /* The z196 zarch "convert to fixed" (cgebra) instruction is rounding
      x to the nearest integer with "ties away from 0" rounding mode
      (M3-field: 1) where inexact exceptions are suppressed (M4-field: 4).  */
-  __asm__ (INSN " %0,1,%1,4" : "=d" (y) : "f" (x) : "cc");
+  __asm__ ("cgebra %0,1,%1,4" : "=d" (y) : "f" (x) : "cc");
   return y;
 }
 libm_alias_float (__lround, lround)
index 046a71f60a712f1b7a5d1395eff613fbd26569e8..0f8f486ed995b270343acc86f5baadceaf019d8f 100644 (file)
 # include <math_private.h>
 # include <libm-alias-ldouble.h>
 
-/* The sizeof (long int) differs between s390x (8byte) and s390 (4byte).
-   Thus we need different instructions as the target size is encoded there.
-   Note: On s390 this instruction is only used if build with -mzarch.  */
-# ifdef __s390x__
-#  define INSN "cgxbra"
-# else
-#  define INSN "cfxbra"
-# endif
-
 long int
 __lroundl (_Float128 x)
 {
@@ -38,7 +29,7 @@ __lroundl (_Float128 x)
   /* The z196 zarch "convert to fixed" (cgxbra) instruction is rounding
      x to the nearest integer with "ties away from 0" rounding mode
      (M3-field: 1) where inexact exceptions are suppressed (M4-field: 4).  */
-  __asm__ (INSN " %0,1,%1,4" : "=d" (y) : "f" (x) : "cc");
+  __asm__ ("cgxbra %0,1,%1,4" : "=d" (y) : "f" (x) : "cc");
   return y;
 }
 libm_alias_ldouble (__lround, lround)
index a0ed7c544445728c03bebc4104922867c2dbea2c..5dcf2850a6e8e8fd7373421dc801efc14cd96c0a 100644 (file)
 
 #if defined HAVE_S390_MIN_Z13_ZARCH_ASM_SUPPORT
 # define MEMCHR_DEFAULT                MEMCHR_Z13
-# define HAVE_MEMCHR_Z900_G5   0
+# define HAVE_MEMCHR_Z900      0
 # define HAVE_MEMCHR_Z13       1
 #else
-# define MEMCHR_DEFAULT                MEMCHR_Z900_G5
-# define HAVE_MEMCHR_Z900_G5   1
+# define MEMCHR_DEFAULT                MEMCHR_Z900
+# define HAVE_MEMCHR_Z900      1
 # define HAVE_MEMCHR_Z13       HAVE_MEMCHR_IFUNC_AND_VX_SUPPORT
 #endif
 
-#if HAVE_MEMCHR_Z900_G5
-# define MEMCHR_Z900_G5                __memchr_default
+#if HAVE_MEMCHR_Z900
+# define MEMCHR_Z900           __memchr_default
 #else
-# define MEMCHR_Z900_G5                NULL
+# define MEMCHR_Z900           NULL
 #endif
 
 #if HAVE_MEMCHR_Z13
index 8a21278a0f4f656849a93bf8e900b435169bfcc1..cb427978cddfe25a5ba44d9c7900890d43ab7d39 100644 (file)
 
 #if defined HAVE_S390_MIN_Z196_ZARCH_ASM_SUPPORT
 # define MEMCMP_DEFAULT                MEMCMP_Z196
-# define HAVE_MEMCMP_Z900_G5   0
+# define HAVE_MEMCMP_Z900      0
 # define HAVE_MEMCMP_Z10       0
 # define HAVE_MEMCMP_Z196      1
 #elif defined HAVE_S390_MIN_Z10_ZARCH_ASM_SUPPORT
 # define MEMCMP_DEFAULT                MEMCMP_Z10
-# define HAVE_MEMCMP_Z900_G5   0
+# define HAVE_MEMCMP_Z900      0
 # define HAVE_MEMCMP_Z10       1
 # define HAVE_MEMCMP_Z196      HAVE_MEMCMP_IFUNC
 #else
-# define MEMCMP_DEFAULT                MEMCMP_Z900_G5
-# define HAVE_MEMCMP_Z900_G5   1
+# define MEMCMP_DEFAULT                MEMCMP_Z900
+# define HAVE_MEMCMP_Z900      1
 # define HAVE_MEMCMP_Z10       HAVE_MEMCMP_IFUNC
 # define HAVE_MEMCMP_Z196      HAVE_MEMCMP_IFUNC
 #endif
 
-#if HAVE_MEMCMP_Z900_G5
-# define MEMCMP_Z900_G5                __memcmp_default
+#if HAVE_MEMCMP_Z900
+# define MEMCMP_Z900           __memcmp_default
 #else
-# define MEMCMP_Z900_G5                NULL
+# define MEMCMP_Z900           NULL
 #endif
 
 #if HAVE_MEMCMP_Z10
index 91efab342856ed91619bbde26c06233fa8a7535f..48afc2c23a26fc87e62be95e2b47acf175e0c8e7 100644 (file)
 #if defined HAVE_S390_MIN_Z196_ZARCH_ASM_SUPPORT
 # define MEMCPY_DEFAULT                MEMCPY_Z196
 # define MEMPCPY_DEFAULT       MEMPCPY_Z196
-# define HAVE_MEMCPY_Z900_G5   0
+# define HAVE_MEMCPY_Z900      0
 # define HAVE_MEMCPY_Z10       0
 # define HAVE_MEMCPY_Z196      1
 #elif defined HAVE_S390_MIN_Z10_ZARCH_ASM_SUPPORT
 # define MEMCPY_DEFAULT                MEMCPY_Z10
 # define MEMPCPY_DEFAULT       MEMPCPY_Z10
-# define HAVE_MEMCPY_Z900_G5   0
+# define HAVE_MEMCPY_Z900      0
 # define HAVE_MEMCPY_Z10       1
 # define HAVE_MEMCPY_Z196      HAVE_MEMCPY_IFUNC
 #else
-# define MEMCPY_DEFAULT                MEMCPY_Z900_G5
-# define MEMPCPY_DEFAULT       MEMPCPY_Z900_G5
-# define HAVE_MEMCPY_Z900_G5   1
+# define MEMCPY_DEFAULT                MEMCPY_Z900
+# define MEMPCPY_DEFAULT       MEMPCPY_Z900
+# define HAVE_MEMCPY_Z900      1
 # define HAVE_MEMCPY_Z10       HAVE_MEMCPY_IFUNC
 # define HAVE_MEMCPY_Z196      HAVE_MEMCPY_IFUNC
 #endif
 # define HAVE_MEMMOVE_ARCH13   HAVE_MEMMOVE_IFUNC_AND_ARCH13_SUPPORT
 #endif
 
-#if HAVE_MEMCPY_Z900_G5
-# define MEMCPY_Z900_G5                __memcpy_default
-# define MEMPCPY_Z900_G5       __mempcpy_default
+#if HAVE_MEMCPY_Z900
+# define MEMCPY_Z900           __memcpy_default
+# define MEMPCPY_Z900          __mempcpy_default
 #else
-# define MEMCPY_Z900_G5                NULL
-# define MEMPCPY_Z900_G5       NULL
+# define MEMCPY_Z900           NULL
+# define MEMPCPY_Z900          NULL
 #endif
 
 #if HAVE_MEMCPY_Z10
index b0041d1a58f270cf7bc594783621fdc89e13e890..569591c9cc11d491bba580916ef61f7169568216 100644 (file)
 
 #if defined HAVE_S390_MIN_Z196_ZARCH_ASM_SUPPORT
 # define MEMSET_DEFAULT                MEMSET_Z196
-# define HAVE_MEMSET_Z900_G5   0
+# define HAVE_MEMSET_Z900      0
 # define HAVE_MEMSET_Z10       0
 # define HAVE_MEMSET_Z196      1
 #elif defined HAVE_S390_MIN_Z10_ZARCH_ASM_SUPPORT
 # define MEMSET_DEFAULT                MEMSET_Z10
-# define HAVE_MEMSET_Z900_G5   0
+# define HAVE_MEMSET_Z900      0
 # define HAVE_MEMSET_Z10       1
 # define HAVE_MEMSET_Z196      HAVE_MEMSET_IFUNC
 #else
-# define MEMSET_DEFAULT                MEMSET_Z900_G5
-# define HAVE_MEMSET_Z900_G5   1
+# define MEMSET_DEFAULT                MEMSET_Z900
+# define HAVE_MEMSET_Z900      1
 # define HAVE_MEMSET_Z10       HAVE_MEMSET_IFUNC
 # define HAVE_MEMSET_Z196      HAVE_MEMSET_IFUNC
 #endif
 # define HAVE_MEMSET_MVCLE     0
 #endif
 
-#if HAVE_MEMSET_Z900_G5
-# define MEMSET_Z900_G5                __memset_default
+#if HAVE_MEMSET_Z900
+# define MEMSET_Z900           __memset_default
 #else
-# define MEMSET_Z900_G5                NULL
+# define MEMSET_Z900           NULL
 #endif
 
 #if HAVE_MEMSET_Z10
index 7d32d72b600b63c974c298ead57e0c32d804d9a2..069827c46064767df6d6610c06f45dfeb7d1f77a 100644 (file)
 
 #if defined HAVE_S390_MIN_Z13_ZARCH_ASM_SUPPORT
 # define STRCMP_DEFAULT                STRCMP_Z13
-# define HAVE_STRCMP_Z900_G5   0
+# define HAVE_STRCMP_Z900      0
 # define HAVE_STRCMP_Z13       1
 #else
-# define STRCMP_DEFAULT                STRCMP_Z900_G5
-# define HAVE_STRCMP_Z900_G5   1
+# define STRCMP_DEFAULT                STRCMP_Z900
+# define HAVE_STRCMP_Z900      1
 # define HAVE_STRCMP_Z13       HAVE_STRCMP_IFUNC_AND_VX_SUPPORT
 #endif
 
-#if HAVE_STRCMP_Z900_G5
-# define STRCMP_Z900_G5                __strcmp_default
+#if HAVE_STRCMP_Z900
+# define STRCMP_Z900           __strcmp_default
 #else
-# define STRCMP_Z900_G5                NULL
+# define STRCMP_Z900           NULL
 #endif
 
 #if HAVE_STRCMP_Z13
index 919bd7492307c56dc01f7217a55588f1304e0105..9cd26f2f76f745c8b472ac541b3411dacb8adf0c 100644 (file)
 
 #if defined HAVE_S390_MIN_Z13_ZARCH_ASM_SUPPORT
 # define STRCPY_DEFAULT                STRCPY_Z13
-# define HAVE_STRCPY_Z900_G5   0
+# define HAVE_STRCPY_Z900      0
 # define HAVE_STRCPY_Z13       1
 #else
-# define STRCPY_DEFAULT                STRCPY_Z900_G5
-# define HAVE_STRCPY_Z900_G5   1
+# define STRCPY_DEFAULT                STRCPY_Z900
+# define HAVE_STRCPY_Z900      1
 # define HAVE_STRCPY_Z13       HAVE_STRCPY_IFUNC_AND_VX_SUPPORT
 #endif
 
-#if HAVE_STRCPY_Z900_G5
-# define STRCPY_Z900_G5                __strcpy_default
+#if HAVE_STRCPY_Z900
+# define STRCPY_Z900           __strcpy_default
 #else
-# define STRCPY_Z900_G5                NULL
+# define STRCPY_Z900           NULL
 #endif
 
 #if HAVE_STRCPY_Z13
index de426e611ecac677e3e3de09ada2b209f663bc3b..625b52a3abae0c9d50708a3970bb920568df46a6 100644 (file)
 
 #if defined HAVE_S390_MIN_Z13_ZARCH_ASM_SUPPORT
 # define STRNCPY_DEFAULT       STRNCPY_Z13
-# define HAVE_STRNCPY_Z900_G5  0
+# define HAVE_STRNCPY_Z900     0
 # define HAVE_STRNCPY_Z13      1
 #else
-# define STRNCPY_DEFAULT       STRNCPY_Z900_G5
-# define HAVE_STRNCPY_Z900_G5  1
+# define STRNCPY_DEFAULT       STRNCPY_Z900
+# define HAVE_STRNCPY_Z900     1
 # define HAVE_STRNCPY_Z13      HAVE_STRNCPY_IFUNC_AND_VX_SUPPORT
 #endif
 
-#if HAVE_STRNCPY_Z900_G5
-# define STRNCPY_Z900_G5       __strncpy_default
+#if HAVE_STRNCPY_Z900
+# define STRNCPY_Z900          __strncpy_default
 #else
-# define STRNCPY_Z900_G5       NULL
+# define STRNCPY_Z900          NULL
 #endif
 
 #if HAVE_STRNCPY_Z13
index 3e7f131f15f798487cb49ffdbf685cbe382ee839..b38e9e6b407469773df1e722cbad248bd906f245 100644 (file)
@@ -169,12 +169,6 @@ __attribute__ ((aligned (8))) =
 #define MIN_NEEDED_FROM                1
 #define MIN_NEEDED_TO          1
 
-# if defined __s390x__
-#  define BRANCH_ON_COUNT(REG,LBL) "brctg %" #REG "," #LBL "\n\t"
-# else
-#  define BRANCH_ON_COUNT(REG,LBL) "brct %" #REG "," #LBL "\n\t"
-# endif
-
 #define TR_LOOP(TABLE)                                                 \
   {                                                                    \
     size_t length = (inend - inptr < outend - outptr                   \
@@ -188,7 +182,7 @@ __attribute__ ((aligned (8))) =
                             "   tr 0(256,%[R_OUT]),0(%[R_TBL])\n\t"    \
                             "   la %[R_IN],256(%[R_IN])\n\t"           \
                             "   la %[R_OUT],256(%[R_OUT])\n\t"         \
-                            BRANCH_ON_COUNT ([R_LI], 0b)               \
+                            "   brctg %[R_LI],0b\n\t"                  \
                             : /* outputs */ [R_IN] "+a" (inptr)        \
                               , [R_OUT] "+a" (outptr), [R_LI] "+d" (blocks) \
                             : /* inputs */ [R_TBL] "a" (TABLE)         \
index 97dbb40078285723173ba5f5ab587b92e0391dfb..3812c126a5e414c721e1eaf6c91b76028f7d0813 100644 (file)
@@ -30,8 +30,7 @@
   ((void *) (address) < (void *) demangle ((jmpbuf)->__gregs[__JB_GPR15]))
 
 
-/* On s390{,x}, CFA is always 96 (resp. 160) bytes above actual
-   %r15.  */
+/* On s390x, CFA is always 160 bytes above actual %r15.  */
 #define _JMPBUF_CFA_UNWINDS_ADJ(_jmpbuf, _context, _adj) \
   _JMPBUF_UNWINDS_ADJ (_jmpbuf,                                        \
                       (void *) (_Unwind_GetCFA (_context)      \
index 0313b50774566b76149ef8f93a82a0ce2c90332f..6c4a999e33d91163a4d20559a7d252401d3044ed 100644 (file)
 #include <elf.h>
 #include <cpu-features.h>
 
-struct La_s390_32_regs;
-struct La_s390_32_retval;
 struct La_s390_64_regs;
 struct La_s390_64_retval;
 
 #define ARCH_PLTENTER_MEMBERS                                          \
-    Elf32_Addr (*s390_32_gnu_pltenter) (Elf32_Sym *, unsigned int,     \
-                                       uintptr_t *,                    \
-                                       uintptr_t *,                    \
-                                       struct La_s390_32_regs *,       \
-                                       unsigned int *, const char *name, \
-                                       long int *framesizep);          \
     Elf64_Addr (*s390_64_gnu_pltenter) (Elf64_Sym *, unsigned int,     \
                                        uintptr_t *,                    \
                                        uintptr_t *,                    \
@@ -42,11 +34,6 @@ struct La_s390_64_retval;
                                        long int *framesizep)
 
 #define ARCH_PLTEXIT_MEMBERS                                           \
-    unsigned int (*s390_32_gnu_pltexit) (Elf32_Sym *, unsigned int,    \
-                                        uintptr_t *, uintptr_t *,      \
-                                        const struct La_s390_32_regs *, \
-                                        struct La_s390_32_retval *,    \
-                                        const char *);                 \
     unsigned int (*s390_64_gnu_pltexit) (Elf64_Sym *, unsigned int,    \
                                         uintptr_t *, uintptr_t *,      \
                                         const struct La_s390_64_regs *, \
index 283615b99ae3d405ad1d58a2a8437669a0f9bb07..faf0b96d3e35629c3b86bf61612e15312e18fd26 100644 (file)
@@ -1,13 +1,5 @@
-#if __WORDSIZE == 64
 struct link_map_machine
-  {
-    Elf64_Addr plt; /* Address of .plt + 0x2e */
-    const Elf64_Rela *jmprel; /* Address of first JMP_SLOT reloc */
-  };
-#else
-struct link_map_machine
-  {
-    Elf32_Addr plt; /* Address of .plt + 0x2c */
-    const Elf32_Rela *jmprel; /* Address of first JMP_SLOT reloc */
-  };
-#endif
+{
+  Elf64_Addr plt; /* Address of .plt + 0x2e */
+  const Elf64_Rela *jmprel; /* Address of first JMP_SLOT reloc */
+};
index 8008e374cee041cfd2cfdf2d536f59a3c8a4d08b..648039d867cbec7f8a8b2e9159dbaf3b5a62ac7c 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of memccpy.
+/* Vector optimized 64 bit S/390 version of memccpy.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 */
 ENTRY(MEMCCPY_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-
-# if !defined __s390x__
-       llgfr   %r5,%r5
-# endif /* !defined __s390x__ */
 
        vlvgp   %v31,%r6,%r7    /* Save registers.  */
        clgije  %r5,0,.Lnf_end  /* If len == 0 then exit.  */
index e6c3ac4181ddfdcef95c3d22ee786116e778765d..86cd0291f79b5ccdf6c4461a37128a199043597c 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of memchr.
+/* Vector optimized 64 bit S/390 version of memchr.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    -v18=c replicated
 */
 ENTRY(MEMCHR_Z13)
-
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__ */
 
        clgije  %r4,0,.Lnf_end  /* If len == 0 then exit.  */
 
@@ -157,7 +151,7 @@ strong_alias (MEMCHR_Z13, __memchr)
 weak_alias (__memchr, memchr)
 # endif
 
-# if ! HAVE_MEMCHR_Z900_G5 && defined SHARED && IS_IN (libc)
+# if ! HAVE_MEMCHR_Z900 && defined SHARED && IS_IN (libc)
 strong_alias (MEMCHR_Z13, __GI_memchr)
 # endif
 #endif
index 16b9c19429fd9b51543ea39947e5ad0b9b25bfdf..c0ffd864f7c79d4c3cd2cd3668b4a0b08ef416f0 100644 (file)
@@ -1,4 +1,4 @@
-/* Search a character in a block of memory.  31/64 bit S/390 version.
+/* Search a character in a block of memory.  64 bit S/390 version.
    Copyright (C) 2001-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 #include "sysdep.h"
 #include "asm-syntax.h"
 
-#if HAVE_MEMCHR_Z900_G5
-# if defined __s390x__
-#  define SLGR slgr
-#  define LGHI lghi
-#  define NGR  ngr
-#  define LGR  lgr
-# else
-#  define SLGR slr
-#  define LGHI lhi
-#  define NGR  nr
-#  define LGR  lr
-# endif /* ! defined __s390x__  */
-
+#if HAVE_MEMCHR_Z900
        .text
-ENTRY(MEMCHR_Z900_G5)
-       LGHI  %r0,0xff
-       NGR   %r0,%r3
-       LGR   %r1,%r2
-# if ! defined __s390x__
-       tmlh  %r4,32768
-       jo    3f                /* Jump away if n >= 0x80000000  */
-# endif
+ENTRY(MEMCHR_Z900)
+       lghi  %r0,0xff
+       ngr   %r0,%r3
+       lgr   %r1,%r2
        la    %r2,0(%r4,%r1)
 0:     srst  %r2,%r1
        jo    0b
        brc   13,1f
-       SLGR  %r2,%r2
+       slgr  %r2,%r2
 1:     br    %r14
-# if ! defined __s390x__
-       /* On s390 (31bit), the pointer to the first byte after s (stored in
-          r2) always wraps around with n >= 0x80000000 and can lead to stop
-          searching before end of s.  Thus just use r2=0 in this case.
-          If r2 < r1, the srst instruction stops searching with cc=2 "not
-          found" when wrapping around from top address to zero.  */
-3:     SLGR  %r2,%r2
-       j     0b
-# endif
-END(MEMCHR_Z900_G5)
+END(MEMCHR_Z900)
 
 # if ! HAVE_MEMCHR_IFUNC
-strong_alias (MEMCHR_Z900_G5, __memchr)
+strong_alias (MEMCHR_Z900, __memchr)
 weak_alias (__memchr, memchr)
 # endif
 
 # if defined SHARED && IS_IN (libc)
-strong_alias (MEMCHR_Z900_G5, __GI_memchr)
+strong_alias (MEMCHR_Z900, __GI_memchr)
 # endif
 #endif
index 764a10a83953589ff3a4846d826948027406cca8..8ddfaa03d4ab8ed412f5d57aec199b98082013f8 100644 (file)
@@ -24,8 +24,8 @@
 # undef memchr
 # include <ifunc-resolve.h>
 
-# if HAVE_MEMCHR_Z900_G5
-extern __typeof (__redirect_memchr) MEMCHR_Z900_G5 attribute_hidden;
+# if HAVE_MEMCHR_Z900
+extern __typeof (__redirect_memchr) MEMCHR_Z900 attribute_hidden;
 # endif
 
 # if HAVE_MEMCHR_Z13
index 00ec2bba526bf169a5bffa15011a1258407d6d06..abdbcaa35e92b0f384c577129832be43679532f5 100644 (file)
@@ -1,4 +1,4 @@
-/* memcmp - compare two memory blocks.  31/64 bit S/390 version.
+/* memcmp - compare two memory blocks.  64 bit S/390 version.
    Copyright (C) 2012-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 
        .text
 
-#if HAVE_MEMCMP_Z900_G5
-# if defined __s390x__
-#  define LTGR ltgr
-#  define AGHI aghi
-#  define BRCTG        brctg
-# else
-#  define LTGR ltr
-#  define AGHI ahi
-#  define BRCTG        brct
-# endif /* ! defined __s390x__  */
-ENTRY(MEMCMP_Z900_G5)
-# if defined __s390x__
+#if HAVE_MEMCMP_Z900
+ENTRY(MEMCMP_Z900)
        .machine "z900"
-# else
-       .machine "g5"
-       basr    %r5,0
-.L_Z900_G5_16:
-#  define Z900_G5_EX_D .L_Z900_G5_15-.L_Z900_G5_16
-# endif /* ! defined __s390x__  */
-       LTGR    %r4,%r4
-       je      .L_Z900_G5_4
-       AGHI    %r4,-1
-# if defined __s390x__
+       ltgr    %r4,%r4
+       je      .L_Z900_4
+       aghi    %r4,-1
        srlg    %r1,%r4,8
-       larl    %r5,.L_Z900_G5_15
-#  define Z900_G5_EX_D 0
-# else
-       lr      %r1,%r4
-       srl     %r1,8
-# endif /* ! defined __s390x__  */
-       LTGR    %r1,%r1
-       jne     .L_Z900_G5_12
-.L_Z900_G5_3:
-       ex      %r4,Z900_G5_EX_D(%r5)
-.L_Z900_G5_4:
+       larl    %r5,.L_Z900_15
+       ltgr    %r1,%r1
+       jne     .L_Z900_12
+.L_Z900_3:
+       ex      %r4,0(%r5)
+.L_Z900_4:
        ipm     %r2
-# if defined __s390x__
        sllg    %r2,%r2,34
        srag    %r2,%r2,62
-# else
-       sll     %r2,2
-       sra     %r2,30
-# endif /* ! defined __s390x__  */
        br      %r14
-.L_Z900_G5_12:
+.L_Z900_12:
        clc     0(256,%r3),0(%r2)
-       jne     .L_Z900_G5_4
+       jne     .L_Z900_4
        la      %r3,256(%r3)
        la      %r2,256(%r2)
-       BRCTG   %r1,.L_Z900_G5_12
-       j       .L_Z900_G5_3
-.L_Z900_G5_15:
+       brctg   %r1,.L_Z900_12
+       j       .L_Z900_3
+.L_Z900_15:
        clc     0(1,%r3),0(%r2)
-END(MEMCMP_Z900_G5)
-# undef LTGR
-# undef AGHI
-# undef BRCTG
-#endif /* HAVE_MEMCMP_Z900_G5  */
+END(MEMCMP_Z900)
+#endif /* HAVE_MEMCMP_Z900  */
 
 #if HAVE_MEMCMP_Z10
 ENTRY(MEMCMP_Z10)
        .machine "z10"
-       .machinemode "zarch_nohighgprs"
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__  */
        ltgr    %r4,%r4
        je      .L_Z10_4
        aghi    %r4,-1
@@ -123,10 +89,6 @@ END(MEMCMP_Z10)
 #if HAVE_MEMCMP_Z196
 ENTRY(MEMCMP_Z196)
        .machine "z196"
-       .machinemode "zarch_nohighgprs"
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__  */
        ltgr    %r4,%r4
        je      .L_Z196_4
        aghi    %r4,-1
index b6f6faa2247a354c2311271480fbfc8cac483a33..5ff55c8091377c3c94a1bc3ed0906796957ce1cd 100644 (file)
@@ -23,8 +23,8 @@
 # undef memcmp
 # include <ifunc-resolve.h>
 
-# if HAVE_MEMCMP_Z900_G5
-extern __typeof (__redirect_memcmp) MEMCMP_Z900_G5 attribute_hidden;
+# if HAVE_MEMCMP_Z900
+extern __typeof (__redirect_memcmp) MEMCMP_Z900 attribute_hidden;
 # endif
 
 # if HAVE_MEMCMP_Z10
index 6ec81298d870a208bd2b3d00aeac1775bc8f8eb3..1eb8dc405781a94e3a022d29a12b80273580e8c3 100644 (file)
@@ -18,6 +18,6 @@
 
 #include <sysdeps/generic/memcopy.h>
 
-/* The s390/s390x memcpy implementations are safe to be used by memmove.  */
+/* The s390x memcpy implementations are safe to be used by memmove.  */
 #undef MEMCPY_OK_FOR_FWD_MEMMOVE
 #define MEMCPY_OK_FOR_FWD_MEMMOVE 1
index 037d24581638a31f726a24defdafb796f8469ba7..3966585e83d75231e3ac702a16a2538ec9280819 100644 (file)
@@ -1,4 +1,4 @@
-/* memcpy - copy a block from source to destination.  31/64 bit S/390 version.
+/* memcpy - copy a block from source to destination.  64 bit S/390 version.
    Copyright (C) 2012-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 
        .text
 
-#if defined __s390x__
-# define LTGR  ltgr
-# define CGHI  cghi
-# define LGR   lgr
-# define AGHI  aghi
-# define BRCTG brctg
-#else
-# define LTGR  ltr
-# define CGHI  chi
-# define LGR   lr
-# define AGHI  ahi
-# define BRCTG brct
-#endif /* ! defined __s390x__  */
-
-#if HAVE_MEMCPY_Z900_G5
-ENTRY(MEMPCPY_Z900_G5)
-# if defined __s390x__
+#if HAVE_MEMCPY_Z900
+ENTRY(MEMPCPY_Z900)
        .machine "z900"
-# else
-       .machine "g5"
-# endif /* ! defined __s390x__  */
-       LGR     %r1,%r2             # Use as dest
+       lgr     %r1,%r2             # Use as dest
        la      %r2,0(%r4,%r2)      # Return dest + n
-       j       .L_Z900_G5_start
-END(MEMPCPY_Z900_G5)
+       j       .L_Z900_start
+END(MEMPCPY_Z900)
 
-ENTRY(MEMCPY_Z900_G5)
-# if defined __s390x__
+ENTRY(MEMCPY_Z900)
        .machine "z900"
-# else
-       .machine "g5"
-# endif /* ! defined __s390x__  */
-       LGR     %r1,%r2             # r1: Use as dest ; r2: Return dest
-.L_Z900_G5_start:
-       LTGR    %r4,%r4
-       je      .L_Z900_G5_4
-       AGHI    %r4,-1
-# if defined __s390x__
+       lgr     %r1,%r2             # r1: Use as dest ; r2: Return dest
+.L_Z900_start:
+       ltgr    %r4,%r4
+       je      .L_Z900_4
+       aghi    %r4,-1
        srlg    %r5,%r4,8
-# else
-       lr      %r5,%r4
-       srl     %r5,8
-# endif /* ! defined __s390x__  */
-       LTGR    %r5,%r5
-       jne     .L_Z900_G5_13
-.L_Z900_G5_3:
-# if defined __s390x__
-       larl    %r5,.L_Z900_G5_15
-#  define Z900_G5_EX_D 0
-# else
-       basr    %r5,0
-.L_Z900_G5_14:
-#  define Z900_G5_EX_D .L_Z900_G5_15-.L_Z900_G5_14
-# endif /* ! defined __s390x__  */
-       ex      %r4,Z900_G5_EX_D(%r5)
-.L_Z900_G5_4:
+       ltgr    %r5,%r5
+       jne     .L_Z900_13
+.L_Z900_3:
+       larl    %r5,.L_Z900_15
+       ex      %r4,0(%r5)
+.L_Z900_4:
        br      %r14
-.L_Z900_G5_13:
-       CGHI    %r5,4096            # Switch to mvcle for copies >1MB
+.L_Z900_13:
+       cghi    %r5,4096            # Switch to mvcle for copies >1MB
        jh      __memcpy_mvcle
-.L_Z900_G5_12:
+.L_Z900_12:
        mvc     0(256,%r1),0(%r3)
        la      %r1,256(%r1)
        la      %r3,256(%r3)
-       BRCTG   %r5,.L_Z900_G5_12
-       j       .L_Z900_G5_3
-.L_Z900_G5_15:
+       brctg   %r5,.L_Z900_12
+       j       .L_Z900_3
+.L_Z900_15:
        mvc     0(1,%r1),0(%r3)
-END(MEMCPY_Z900_G5)
-#endif /* HAVE_MEMCPY_Z900_G5  */
+END(MEMCPY_Z900)
+#endif /* HAVE_MEMCPY_Z900  */
 
 ENTRY(__memcpy_mvcle)
        # Using as standalone function will result in unexpected
        # results since the length field is incremented by 1 in order to
        # compensate the changes already done in the functions above.
-       LGR     %r0,%r2             # backup return dest [ + n ]
-       AGHI    %r4,1               # length + 1
+       lgr     %r0,%r2             # backup return dest [ + n ]
+       aghi    %r4,1               # length + 1
        LGR     %r5,%r4             # source length
        LGR     %r4,%r3             # source address
        LGR     %r2,%r1             # destination address
@@ -112,20 +78,13 @@ ENTRY(__memcpy_mvcle)
 .L_MVCLE_1:
        mvcle   %r2,%r4,0           # that's it, MVCLE is your friend
        jo      .L_MVCLE_1
-       LGR     %r2,%r0             # return destination address
+       lgr     %r2,%r0             # return destination address
        br      %r14
 END(__memcpy_mvcle)
 
-#undef LTGR
-#undef CGHI
-#undef LGR
-#undef AGHI
-#undef BRCTG
-
 #if HAVE_MEMCPY_Z10
 ENTRY(MEMPCPY_Z10)
        .machine "z10"
-       .machinemode "zarch_nohighgprs"
        lgr     %r1,%r2         # Use as dest
        la      %r2,0(%r4,%r2)  # Return dest + n
        j       .L_Z10_start
@@ -133,12 +92,8 @@ END(MEMPCPY_Z10)
 
 ENTRY(MEMCPY_Z10)
        .machine "z10"
-       .machinemode "zarch_nohighgprs"
        lgr     %r1,%r2         # r1: Use as dest ; r2: Return dest
 .L_Z10_start:
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__  */
        cgije   %r4,0,.L_Z10_4
        aghi    %r4,-1
        srlg    %r5,%r4,8
@@ -166,7 +121,6 @@ END(MEMCPY_Z10)
 #if HAVE_MEMCPY_Z196
 ENTRY(MEMPCPY_Z196)
        .machine "z196"
-       .machinemode "zarch_nohighgprs"
        lgr     %r1,%r2         # Use as dest
        la      %r2,0(%r4,%r2)  # Return dest + n
        j       .L_Z196_start
@@ -174,12 +128,8 @@ END(MEMPCPY_Z196)
 
 ENTRY(MEMCPY_Z196)
        .machine "z196"
-       .machinemode "zarch_nohighgprs"
        lgr     %r1,%r2         # r1: Use as dest ; r2: Return dest
 .L_Z196_start:
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__  */
        ltgr    %r4,%r4
        je      .L_Z196_4
 .L_Z196_start2:
@@ -220,13 +170,6 @@ END(MEMCPY_Z196)
 #if HAVE_MEMMOVE_Z13
 ENTRY(MEMMOVE_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-# if !defined __s390x__
-       /* Note: The 31bit dst and src pointers are prefixed with zeroes.  */
-       llgfr   %r4,%r4
-       llgfr   %r3,%r3
-       llgfr   %r2,%r2
-# endif /* !defined __s390x__ */
        sgrk    %r0,%r2,%r3
        clgijh  %r4,16,.L_MEMMOVE_Z13_LARGE
        aghik   %r5,%r4,-1
@@ -289,13 +232,6 @@ END(MEMMOVE_Z13)
 #if HAVE_MEMMOVE_ARCH13
 ENTRY(MEMMOVE_ARCH13)
        .machine "arch13"
-       .machinemode "zarch_nohighgprs"
-# if ! defined __s390x__
-       /* Note: The 31bit dst and src pointers are prefixed with zeroes.  */
-       llgfr   %r4,%r4
-       llgfr   %r3,%r3
-       llgfr   %r2,%r2
-# endif /* ! defined __s390x__ */
        sgrk    %r5,%r2,%r3
        aghik   %r0,%r4,-1      /* Both vstl and mvcrl needs highest index.  */
        clgijh  %r4,16,.L_MEMMOVE_ARCH13_LARGE
index 243f3a30460914d2963953196af4fe8794495e9a..cfad6cdcb46f5294203c426d67a048d492826f0a 100644 (file)
@@ -24,8 +24,8 @@
 # undef memcpy
 # include <ifunc-resolve.h>
 
-# if HAVE_MEMCPY_Z900_G5
-extern __typeof (__redirect_memcpy) MEMCPY_Z900_G5 attribute_hidden;
+# if HAVE_MEMCPY_Z900
+extern __typeof (__redirect_memcpy) MEMCPY_Z900 attribute_hidden;
 # endif
 
 # if HAVE_MEMCPY_Z10
index 227c6fecfb0530309b8fef6d95a5257aec5678af..e8644713914454b3ac875834c3e48f89d14eac74 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of memmem.
+/* Vector optimized 64 bit S/390 version of memmem.
    Copyright (C) 2019-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    Locate a substring.  */
 ENTRY(MEMMEM_ARCH13)
        .machine "arch13"
-       .machinemode "zarch_nohighgprs"
-# if ! defined __s390x__
-       llgfr   %r3,%r3
-       llgfr   %r5,%r5
-       llgfr   %r4,%r4
-       llgfr   %r2,%r2
-# endif /* ! defined __s390x__ */
        clgrjl  %r3,%r5,.Lend_no_match  /* Haystack < needle?  */
 
        /* Jump to fallback if needle > 9.  See also strstr-arch13.S.  */
index 43604948e77e4ee0f043400d5bcb4cce9ce8f6ef..49f01b0575e4f5b3d6f03eaadb70315344d083c0 100644 (file)
@@ -28,8 +28,8 @@
 # undef __mempcpy
 # include <ifunc-resolve.h>
 
-# if HAVE_MEMCPY_Z900_G5
-extern __typeof (__redirect___mempcpy) MEMPCPY_Z900_G5 attribute_hidden;
+# if HAVE_MEMCPY_Z900
+extern __typeof (__redirect___mempcpy) MEMPCPY_Z900 attribute_hidden;
 # endif
 
 # if HAVE_MEMCPY_Z10
index 53ca78ae2457c9870fc13789cce5e5e7a81d5caa..7b65479777bcef17047cb58e755b3746a3ceed77 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of memrchr.
+/* Vector optimized 64 bit S/390 version of memrchr.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 */
 ENTRY(MEMRCHR_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__ */
        clgije  %r4,0,.Lnot_found
 
        vlvgb   %v18,%r3,0      /* Generate vector which elements are all c.
index 987589988bc3a253715d7f314946516f4b76a569..646ea9b33da67e4f29a9835d672dac9777e2b6b1 100644 (file)
@@ -1,4 +1,4 @@
-/* Set a block of memory to some byte value.  31/64 bit S/390 version.
+/* Set a block of memory to some byte value.  64 bit S/390 version.
    Copyright (C) 2001-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 
        .text
 
-#if HAVE_MEMSET_Z900_G5
-# if defined __s390x__
-#  define LTGR ltgr
-#  define CGHI cghi
-#  define LGR  lgr
-#  define AGHI aghi
-#  define BRCTG        brctg
-# else
-#  define LTGR ltr
-#  define CGHI chi
-#  define LGR  lr
-#  define AGHI ahi
-#  define BRCTG        brct
-# endif /* ! defined __s390x__  */
-
-ENTRY(MEMSET_Z900_G5)
-.L_Z900_G5_start:
-#if defined __s390x__
+#if HAVE_MEMSET_Z900
+ENTRY(MEMSET_Z900)
+.L_Z900_start:
        .machine "z900"
-#else
-       .machine "g5"
-#endif /* ! defined __s390x__  */
-       LTGR    %r4,%r4
-       je      .L_Z900_G5_4
+       ltgr    %r4,%r4
+       je      .L_Z900_4
        stc     %r3,0(%r2)
-       CGHI    %r4,1
-       LGR     %r1,%r2
-       je      .L_Z900_G5_4
-       AGHI    %r4,-2
-#if defined __s390x__
-       larl    %r5,.L_Z900_G5_18
+       cghi    %r4,1
+       lgr     %r1,%r2
+       je      .L_Z900_4
+       aghi    %r4,-2
+       larl    %r5,.L_Z900_18
        srlg    %r3,%r4,8
-# define Z900_G5_EX_D 0
-#else
-       basr    %r5,0
-.L_Z900_G5_19:
-# define Z900_G5_EX_D .L_Z900_G5_18-.L_Z900_G5_19
-       lr      %r3,%r4
-       srl     %r3,8
-#endif /* ! defined __s390x__  */
-       LTGR    %r3,%r3
-       jne     .L_Z900_G5_14
-.L_Z900_G5_3:
-       ex      %r4,Z900_G5_EX_D(%r5)
-.L_Z900_G5_4:
+       ltgr    %r3,%r3
+       jne     .L_Z900_14
+.L_Z900_3:
+       ex      %r4,0(%r5)
+.L_Z900_4:
        br      %r14
-.L_Z900_G5_14:
+.L_Z900_14:
        mvc     1(256,%r1),0(%r1)
        la      %r1,256(%r1)
-       BRCTG   %r3,.L_Z900_G5_14
-       j       .L_Z900_G5_3
-.L_Z900_G5_18:
+       brctg   %r3,.L_Z900_14
+       j       .L_Z900_3
+.L_Z900_18:
        mvc     1(1,%r1),0(%r1)
-END(MEMSET_Z900_G5)
-# undef LTGR
-# undef CGHI
-# undef LGR
-# undef AGHI
-# undef BRCTG
-#endif /*  HAVE_MEMSET_Z900_G5  */
+END(MEMSET_Z900)
+#endif /*  HAVE_MEMSET_Z900  */
 
 #if HAVE_MEMSET_Z10
 ENTRY(MEMSET_Z10)
 .L_Z10_start:
        .machine "z10"
-       .machinemode "zarch_nohighgprs"
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__  */
        cgije   %r4,0,.L_Z10_4
        stc     %r3,0(%r2)
        lgr     %r1,%r2
@@ -126,10 +90,6 @@ END(MEMSET_Z10)
 ENTRY(MEMSET_Z196)
 .L_Z196_start:
        .machine "z196"
-       .machinemode "zarch_nohighgprs"
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__  */
        clgfi   %r4,1
        jl      .L_Z196_4           # n == 0
        stc     %r3,0(%r2)
index 1eb6dcb007dae752425ad3b7f0265e6eeaff0407..25ed9af66080387a8789a76a8f886cbbfada3e2a 100644 (file)
@@ -23,8 +23,8 @@
 # undef memset
 # include <ifunc-resolve.h>
 
-# if HAVE_MEMSET_Z900_G5
-extern __typeof (__redirect_memset) MEMSET_Z900_G5 attribute_hidden;
+# if HAVE_MEMSET_Z900
+extern __typeof (__redirect_memset) MEMSET_Z900 attribute_hidden;
 # endif
 
 # if HAVE_MEMSET_Z10
index 10edde664141bc8fa171d1893d9ceb298613a4db..8224cec55711e22726b2b94e4a4f0417d5293a37 100644 (file)
@@ -88,7 +88,6 @@
           loop_count = 16;                                             \
         __asm__ volatile (".machine push\n\t"                          \
                           ".machine \"z13\"\n\t"                       \
-                          ".machinemode \"zarch_nohighgprs\"\n\t"      \
                           "    sllk %[R_I],%[R_LI],4\n\t"              \
                           "    ahi %[R_I],-1\n\t"                      \
                           /* Execute mvc and tr with correct len.  */  \
           (ch == 0 is no error, but is handled differently)  */        \
        __asm__ volatile (".machine push\n\t"                           \
                          ".machine \"z13\"\n\t"                        \
-                         ".machinemode \"zarch_nohighgprs\"\n\t"       \
                          /* Setup to check for ch >= max.  */          \
                          "    vzero %%v21\n\t"                         \
                          "    vleih %%v21,-24576,0\n\t" /* element 0:   >  */ \
               check for errors (from_ucs4[ch] == 0).  */               \
            __asm__ volatile (".machine push\n\t"                       \
                              ".machine \"z13\"\n\t"                    \
-                             ".machinemode \"zarch_nohighgprs\"\n\t"   \
                              "    sllk %[R_I],%[R_LI],4\n\t"           \
                              "    ahi %[R_I],-1\n\t"                   \
                              /* Execute tr with correct len.  */       \
index a6548d6d41246638e5a0c5d929e9ea60e1f3693c..35a5699404102cc2f7783e0885175e1785643e6d 100644 (file)
 # undef __gconv_transform_internal_ucs2reverse
 
 /* Now define the functions with vector support.  */
-# if defined __s390x__
-#  define CONVERT_32BIT_SIZE_T(REG)
-# else
-#  define CONVERT_32BIT_SIZE_T(REG) "llgfr %" #REG ",%" #REG "\n\t"
-# endif
 
 /* Convert from ISO 646-IRV to the internal (UCS4-like) format.  */
 # define DEFINE_INIT           0
     size_t loop_count, tmp;                                            \
     __asm__ volatile (".machine push\n\t"                              \
                      ".machine \"z13\"\n\t"                            \
-                     ".machinemode \"zarch_nohighgprs\"\n\t"           \
-                     CONVERT_32BIT_SIZE_T ([R_LEN])                    \
                      "    vrepib %%v30,0x7f\n\t" /* For compare > 0x7f.  */ \
                      "    srlg %[R_LI],%[R_LEN],4\n\t"                 \
                      "    vrepib %%v31,0x20\n\t"                       \
@@ -257,8 +250,6 @@ ICONV_VX_IFUNC (__gconv_transform_ascii_internal)
     size_t loop_count, tmp, tmp2;                                      \
     __asm__ volatile (".machine push\n\t"                              \
                      ".machine \"z13\"\n\t"                            \
-                     ".machinemode \"zarch_nohighgprs\"\n\t"           \
-                     CONVERT_32BIT_SIZE_T ([R_LEN])                    \
                      /* Setup to check for ch > 0x7f.  */              \
                      "    vzero %%v21\n\t"                             \
                      "    srlg %[R_LI],%[R_LEN],4\n\t"                 \
@@ -414,8 +405,6 @@ ICONV_VX_NAME (internal_ucs4le_loop) (struct __gconv_step *step,
   size_t loop_count;
   __asm__ volatile (".machine push\n\t"
                    ".machine \"z13\"\n\t"
-                   ".machinemode \"zarch_nohighgprs\"\n\t"
-                   CONVERT_32BIT_SIZE_T ([R_LEN])
                    "    bras %[R_LI],1f\n\t"
                    /* Vector permute mask:  */
                    "    .long 0x03020100,0x7060504,0x0B0A0908,0x0F0E0D0C\n\t"
@@ -517,8 +506,6 @@ ICONV_VX_NAME (ucs4_internal_loop) (struct __gconv_step *step,
       len = MIN (inend - inptr, outend - outptr) / 4;
       __asm__ volatile (".machine push\n\t"
                        ".machine \"z13\"\n\t"
-                       ".machinemode \"zarch_nohighgprs\"\n\t"
-                       CONVERT_32BIT_SIZE_T ([R_LEN])
                        /* Setup to check for ch > 0x7fffffff.  */
                        "    larl %[R_LI],9f\n\t"
                        "    vlm %%v20,%%v21,0(%[R_LI])\n\t"
@@ -644,8 +631,6 @@ ICONV_VX_NAME (ucs4le_internal_loop) (struct __gconv_step *step,
       len = MIN (inend - inptr, outend - outptr) / 4;
       __asm__ volatile (".machine push\n\t"
                        ".machine \"z13\"\n\t"
-                       ".machinemode \"zarch_nohighgprs\"\n\t"
-                       CONVERT_32BIT_SIZE_T ([R_LEN])
                        /* Setup to check for ch > 0x7fffffff.  */
                        "    larl %[R_LI],9f\n\t"
                        "    vlm %%v20,%%v22,0(%[R_LI])\n\t"
@@ -783,8 +768,6 @@ ICONV_VX_IFUNC (__gconv_transform_ucs4le_internal)
     len = MIN ((inend - inptr) / 2, (outend - outptr) / 4);            \
     __asm__ volatile (".machine push\n\t"                              \
                      ".machine \"z13\"\n\t"                            \
-                     ".machinemode \"zarch_nohighgprs\"\n\t"           \
-                     CONVERT_32BIT_SIZE_T ([R_LEN])                    \
                      /* Setup to check for ch >= 0xd800 && ch < 0xe000.  */ \
                      "    larl %[R_TMP],9f\n\t"                        \
                      "    vlm %%v20,%%v21,0(%[R_TMP])\n\t"             \
@@ -907,8 +890,6 @@ ICONV_VX_IFUNC (__gconv_transform_ucs2_internal)
     len = MIN ((inend - inptr) / 2, (outend - outptr) / 4);            \
     __asm__ volatile (".machine push\n\t"                              \
                      ".machine \"z13\"\n\t"                            \
-                     ".machinemode \"zarch_nohighgprs\"\n\t"           \
-                     CONVERT_32BIT_SIZE_T ([R_LEN])                    \
                      /* Setup to check for ch >= 0xd800 && ch < 0xe000.  */ \
                      "    larl %[R_TMP],9f\n\t"                        \
                      "    vlm %%v20,%%v22,0(%[R_TMP])\n\t"             \
@@ -1051,8 +1032,6 @@ ICONV_VX_IFUNC (__gconv_transform_ucs2reverse_internal)
          loop_count = (outend - outptr) / 16;                          \
        __asm__ volatile (".machine push\n\t"                           \
                          ".machine \"z13\"\n\t"                        \
-                         ".machinemode \"zarch_nohighgprs\"\n\t"       \
-                         CONVERT_32BIT_SIZE_T ([R_LI])                 \
                          "    larl %[R_I],3f\n\t"                      \
                          "    vlm %%v20,%%v23,0(%[R_I])\n\t"           \
                          "0:  \n\t"                                    \
@@ -1183,8 +1162,6 @@ ICONV_VX_IFUNC (__gconv_transform_internal_ucs2)
          loop_count = (outend - outptr) / 16;                          \
        __asm__ volatile (".machine push\n\t"                           \
                          ".machine \"z13\"\n\t"                        \
-                         ".machinemode \"zarch_nohighgprs\"\n\t"       \
-                         CONVERT_32BIT_SIZE_T ([R_LI])                 \
                          "    larl %[R_I],3f\n\t"                      \
                          "    vlm %%v20,%%v24,0(%[R_I])\n\t"           \
                          "0:  \n\t"                                    \
index e948b9753032653ded8c20252e5530a496ee1b69..6e9799891af6d63befb193e783fcbe5b4eef23b8 100644 (file)
@@ -1,4 +1,4 @@
-/* Enumerate available IFUNC implementations of a function. s390/s390x version.
+/* Enumerate available IFUNC implementations of a function. s390x version.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -94,8 +94,8 @@ __libc_ifunc_impl_list (const char *name, struct libc_ifunc_impl *array,
              IFUNC_IMPL_ADD (array, i, memset,
                              S390_IS_Z10 (stfle_bits), MEMSET_Z10)
 # endif
-# if HAVE_MEMSET_Z900_G5
-             IFUNC_IMPL_ADD (array, i, memset, 1, MEMSET_Z900_G5)
+# if HAVE_MEMSET_Z900
+             IFUNC_IMPL_ADD (array, i, memset, 1, MEMSET_Z900)
 # endif
              )
 #endif /* HAVE_MEMSET_IFUNC */
@@ -110,8 +110,8 @@ __libc_ifunc_impl_list (const char *name, struct libc_ifunc_impl *array,
              IFUNC_IMPL_ADD (array, i, memcmp,
                              S390_IS_Z10 (stfle_bits), MEMCMP_Z10)
 # endif
-# if HAVE_MEMCMP_Z900_G5
-             IFUNC_IMPL_ADD (array, i, memcmp, 1, MEMCMP_Z900_G5)
+# if HAVE_MEMCMP_Z900
+             IFUNC_IMPL_ADD (array, i, memcmp, 1, MEMCMP_Z900)
 # endif
              )
 #endif /* HAVE_MEMCMP_IFUNC */
@@ -126,8 +126,8 @@ __libc_ifunc_impl_list (const char *name, struct libc_ifunc_impl *array,
              IFUNC_IMPL_ADD (array, i, memcpy,
                              S390_IS_Z10 (stfle_bits), MEMCPY_Z10)
 # endif
-# if HAVE_MEMCPY_Z900_G5
-             IFUNC_IMPL_ADD (array, i, memcpy, 1, MEMCPY_Z900_G5)
+# if HAVE_MEMCPY_Z900
+             IFUNC_IMPL_ADD (array, i, memcpy, 1, MEMCPY_Z900)
 # endif
              )
 
@@ -140,8 +140,8 @@ __libc_ifunc_impl_list (const char *name, struct libc_ifunc_impl *array,
              IFUNC_IMPL_ADD (array, i, mempcpy,
                              S390_IS_Z10 (stfle_bits), MEMPCPY_Z10)
 # endif
-# if HAVE_MEMCPY_Z900_G5
-             IFUNC_IMPL_ADD (array, i, mempcpy, 1, MEMPCPY_Z900_G5)
+# if HAVE_MEMCPY_Z900
+             IFUNC_IMPL_ADD (array, i, mempcpy, 1, MEMPCPY_Z900)
 # endif
              )
 #endif /* HAVE_MEMCPY_IFUNC  */
@@ -226,8 +226,8 @@ __libc_ifunc_impl_list (const char *name, struct libc_ifunc_impl *array,
                IFUNC_IMPL_ADD (array, i, strcpy,
                                dl_hwcap & HWCAP_S390_VX, STRCPY_Z13)
 # endif
-# if HAVE_STRCPY_Z900_G5
-               IFUNC_IMPL_ADD (array, i, strcpy, 1, STRCPY_Z900_G5)
+# if HAVE_STRCPY_Z900
+               IFUNC_IMPL_ADD (array, i, strcpy, 1, STRCPY_Z900)
 # endif
                )
 #endif /* HAVE_STRCPY_IFUNC  */
@@ -250,8 +250,8 @@ __libc_ifunc_impl_list (const char *name, struct libc_ifunc_impl *array,
                IFUNC_IMPL_ADD (array, i, strncpy,
                                dl_hwcap & HWCAP_S390_VX, STRNCPY_Z13)
 # endif
-# if HAVE_STRNCPY_Z900_G5
-               IFUNC_IMPL_ADD (array, i, strncpy, 1, STRNCPY_Z900_G5)
+# if HAVE_STRNCPY_Z900
+               IFUNC_IMPL_ADD (array, i, strncpy, 1, STRNCPY_Z900)
 # endif
                )
 #endif /* HAVE_STRNCPY_IFUNC  */
@@ -298,8 +298,8 @@ __libc_ifunc_impl_list (const char *name, struct libc_ifunc_impl *array,
                IFUNC_IMPL_ADD (array, i, strcmp,
                                dl_hwcap & HWCAP_S390_VX, STRCMP_Z13)
 # endif
-# if HAVE_STRCMP_Z900_G5
-               IFUNC_IMPL_ADD (array, i, strcmp, 1, STRCMP_Z900_G5)
+# if HAVE_STRCMP_Z900
+               IFUNC_IMPL_ADD (array, i, strcmp, 1, STRCMP_Z900)
 # endif
                )
 #endif /* HAVE_STRCMP_IFUNC  */
@@ -394,8 +394,8 @@ __libc_ifunc_impl_list (const char *name, struct libc_ifunc_impl *array,
                IFUNC_IMPL_ADD (array, i, memchr,
                                dl_hwcap & HWCAP_S390_VX, MEMCHR_Z13)
 # endif
-# if HAVE_MEMCHR_Z900_G5
-               IFUNC_IMPL_ADD (array, i, memchr, 1, MEMCHR_Z900_G5)
+# if HAVE_MEMCHR_Z900
+               IFUNC_IMPL_ADD (array, i, memchr, 1, MEMCHR_Z900)
 # endif
                )
 #endif /* HAVE_MEMCHR_IFUNC  */
index c6cb8fa97c9adbafa2d88b404c7ef6e5baca47bd..a66669e1d73ee48a18f54dfaa798012ca940344b 100644 (file)
@@ -1,5 +1,5 @@
 /* IFUNC resolver function for CPU specific functions.
-   32/64 bit S/390 version.
+   64 bit S/390 version.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
index dbc2b5b976a3b6259a2509a1ff09beff27b0859a..21538139573e9637ba796f9b5d3ebd0285a30f2f 100644 (file)
@@ -34,9 +34,7 @@ strong_alias (SINGLE_NAME (TO_LOOP_DEFAULT), SINGLE_NAME (TO_LOOP))
 s390_libc_ifunc_expr (FROM_LOOP_DEFAULT, FROM_LOOP,
                      (HAVE_FROM_VX && (hwcap & HWCAP_S390_VX))
                      ? FROM_LOOP_VX
-                     : (HAVE_FROM_CU && (hwcap & HWCAP_S390_ZARCH
-                                         && hwcap & HWCAP_S390_HIGH_GPRS
-                                         && hwcap & HWCAP_S390_ETF3EH))
+                     : (HAVE_FROM_CU && (hwcap & HWCAP_S390_ETF3EH))
                        ? FROM_LOOP_CU
                        : FROM_LOOP_DEFAULT);
 
index 06d7e66f9e1525e6ae266ce73cd1a678462d2986..94f0767832f8fc169496b618a577acf2ae8239c7 100644 (file)
@@ -34,9 +34,7 @@ strong_alias (SINGLE_NAME (TO_LOOP_DEFAULT), SINGLE_NAME (TO_LOOP))
 s390_libc_ifunc_expr (FROM_LOOP_DEFAULT, FROM_LOOP,
                      (HAVE_FROM_VX && (hwcap & HWCAP_S390_VX))
                      ? FROM_LOOP_VX
-                     : (HAVE_FROM_CU && (hwcap & HWCAP_S390_ZARCH
-                                         && hwcap & HWCAP_S390_HIGH_GPRS
-                                         && hwcap & HWCAP_S390_ETF3EH))
+                     : (HAVE_FROM_CU && (hwcap & HWCAP_S390_ETF3EH))
                        ? FROM_LOOP_CU
                        : FROM_LOOP_DEFAULT);
 
index 571265267c2edbc388e00aed800c03b3d2c05b2d..ff2d251986c4cced5100b41543ef9ecb50cd7584 100644 (file)
@@ -24,39 +24,17 @@ struct __pthread_mutex_s
   int __lock;
   unsigned int __count;
   int __owner;
-#if __WORDSIZE == 64
   unsigned int __nusers;
-#endif
   /* KIND must stay at this position in the structure to maintain
      binary compatibility with static initializers.  */
   int __kind;
-#if __WORDSIZE == 64
   short __spins;
   short __glibc_reserved;
   __pthread_list_t __list;
 # define __PTHREAD_MUTEX_HAVE_PREV      1
-#else
-  unsigned int __nusers;
-  __extension__ union
-  {
-    struct
-    {
-      short __data_spins;
-      short __data_unused;
-    } __data;
-#  define __spins __data.__data_spins
-    __pthread_slist_t __list;
-  };
-# define __PTHREAD_MUTEX_HAVE_PREV      0
-#endif
 };
 
-#if __WORDSIZE == 64
-# define __PTHREAD_MUTEX_INITIALIZER(__kind) \
+#define __PTHREAD_MUTEX_INITIALIZER(__kind) \
   0, 0, 0, 0, __kind, 0, 0, { 0, 0 }
-#else
-# define __PTHREAD_MUTEX_INITIALIZER(__kind) \
-  0, 0, 0, __kind, 0, { { 0, 0 } }
-#endif
 
 #endif
index ee49a9632d68da7f5a466e2270af266184053075..ed1235b0616bb96f1ffad8eed976ea78bd84db04 100644 (file)
@@ -28,7 +28,6 @@ struct __pthread_rwlock_arch_t
   unsigned int __writers_futex;
   unsigned int __pad3;
   unsigned int __pad4;
-#if __WORDSIZE == 64
   int __cur_writer;
   int __shared;
   unsigned long int __pad1;
@@ -36,23 +35,9 @@ struct __pthread_rwlock_arch_t
   /* FLAGS must stay at this position in the structure to maintain
      binary compatibility.  */
   unsigned int __flags;
-# else
-  unsigned char __pad1;
-  unsigned char __pad2;
-  unsigned char __shared;
-  /* FLAGS must stay at this position in the structure to maintain
-     binary compatibility.  */
-  unsigned char __flags;
-  int __cur_writer;
-#endif
 };
 
-#if __WORDSIZE == 64
-# define __PTHREAD_RWLOCK_INITIALIZER(__flags) \
+#define __PTHREAD_RWLOCK_INITIALIZER(__flags) \
   0, 0, 0, 0, 0, 0, 0, 0, 0, 0, __flags
-#else
-# define __PTHREAD_RWLOCK_INITIALIZER(__flags) \
-  0, 0, 0, 0, 0, 0, 0, 0, 0, __flags, 0
-#endif
 
 #endif
index 9e2112120b6b9affae93814f48a090463c3aeddb..f8e4469f7eae801118a6b7c462dd2a60880f7ad9 100644 (file)
@@ -1,13 +1,2 @@
-#include <bits/wordsize.h>
-
-#if __WORDSIZE == 64
-# define __PTHREAD_MUTEX_KIND_OFFSET     16
-#else
-# define __PTHREAD_MUTEX_KIND_OFFSET     12
-#endif
-
-#if __WORDSIZE == 64
-# define __PTHREAD_RWLOCK_FLAGS_OFFSET   48
-#else
-# define __PTHREAD_RWLOCK_FLAGS_OFFSET   27
-#endif
+#define __PTHREAD_MUTEX_KIND_OFFSET     16
+#define __PTHREAD_RWLOCK_FLAGS_OFFSET   48
index 9870e54327dc39cb698d3463544042f82c79b567..de7e9c64828abf12a213279107d3e806b377603f 100644 (file)
@@ -44,10 +44,6 @@ typedef struct
   void *__private_ss;
 } tcbhead_t;
 
-# ifndef __s390x__
-#  define TLS_MULTIPLE_THREADS_IN_TCB 1
-# endif
-
 #else /* __ASSEMBLER__ */
 # include <tcb-offsets.h>
 #endif
index e74c63f6e419a69b29c4fc0fbf4ff5a438f5bd5a..4bf4e4bdda50903d7fdd4a13272972523e1b6d0c 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of rawmemchr.
+/* Vector optimized 64 bit S/390 version of rawmemchr.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -41,7 +41,6 @@
 */
 ENTRY(RAWMEMCHR_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        vlbb    %v16,0(%r2),6   /* Load s until next 4k-byte boundary.  */
        lcbb    %r1,0(%r2),6    /* Get bytes to 4k-byte boundary or 16.  */
index 00e88b0628201386ac24f336bef1cae80181fd27..b263c3141ba75e515a3d8248bffc55d28faf701c 100644 (file)
@@ -1,11 +1,4 @@
 /* Determine the wordsize from the preprocessor defines.  */
 
-#if defined __s390x__
-# define __WORDSIZE    64
-#else
-# define __WORDSIZE    32
-# define __WORDSIZE32_SIZE_ULONG       1
-# define __WORDSIZE32_PTRDIFF_LONG     0
-#endif
-
-#define __WORDSIZE_TIME64_COMPAT32     0
+#define __WORDSIZE                     64
+#define __WORDSIZE_TIME64_COMPAT32     0
index 2c97d3824f4547dff60c28899b222093a52e87d1..3671c7cd7a1ea4c8d7beb1aa967e2d642f322dbd 100644 (file)
@@ -3,7 +3,7 @@
 #define STACK_CHK_GUARD \
   ({ uintptr_t x; __asm__ ("ear %0,%%a0; sllg %0,%0,32; ear %0,%%a1; lg %0,0x28(%0)" : "=a" (x)); x; })
 
-/* On s390/s390x there is no unique pointer guard, instead we use the
+/* On s390x there is no unique pointer guard, instead we use the
    same value as the stack guard.  */
 #define POINTER_CHK_GUARD                                      \
   ({                                                           \
index 579e12173157acbcc3c49b60661a8cdd0111fdc5..6d954cf4024ea964f2bfc54dde78d9d8fd5b333f 100644 (file)
@@ -26,8 +26,8 @@
 #include "sysdep.h"
 #include "asm-syntax.h"
 
-#if HAVE_STRNCPY_Z900_G5
-ENTRY(STRNCPY_Z900_G5)
+#if HAVE_STRNCPY_Z900
+ENTRY(STRNCPY_Z900)
        .text
        stg   %r2,48(%r15)          # save dst pointer
        slgr  %r2,%r3               # %r3 points to src, %r2+%r3 to dst
@@ -87,13 +87,13 @@ ENTRY(STRNCPY_Z900_G5)
        jo    .L13
 .Lexit: lg    %r2,48(%r15)         # return dst pointer
        br    %r14
-END(STRNCPY_Z900_G5)
+END(STRNCPY_Z900)
 
 # if ! HAVE_STRNCPY_IFUNC
-strong_alias (STRNCPY_Z900_G5, strncpy)
+strong_alias (STRNCPY_Z900, strncpy)
 # endif
 
 # if defined SHARED && IS_IN (libc)
-strong_alias (STRNCPY_Z900_G5, __GI_strncpy)
+strong_alias (STRNCPY_Z900, __GI_strncpy)
 # endif
 #endif
index 4b0194ab0aa7b4839cd43264f0c579b03bafb097..ff6ebf7a432b54fd4c043e6d229de36427df201c 100644 (file)
 
 #include <elf/sotruss-lib.c>
 
-#if __ELF_NATIVE_CLASS == 32
-# define la_s390_gnu_pltenter  la_s390_32_gnu_pltenter
-# define la_s390_gnu_pltexit   la_s390_32_gnu_pltexit
-# define La_s390_regs          La_s390_32_regs
-# define La_s390_retval                La_s390_32_retval
-#else
-# define la_s390_gnu_pltenter  la_s390_64_gnu_pltenter
-# define la_s390_gnu_pltexit   la_s390_64_gnu_pltexit
-# define La_s390_regs          La_s390_64_regs
-# define La_s390_retval                La_s390_64_retval
-#endif
-
-ElfW(Addr)
-la_s390_gnu_pltenter (ElfW(Sym) *sym,
-                     unsigned int ndx __attribute__ ((unused)),
-                     uintptr_t *refcook, uintptr_t *defcook,
-                     La_s390_regs *regs, unsigned int *flags,
-                     const char *symname, long int *framesizep)
+Elf64_Addr
+la_s390_64_gnu_pltenter (Elf64_Sym *sym,
+                        unsigned int ndx __attribute__ ((unused)),
+                        uintptr_t *refcook, uintptr_t *defcook,
+                        La_s390_64_regs *regs, unsigned int *flags,
+                        const char *symname, long int *framesizep)
 {
   print_enter (refcook, defcook, symname,
               regs->lr_r2, regs->lr_r3, regs->lr_r4, *flags);
@@ -51,10 +39,11 @@ la_s390_gnu_pltenter (ElfW(Sym) *sym,
 }
 
 unsigned int
-la_s390_gnu_pltexit (ElfW(Sym) *sym, unsigned int ndx, uintptr_t *refcook,
-                    uintptr_t *defcook,
-                    const struct La_s390_regs *inregs,
-                    struct La_s390_retval *outregs, const char *symname)
+la_s390_64_gnu_pltexit (Elf64_Sym *sym, unsigned int ndx, uintptr_t *refcook,
+                       uintptr_t *defcook,
+                       const struct La_s390_64_regs *inregs,
+                       struct La_s390_64_retval *outregs,
+                       const char *symname)
 {
   print_exit (refcook, defcook, symname, outregs->lrv_r2);
 
index 02c8e4561754b261652e28fb023394ce0ab0fcbd..8184fd3bc4b5076adb260c93bf697b8e3cde4731 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of stpcpy.
+/* Vector optimized 64 bit S/390 version of stpcpy.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -40,7 +40,6 @@
 */
 ENTRY(STPCPY_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        vlbb    %v16,0(%r3),6   /* Load s until next 4k-byte boundary.  */
        lcbb    %r1,0(%r3),6    /* Get bytes to 4k-byte boundary or 16.  */
index 739bf7ebce2596532c801a4a66b2b91067027433..46a82e71b03e76486c970ad14b6a155253e98125 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of stpncpy.
+/* Vector optimized 64 bit S/390 version of stpncpy.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 */
 ENTRY(STPNCPY_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__ */
 
        clgfi   %r4,0
        ber     %r14            /* Nothing to do, if n == 0.  */
index 434c78ca4af0d832c79091bc0875b54ba1a53a08..0f36c8de8a1012a5203cb519ab59cc6aaf747d99 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of strcat.
+/* Vector optimized 64 bit S/390 version of strcat.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -40,7 +40,6 @@
 */
 ENTRY(STRCAT_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        lgr     %r0,%r2         /* Save destination pointer for return.  */
 
index f263f51bb7c81e9b6af67943ff74b2185eafc97f..4544c85592c6555b4f9f64104f13b087ca230918 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of strchr.
+/* Vector optimized 64 bit S/390 version of strchr.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -40,7 +40,6 @@
 */
 ENTRY(STRCHR_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        vlbb    %v16,0(%r2),6   /* Load s until next 4k-byte boundary.  */
        lcbb    %r1,0(%r2),6    /* Get bytes to 4k-byte boundary or 16.  */
index 4a648190a5add66b09c10a5dbe510f30b0047a63..485be32b043220ee7c4ab6ad941cfb75338509c8 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of strchrnul.
+/* Vector optimized 64 bit S/390 version of strchrnul.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -39,7 +39,6 @@
 */
 ENTRY(STRCHRNUL_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        vlbb    %v16,0(%r2),6   /* Load s until next 4k-byte boundary.  */
        lcbb    %r1,0(%r2),6    /* Get bytes to 4k-byte boundary or 16.  */
index fda693002d82a7b48ad3e599e9bcbaf36adc1562..2fe013cb82101d2d969e6e900c05233e9650ec10 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of strcmp.
+/* Vector optimized 64 bit S/390 version of strcmp.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -39,7 +39,6 @@
 */
 ENTRY(STRCMP_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        lghi    %r5,0           /* current_len = 0.  */
 
@@ -113,7 +112,7 @@ END(STRCMP_Z13)
 strong_alias (STRCMP_Z13, strcmp)
 # endif
 
-# if ! HAVE_STRCMP_Z900_G5 && defined SHARED && IS_IN (libc)
+# if ! HAVE_STRCMP_Z900 && defined SHARED && IS_IN (libc)
 strong_alias (STRCMP_Z13, __GI_strcmp)
 # endif
 #endif
index 2404cdc3c015b44ea9f86889854cdd6485be100f..07ad1fbdf5e7c086aafabe7d06a6bed1985b8ebf 100644 (file)
 #include "sysdep.h"
 #include "asm-syntax.h"
 
-#if HAVE_STRCMP_Z900_G5
-# if defined __s390x__
-#  define SLGR slgr
-#  define LGHI lghi
-# else
-#  define SLGR slr
-#  define LGHI lhi
-# endif /* ! defined __s390x__  */
-
+#if HAVE_STRCMP_Z900
        .text
-ENTRY(STRCMP_Z900_G5)
-       SLGR   %r0,%r0
+ENTRY(STRCMP_Z900)
+       slgr   %r0,%r0
 0:     clst  %r2,%r3
        jo    0b
        jp    1f
        jm    2f
-       SLGR  %r2,%r2
+       slgr  %r2,%r2
        br    %r14
-1:     LGHI  %r2,1
+1:     lghi  %r2,1
        br    %r14
-2:     LGHI  %r2,-1
+2:     lghi  %r2,-1
        br    %r14
-END(STRCMP_Z900_G5)
+END(STRCMP_Z900)
 
 # if ! HAVE_STRCMP_IFUNC
-strong_alias (STRCMP_Z900_G5, strcmp)
+strong_alias (STRCMP_Z900, strcmp)
 # endif
 
 # if defined SHARED && IS_IN (libc)
-strong_alias (STRCMP_Z900_G5, __GI_strcmp)
+strong_alias (STRCMP_Z900, __GI_strcmp)
 # endif
 #endif
index 2dbffb13c9c3cb09619403c8d91a0c1cf7e81c10..9ed3abee1949fa698ab12dcffaaa5cf204ef45de 100644 (file)
@@ -26,8 +26,8 @@
 # include <ifunc-resolve.h>
 # undef strcmp
 
-# if HAVE_STRCMP_Z900_G5
-extern __typeof (__redirect_strcmp) STRCMP_Z900_G5 attribute_hidden;
+# if HAVE_STRCMP_Z900
+extern __typeof (__redirect_strcmp) STRCMP_Z900 attribute_hidden;
 # endif
 
 # if HAVE_STRCMP_Z13
index 2ddc96ed0b7fcb0edd843cdee5d23da7c487530c..7cc6dd8f6892a4629d7ebc634cd6a14d3e3ab037 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of strcpy.
+/* Vector optimized 64 bit S/390 version of strcpy.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -38,7 +38,6 @@
 */
 ENTRY(STRCPY_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        vlbb    %v16,0(%r3),6   /* Load s until next 4k-byte boundary.  */
        lcbb    %r1,0(%r3),6    /* Get bytes to 4k-byte boundary or 16.  */
@@ -103,7 +102,7 @@ END(STRCPY_Z13)
 strong_alias (STRCPY_Z13, strcpy)
 # endif
 
-# if ! HAVE_STRCPY_Z900_G5 && defined SHARED && IS_IN (libc)
+# if ! HAVE_STRCPY_Z900 && defined SHARED && IS_IN (libc)
 strong_alias (STRCPY_Z13, __GI_strcpy)
 # endif
 #endif
index 39f72381524f75e2202e14fc47167863a37ec3fe..a34cb56b9a82bf3c87cf68fb8b6ac9556873bd81 100644 (file)
@@ -1,4 +1,4 @@
-/* strcpy - copy a string from source to destination.  64/31 bit S/390 version.
+/* strcpy - copy a string from source to destination.  64 bit S/390 version.
    Copyright (C) 2001-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 #include "sysdep.h"
 #include "asm-syntax.h"
 
-#if HAVE_STRCPY_Z900_G5
-# if defined __s390x__
-#  define SLGR slgr
-#  define LGR  lgr
-# else
-#  define SLGR slr
-#  define LGR  lr
-# endif /* ! defined __s390x__  */
-
-        .text
-ENTRY(STRCPY_Z900_G5)
-       SLGR  %r0,%r0
-       LGR   %r1,%r2
+#if HAVE_STRCPY_Z900
+       .text
+ENTRY(STRCPY_Z900)
+       slgr  %r0,%r0
+       lgr   %r1,%r2
 0:     mvst  %r1,%r3
        jo    0b
        br    %r14
-END(STRCPY_Z900_G5)
-
-# undef SLGR
-# undef LGR
+END(STRCPY_Z900)
 
 # if ! HAVE_STRCPY_IFUNC
-strong_alias (STRCPY_Z900_G5, strcpy)
+strong_alias (STRCPY_Z900, strcpy)
 # endif
 
 # if defined SHARED && IS_IN (libc)
-strong_alias (STRCPY_Z900_G5, __GI_strcpy)
+strong_alias (STRCPY_Z900, __GI_strcpy)
 # endif
 #endif
index a307a5f3701e77071a1899336e7b6fa97fa19f5b..daede82f3f6b793aff49870bd4f3fca2645706af 100644 (file)
@@ -24,8 +24,8 @@
 # undef strcpy
 # include <ifunc-resolve.h>
 
-# if HAVE_STRCPY_Z900_G5
-extern __typeof (__redirect_strcpy) STRCPY_Z900_G5 attribute_hidden;
+# if HAVE_STRCPY_Z900
+extern __typeof (__redirect_strcpy) STRCPY_Z900 attribute_hidden;
 # endif
 
 # if HAVE_STRCPY_Z13
index 7a825131dd0677538426a4f2a2809d9999ddb412..e28f738d6cb1ca8ef5c6bff664e78c5c04bfb25a 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of strcspn.
+/* Vector optimized 64 bit S/390 version of strcspn.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -62,7 +62,6 @@
 */
 ENTRY(STRCSPN_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        /*
          Check if reject-string fits in one vreg:
index e4bbcd4500a3a97e35e0a131e25e52525dcfca09..99f71f1e22ba079605f65d45faa41c294f2a2708 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of strlen.
+/* Vector optimized 64 bit S/390 version of strlen.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -37,7 +37,6 @@
 */
 ENTRY(STRLEN_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        vlbb    %v16,0(%r2),6   /* Load s until next 4k-byte boundary.  */
        lcbb    %r1,0(%r2),6    /* Get bytes to 4k-byte boundary or 16.  */
index 02b2022cbc053b6ba5580574d654e6830c1dcf02..53e80a49c11607c0c30a43c5d7fa3437072186fd 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of strncat.
+/* Vector optimized 64 bit S/390 version of strncat.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 */
 ENTRY(STRNCAT_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__ */
 
        clgfi   %r4,0
        ber     %r14            /* Nothing to do, if n == 0.  */
index 332dd4593e43e682f51fec55196545c9ba4e2f99..a334bdfca16e18563eb5a7e8733ae854bc3767f2 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of strncmp.
+/* Vector optimized 64 bit S/390 version of strncmp.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 */
 ENTRY(STRNCMP_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__ */
 
        clgije  %r4,0,.Lend_equal /* Nothing to do if n == 0,  */
        lghi    %r5,0           /* current_len = 0.  */
index 76155bf8c4d1013c7bca81096ae4666307535900..9d65d4ebe7b9e8874fec13efbdcc63d2a6b13c16 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of strncpy.
+/* Vector optimized 64 bit S/390 version of strncpy.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 */
 ENTRY(STRNCPY_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__ */
 
        clgfi   %r4,0
        ber     %r14            /* Nothing to do, if n == 0.  */
@@ -202,7 +197,7 @@ END(STRNCPY_Z13)
 strong_alias (STRNCPY_Z13, strncpy)
 # endif
 
-# if ! HAVE_STRNCPY_Z900_G5 && defined SHARED && IS_IN (libc)
+# if ! HAVE_STRNCPY_Z900 && defined SHARED && IS_IN (libc)
 strong_alias (STRNCPY_Z13, __GI_strncpy)
 # endif
 #endif
index b7ace482a5641e7cffc34d4069de3c37d0717ed8..986f00a0f40ed7961d5c7213566ee1136d6c9383 100644 (file)
@@ -26,8 +26,8 @@
 # undef strncpy
 # include <ifunc-resolve.h>
 
-# if HAVE_STRNCPY_Z900_G5
-extern __typeof (__redirect_strncpy) STRNCPY_Z900_G5 attribute_hidden;
+# if HAVE_STRNCPY_Z900
+extern __typeof (__redirect_strncpy) STRNCPY_Z900 attribute_hidden;
 # endif
 
 # if HAVE_STRNCPY_Z13
index db1bda229fc6ec830cdc4d4e2922186cd961de79..29e3353d5a174298b38fe76d30f7880f0321ad5a 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of strnlen.
+/* Vector optimized 64 bit S/390 version of strnlen.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 */
 ENTRY(STRNLEN_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-
-# if !defined __s390x__
-       llgfr   %r3,%r3
-# endif /* !defined __s390x__ */
 
        clgfi   %r3,0           /* if maxlen == 0, return 0.  */
        locgre  %r2,%r3
index 8fb6963be2e971b43ae0c9479afbaf62f03d80f9..6bf12134182bada56844182a22a764d86ed8390b 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of strpbrk.
+/* Vector optimized 64 bit S/390 version of strpbrk.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -63,7 +63,6 @@
 */
 ENTRY(STRPBRK_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        /*
          Check if accept-string fits in one vreg:
index ed2342c9e30ed2656d9f876a87c8b28960484894..219c6d59ceb72c11f27b3b32f28fdf6dc69e3c1f 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of strrchr.
+/* Vector optimized 64 bit S/390 version of strrchr.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -43,7 +43,6 @@
 */
 ENTRY(STRRCHR_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        vlbb    %v16,0(%r2),6   /* Load s until next 4k-byte boundary.  */
        lcbb    %r0,0(%r2),6    /* Get bytes to 4k-byte boundary or 16.  */
index aa985de110d9f8f93ba2f6178f957d103ec61e5d..67de8883951f45f16cbd2f817b679de424f00e1c 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of strspn.
+/* Vector optimized 64 bit S/390 version of strspn.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -61,7 +61,6 @@
 */
 ENTRY(STRSPN_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        /*
          Check if accept-string fits in one vreg:
index 10875acad6960731270e87ed8f3b9ad296395334..acf47928ba945a771a8e9d75e66a2d2759ca5135 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of strstr.
+/* Vector optimized 64 bit S/390 version of strstr.
    Copyright (C) 2019-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -26,7 +26,6 @@
    Locate a substring.  */
 ENTRY(STRSTR_ARCH13)
        .machine "arch13"
-       .machinemode "zarch_nohighgprs"
        lcbb    %r1,0(%r3),6
        jo      .Lneedle_on_bb  /* Needle on block-boundary?  */
        vl      %v18,0(%r3),6   /* Load needle.  */
index 6090d21a975839be4ac43e91970f5bcb20adda0b..58feb144506f8192342765aaefd79955fa7bc636 100644 (file)
        .type   r0x2, @function
 r0x2:
        .cfi_startproc
-#if defined (__s390x__)
        agr %r0,%r0
-#else
-       ar %r0,%r0
-#endif
        br %r14
        .cfi_endproc
        .size   r0x2, .-r0x2
index 3b2fc3093e381b5da8f21c1df0d1e9376a037dc7..49087ef5e0cabcbeb04620c987d87bef7cb02009 100644 (file)
 #include <stdlib.h>
 #include <unistd.h>
 
-#if defined (__s390x__)
 static const unsigned long magic_value = 0x0011223344556677UL;
-#else
-static const unsigned long magic_value = 0x00112233;
-#endif
 
 unsigned long r0x2_trampoline (unsigned long);
 
@@ -35,7 +31,6 @@ unsigned long r0x2_trampoline (unsigned long);
    _dl_runtime_resolve and _dl_runtime_profile.  */
 asm ("    .type r0x2_trampoline, @function\n"
      "r0x2_trampoline:\n"
-#if defined (__s390x__)
      "    lgr %r0,%r2\n"
      "    stg %r14,112(%r15)\n"
      "    aghi %r15,-160\n"
@@ -44,28 +39,6 @@ asm ("    .type r0x2_trampoline, @function\n"
      "    lg %r14,112(%r15)\n"
      "    lgr %r2,%r0\n"
      "    br %r14\n"
-#elif defined (__zarch__)
-     "    lr %r0,%r2\n"
-     "    st %r14,56(%r15)\n"
-     "    ahi %r15,-96\n"
-     "    brasl %r14,r0x2@plt\n"
-     "    ahi %r15,96\n"
-     "    l %r14,56(%r15)\n"
-     "    lr %r2,%r0\n"
-     "    br %r14\n"
-#else
-     "    lr %r0,%r2\n"
-     "    st %r14,56(%r15)\n"
-     "    ahi %r15,-96\n"
-     "    balr %r14,0\n"
-     "    l %r14,1f-.(%r14)\n"
-     "    basr %r14,%r14\n"
-     "    ahi %r15,96\n"
-     "    l %r14,56(%r15)\n"
-     "    lr %r2,%r0\n"
-     "    br %r14\n"
-     "1: .long r0x2\n"
-#endif
      );
 
 static int
index ceba2fad5e2e4cbebda756711792bfaba6320b47..68d256a7b25c4dea2f18a8fbdec0e371a7003d08 100644 (file)
 # define ASM_CLOBBER_VR(NR)
 #endif
 
-#if defined __s390x__
-# define CONVERT_32BIT_SIZE_T(REG)
-#else
-# define CONVERT_32BIT_SIZE_T(REG) "llgfr %" #REG ",%" #REG "\n\t"
-#endif
-
 /* UTF-32 big endian byte order mark.  */
 #define BOM_UTF32               0x0000feffu
 
@@ -256,12 +250,9 @@ gconv_end (struct __gconv_step *data)
     unsigned long tmp, tmp2, tmp3;                                     \
     asm volatile (".machine push\n\t"                                  \
                  ".machine \"z13\"\n\t"                                \
-                 ".machinemode \"zarch_nohighgprs\"\n\t"               \
                  /* Setup to check for surrogates.  */                 \
                  "    larl %[R_TMP],9f\n\t"                            \
                  "    vlm %%v30,%%v31,0(%[R_TMP])\n\t"                 \
-                 CONVERT_32BIT_SIZE_T ([R_INLEN])                      \
-                 CONVERT_32BIT_SIZE_T ([R_OUTLEN])                     \
                  /* Loop which handles UTF-16 chars <0xd800, >0xdfff.  */ \
                  "0:  clgijl %[R_INLEN],16,2f\n\t"                     \
                  "    clgijl %[R_OUTLEN],32,2f\n\t"                    \
@@ -402,12 +393,9 @@ gconv_end (struct __gconv_step *data)
     unsigned long tmp, tmp2, tmp3;                                     \
     asm volatile (".machine push\n\t"                                  \
                  ".machine \"z13\"\n\t"                                \
-                 ".machinemode \"zarch_nohighgprs\"\n\t"               \
                  /* Setup to check for surrogates.  */                 \
                  "    larl %[R_TMP],9f\n\t"                            \
                  "    vlm %%v30,%%v31,0(%[R_TMP])\n\t"                 \
-                 CONVERT_32BIT_SIZE_T ([R_INLEN])                      \
-                 CONVERT_32BIT_SIZE_T ([R_OUTLEN])                     \
                  /* Loop which handles UTF-16 chars <0xd800, >0xdfff.  */ \
                  "0:  clgijl %[R_INLEN],16,20f\n\t"                    \
                  "    clgijl %[R_OUTLEN],32,20f\n\t"                   \
@@ -572,12 +560,9 @@ gconv_end (struct __gconv_step *data)
     unsigned long tmp, tmp2, tmp3;                                     \
     asm volatile (".machine push\n\t"                                  \
                  ".machine \"z13\"\n\t"                                \
-                 ".machinemode \"zarch_nohighgprs\"\n\t"               \
                  /* Setup to check for surrogates.  */                 \
                  "    larl %[R_TMP],9f\n\t"                            \
                  "    vlm %%v30,%%v31,0(%[R_TMP])\n\t"                 \
-                 CONVERT_32BIT_SIZE_T ([R_INLEN])                      \
-                 CONVERT_32BIT_SIZE_T ([R_OUTLEN])                     \
                  /* Loop which handles UTF-32 chars                    \
                     ch < 0xd800 || (ch > 0xdfff && ch < 0x10000).  */  \
                  "0:  clgijl %[R_INLEN],32,2f\n\t"                     \
@@ -712,12 +697,9 @@ gconv_end (struct __gconv_step *data)
     unsigned long tmp, tmp2, tmp3;                                     \
     asm volatile (".machine push\n\t"                                  \
                  ".machine \"z13\"\n\t"                                \
-                 ".machinemode \"zarch_nohighgprs\"\n\t"               \
                  /* Setup to check for surrogates.  */                 \
                  "    larl %[R_TMP],9f\n\t"                            \
                  "    vlm %%v30,%%v31,0(%[R_TMP])\n\t"                 \
-                 CONVERT_32BIT_SIZE_T ([R_INLEN])                      \
-                 CONVERT_32BIT_SIZE_T ([R_OUTLEN])                     \
                  /* Loop which handles UTF-32 chars                    \
                     ch < 0xd800 || (ch > 0xdfff && ch < 0x10000).  */  \
                  "0:  clgijl %[R_INLEN],32,20f\n\t"                    \
index 1c43f5b221569b357f08a21dc829a2d122279aae..1bc52e5833ec29b4491853a241198d59b117e994 100644 (file)
 # define ASM_CLOBBER_VR(NR)
 #endif
 
-#if defined __s390x__
-# define CONVERT_32BIT_SIZE_T(REG)
-#else
-# define CONVERT_32BIT_SIZE_T(REG) "llgfr %" #REG ",%" #REG "\n\t"
-#endif
-
 /* Defines for skeleton.c.  */
 #define DEFINE_INIT            0
 #define DEFINE_FINI            0
@@ -176,7 +170,6 @@ gconv_end (struct __gconv_step *data)
                                                                        \
     __asm__ __volatile__ (".machine push       \n\t"                   \
                          ".machine \"z9-109\" \n\t"                    \
-                         ".machinemode \"zarch_nohighgprs\"\n\t"       \
                          "0: " INSTRUCTION "  \n\t"                    \
                          ".machine pop        \n\t"                    \
                          "   jo     0b        \n\t"                    \
@@ -247,11 +240,8 @@ gconv_end (struct __gconv_step *data)
     unsigned long tmp, tmp2, tmp3;                                     \
     asm volatile (".machine push\n\t"                                  \
                  ".machine \"z13\"\n\t"                                \
-                 ".machinemode \"zarch_nohighgprs\"\n\t"               \
                  "    vrepib %%v30,0x7f\n\t" /* For compare > 0x7f.  */ \
                  "    vrepib %%v31,0x20\n\t"                           \
-                 CONVERT_32BIT_SIZE_T ([R_INLEN])                      \
-                 CONVERT_32BIT_SIZE_T ([R_OUTLEN])                     \
                  /* Loop which handles UTF-8 chars <=0x7f.  */         \
                  "0:  clgijl %[R_INLEN],16,20f\n\t"                    \
                  "    clgijl %[R_OUTLEN],32,20f\n\t"                   \
@@ -636,12 +626,9 @@ gconv_end (struct __gconv_step *data)
     unsigned long tmp, tmp2, tmp3;                                     \
     asm volatile (".machine push\n\t"                                  \
                  ".machine \"z13\"\n\t"                                \
-                 ".machinemode \"zarch_nohighgprs\"\n\t"               \
                  /* Setup to check for values <= 0x7f.  */             \
                  "    larl %[R_TMP],9f\n\t"                            \
                  "    vlm %%v30,%%v31,0(%[R_TMP])\n\t"                 \
-                 CONVERT_32BIT_SIZE_T ([R_INLEN])                      \
-                 CONVERT_32BIT_SIZE_T ([R_OUTLEN])                     \
                  /* Loop which handles UTF-16 chars <=0x7f.  */        \
                  "0:  clgijl %[R_INLEN],32,2f\n\t"                     \
                  "    clgijl %[R_OUTLEN],16,2f\n\t"                    \
@@ -823,12 +810,9 @@ gconv_end (struct __gconv_step *data)
     unsigned long tmp, tmp2, tmp3;                                     \
     asm volatile (".machine push\n\t"                                  \
                  ".machine \"z13\"\n\t"                                \
-                 ".machinemode \"zarch_nohighgprs\"\n\t"               \
                  /* Setup to check for values <= 0x7f.  */             \
                  "    larl %[R_TMP],9f\n\t"                            \
                  "    vlm %%v30,%%v31,0(%[R_TMP])\n\t"                 \
-                 CONVERT_32BIT_SIZE_T ([R_INLEN])                      \
-                 CONVERT_32BIT_SIZE_T ([R_OUTLEN])                     \
                  /* Loop which handles UTF-16 chars <=0x7f.  */        \
                  "0:  clgijl %[R_INLEN],32,20f\n\t"                    \
                  "    clgijl %[R_OUTLEN],16,20f\n\t"                   \
index a5bf48e49948016e2257fd387cc981d1e67d2bdd..c1708772c6d32484fa66157528b9a82506a2479f 100644 (file)
 # define ASM_CLOBBER_VR(NR)
 #endif
 
-#if defined __s390x__
-# define CONVERT_32BIT_SIZE_T(REG)
-#else
-# define CONVERT_32BIT_SIZE_T(REG) "llgfr %" #REG ",%" #REG "\n\t"
-#endif
-
 /* Defines for skeleton.c.  */
 #define DEFINE_INIT            0
 #define DEFINE_FINI            0
@@ -176,7 +170,6 @@ gconv_end (struct __gconv_step *data)
                                                                        \
     __asm__ __volatile__ (".machine push       \n\t"                   \
                          ".machine \"z9-109\" \n\t"                    \
-                         ".machinemode \"zarch_nohighgprs\"\n\t"       \
                          "0: " INSTRUCTION "  \n\t"                    \
                          ".machine pop        \n\t"                    \
                          "   jo     0b        \n\t"                    \
@@ -480,11 +473,8 @@ gconv_end (struct __gconv_step *data)
     unsigned long tmp, tmp2, tmp3;                                     \
     asm volatile (".machine push\n\t"                                  \
                  ".machine \"z13\"\n\t"                                \
-                 ".machinemode \"zarch_nohighgprs\"\n\t"               \
                  "    vrepib %%v30,0x7f\n\t" /* For compare > 0x7f.  */ \
                  "    vrepib %%v31,0x20\n\t"                           \
-                 CONVERT_32BIT_SIZE_T ([R_INLEN])                      \
-                 CONVERT_32BIT_SIZE_T ([R_OUTLEN])                     \
                  /* Loop which handles UTF-8 chars <=0x7f.  */         \
                  "0:  clgijl %[R_INLEN],16,20f\n\t"                    \
                  "    clgijl %[R_OUTLEN],64,20f\n\t"                   \
@@ -691,13 +681,10 @@ gconv_end (struct __gconv_step *data)
     unsigned long tmp, tmp2, tmp3;                                     \
     asm volatile (".machine push\n\t"                                  \
                  ".machine \"z13\"\n\t"                                \
-                 ".machinemode \"zarch_nohighgprs\"\n\t"               \
                  "    vleif %%v20,127,0\n\t"   /* element 0: 127  */   \
                  "    vzero %%v21\n\t"                                 \
                  "    vleih %%v21,8192,0\n\t"  /* element 0:   >  */   \
                  "    vleih %%v21,-8192,2\n\t" /* element 1: =<>  */   \
-                 CONVERT_32BIT_SIZE_T ([R_INLEN])                      \
-                 CONVERT_32BIT_SIZE_T ([R_OUTLEN])                     \
                  /* Loop which handles UTF-32 chars <=0x7f.  */        \
                  "0:  clgijl %[R_INLEN],64,2f\n\t"                     \
                  "    clgijl %[R_OUTLEN],16,2f\n\t"                    \
@@ -869,13 +856,10 @@ gconv_end (struct __gconv_step *data)
     unsigned long tmp, tmp2;                                           \
     asm volatile (".machine push\n\t"                                  \
                  ".machine \"z13\"\n\t"                                \
-                 ".machinemode \"zarch_nohighgprs\"\n\t"               \
                  "    vleif %%v20,127,0\n\t"   /* element 0: 127  */   \
                  "    vzero %%v21\n\t"                                 \
                  "    vleih %%v21,8192,0\n\t"  /* element 0:   >  */   \
                  "    vleih %%v21,-8192,2\n\t" /* element 1: =<>  */   \
-                 CONVERT_32BIT_SIZE_T ([R_INLEN])                      \
-                 CONVERT_32BIT_SIZE_T ([R_OUTLEN])                     \
                  /* Loop which handles UTF-32 chars <= 0x7f.  */       \
                  "0:  clgijl %[R_INLEN],64,20f\n\t"                    \
                  "    clgijl %[R_OUTLEN],16,20f\n\t"                   \
index 98c9d09064501cad108404430eb2e65569eb076e..ee509ab8d046bbeb4bb22b1e1b5114b6645e1846 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcpcpy.
+/* Vector optimized 64 bit S/390 version of wcpcpy.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -40,7 +40,6 @@
 */
 ENTRY(WCPCPY_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        vlbb    %v16,0(%r3),6   /* Load s until next 4k-byte boundary.  */
        lcbb    %r1,0(%r3),6    /* Get bytes to 4k-byte boundary or 16.  */
index 097eee9678660cdb03529aa295b4919707da7dae..69817aa97d29ab3a0e723b25fd4923eeb64afefa 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcpncpy.
+/* Vector optimized 64 bit S/390 version of wcpncpy.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 */
 ENTRY(WCPNCPY_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__ */
 
        clgfi   %r4,0
        ber     %r14            /* Nothing to do, if n == 0.  */
@@ -62,13 +57,8 @@ ENTRY(WCPNCPY_Z13)
        llgfr   %r6,%r6         /* Convert 32bit to 64bit.  */
 
        /* Check range of maxlen and convert to byte-count.  */
-# ifdef __s390x__
        tmhh    %r4,49152       /* Test bit 0 or 1 of maxlen.  */
        lghi    %r1,-4          /* Max byte-count is 18446744073709551612.  */
-# else
-       tmlh    %r4,49152       /* Test bit 0 or 1 of maxlen.  */
-       llilf   %r1,4294967292  /* Max byte-count is 4294967292.  */
-# endif /* !__s390x__ */
        sllg    %r4,%r4,2       /* Convert character-count to byte-count.  */
        locgrne %r4,%r1         /* Use max byte-count, if bit 0/1 was one.  */
 
index 0feb4797e661463effcaa5764ddde16c95770985..a7ec6d50b5e41bfcdf263828ea2ebb4e71da26a7 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcscat.
+/* Vector optimized 64 bit S/390 version of wcscat.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -40,7 +40,6 @@
 */
 ENTRY(WCSCAT_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        vlbb    %v16,0(%r2),6   /* Load s until next 4k-byte boundary.  */
        lcbb    %r1,0(%r2),6    /* Get bytes to 4k-byte boundary or 16.  */
index dd4ca46d9aca0898311ac0bc747dbbc20ea05301..af3f5cf8492f2b99f3d3240bafc189544738a210 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcschr.
+/* Vector optimized 64 bit S/390 version of wcschr.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -39,7 +39,6 @@
 */
 ENTRY(WCSCHR_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        vlbb    %v16,0(%r2),6   /* Load s until next 4k-byte boundary.  */
        lcbb    %r1,0(%r2),6    /* Get bytes to 4k-byte boundary or 16.  */
index 9d1d0b36708ada32fa54ad568abbd19f7d045fb5..0107fd5a669e8984e22e8094b6eba9237a27e5a8 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcschrnul.
+/* Vector optimized 64 bit S/390 version of wcschrnul.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -38,7 +38,6 @@
 */
 ENTRY(WCSCHRNUL_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        vlbb    %v16,0(%r2),6   /* Load s until next 4k-byte boundary.  */
        lcbb    %r1,0(%r2),6    /* Get bytes to 4k-byte boundary or 16.  */
index 39d62412d5b714ce470f3f21ac80621766e245c9..25f992e75c5d4c1d3120ac6ee5140f59d1f869a9 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcscmp.
+/* Vector optimized 64 bit S/390 version of wcscmp.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -39,7 +39,6 @@
 */
 ENTRY(WCSCMP_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        lghi    %r5,0           /* current_len = 0.  */
 
index 718fb2f9e1ba38a479f6873bf56eb2f209e55479..2aa266d2ef35a39ff5690f6080075296747eed17 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcscpy.
+/* Vector optimized 64 bit S/390 version of wcscpy.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -40,7 +40,6 @@
 */
 ENTRY(WCSCPY_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        vlbb    %v16,0(%r3),6   /* Load s until next 4k-byte boundary.  */
        lcbb    %r1,0(%r3),6    /* Get bytes to 4k-byte boundary or 16.  */
index b5b910f8bf6df39b039c4146f89870923b5cc47b..3a6fcb6e1bdc8705bc7384e19bfde08f30c9df32 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcscspn.
+/* Vector optimized 64 bit S/390 version of wcscspn.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -60,7 +60,6 @@
 */
 ENTRY(WCSCSPN_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        tmll    %r2,3           /* Test if s is 4-byte aligned?  */
        jne     .Lfallback      /* And use common-code variant if not.  */
index 29a91315215fc5efb9a1d28ef105334ae049193e..cd4459ac82ffe6ae7aee9533764eca405d0af048 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcslen.
+/* Vector optimized 64 bit S/390 version of wcslen.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -37,7 +37,6 @@
 */
 ENTRY(WCSLEN_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        vlbb    %v16,0(%r2),6   /* Load s until next 4k-byte boundary.  */
        lcbb    %r1,0(%r2),6    /* Get bytes to 4k-byte boundary or 16.  */
index 91d2a9b89decde8ea7a08bc551028e2f3a8bfdb8..155459dd5e22ff060c46dfe5e947de8766c64e6c 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcsncat.
+/* Vector optimized 64 bit S/390 version of wcsncat.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 */
 ENTRY(WCSNCAT_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__ */
 
        clgfi   %r4,0
        ber     %r14            /* Nothing to do, if n == 0.  */
@@ -123,13 +118,8 @@ ENTRY(WCSNCAT_Z13)
        lghi    %r5,0           /* current_len = 0.  */
 
        /* Check range of maxlen and convert to byte-count.  */
-# ifdef __s390x__
        tmhh    %r4,49152       /* Test bit 0 or 1 of maxlen.  */
        lghi    %r1,-4          /* Max byte-count is 18446744073709551612.  */
-# else
-       tmlh    %r4,49152       /* Test bit 0 or 1 of maxlen.  */
-       llilf   %r1,4294967292  /* Max byte-count is 4294967292.  */
-# endif /* !__s390x__ */
        sllg    %r4,%r4,2       /* Convert character-count to byte-count.  */
        locgrne %r4,%r1         /* Use max byte-count, if bit 0/1 was one.  */
 
index f01fcc56a663f9b6f03f5595de07d9f756549245..3fb375605969115da38b8ec97408b3c606051fea 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcsncmp.
+/* Vector optimized 64 bit S/390 version of wcsncmp.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 */
 ENTRY(WCSNCMP_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__ */
 
        clgije  %r4,0,.Lend_equal /* Nothing to do if n == 0.  */
 
        /* Check range of n and convert to byte-count.  */
-# ifdef __s390x__
        tmhh    %r4,49152       /* Test bit 0 or 1 of maxlen.  */
        lghi    %r1,-4          /* Max byte-count is 18446744073709551612.  */
-# else
-       tmlh    %r4,49152       /* Test bit 0 or 1 of maxlen.  */
-       llilf   %r1,4294967292  /* Max byte-count is 4294967292.  */
-# endif /* !__s390x__ */
        sllg    %r4,%r4,2       /* Convert character-count to byte-count.  */
        locgrne %r4,%r1         /* Use max byte-count, if bit 0/1 was one.  */
 
index c1d6732e878480d8dabb7fd82dc44fddbea529ff..afe14951853ff15212541808fc04a9a1165b9b40 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcsncpy.
+/* Vector optimized 64 bit S/390 version of wcsncpy.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 */
 ENTRY(WCSNCPY_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__ */
 
        clgfi   %r4,0
        ber     %r14            /* Nothing to do, if n == 0.  */
@@ -66,13 +61,8 @@ ENTRY(WCSNCPY_Z13)
        lghi    %r5,0           /* current_len = 0.  */
 
        /* Check range of maxlen and convert to byte-count.  */
-# ifdef __s390x__
        tmhh    %r4,49152       /* Test bit 0 or 1 of n.  */
        lghi    %r1,-4          /* Max byte-count is 18446744073709551612.  */
-# else
-       tmlh    %r4,49152       /* Test bit 0 or 1 of n.  */
-       llilf   %r1,4294967292  /* Max byte-count is 4294967292.  */
-# endif /* !__s390x__ */
        sllg    %r4,%r4,2       /* Convert character-count to byte-count.  */
        locgrne %r4,%r1         /* Use max byte-count, if bit 0/1 was one.  */
 
index bfff0ba2a43fc8bb2ffe066bfb449fe79b68f609..d57b3bb5b31b5098d68c76dddbe18ec496344414 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcsnlen.
+/* Vector optimized 64 bit S/390 version of wcsnlen.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 ENTRY(WCSNLEN_Z13)
 
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-
-# if !defined __s390x__
-       llgfr   %r3,%r3
-# endif /* !defined __s390x__ */
 
        clgfi   %r3,0           /* if maxlen == 0, return 0.  */
        locgre  %r2,%r3
@@ -56,13 +51,8 @@ ENTRY(WCSNLEN_Z13)
        jne     .Lfallback      /* And use common-code variant if not.  */
 
        /* Check range of maxlen and convert to byte-count.  */
-# ifdef __s390x__
        tmhh    %r3,49152       /* Test bit 0 or 1 of maxlen.  */
        lghi    %r4,-4          /* Max byte-count is 18446744073709551612.  */
-# else
-       tmlh    %r3,49152       /* Test bit 0 or 1 of maxlen.  */
-       llilf   %r4,4294967292  /* Max byte-count is 4294967292.  */
-# endif /* !__s390x__ */
        sllg    %r3,%r3,2       /* Convert character-count to byte-count.  */
        locgrne %r3,%r4         /* Use max byte-count, if bit 0/1 was one.  */
 
index d1c0b2b47db8be1280601acbfd3c68122d6b1792..d97b2c02f1ebc0867464b072999cd55dbae385f6 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcspbrk.
+/* Vector optimized 64 bit S/390 version of wcspbrk.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -62,7 +62,6 @@
 */
 ENTRY(WCSPBRK_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        tmll    %r2,3           /* Test if s is 4-byte aligned?  */
        jne     .Lfallback      /* And use common-code variant if not.  */
index 9e5f4ceea3ec6ef769ffcd0b7fa7922949e020dd..4e9934f01e17d217d25883441eb247da8c02e291 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcsrchr.
+/* Vector optimized 64 bit S/390 version of wcsrchr.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -42,7 +42,6 @@
 */
 ENTRY(WCSRCHR_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        vlbb    %v16,0(%r2),6   /* Load s until next 4k-byte boundary.  */
        lcbb    %r0,0(%r2),6    /* Get bytes to 4k-byte boundary or 16.  */
index 81d7ccb101715dc3296e27de4d60effccdd6e5b5..bdd316950d7731c47b84de497cad58aa54aaa055 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wcsspn.
+/* Vector optimized 64 bit S/390 version of wcsspn.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -60,7 +60,6 @@
 */
 ENTRY(WCSSPN_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
 
        tmll    %r2,3           /* Test if s is 4-byte aligned?  */
        jne     .Lfallback      /* And use common-code variant if not.  */
index 6882395ce76a2edac0ef9cf694b098f958818bad..2040ee8ebae071aabc827bfbfdf1dbead03433bb 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector optimized 32/64 bit S/390 version of wmemchr.
+/* Vector optimized 64 bit S/390 version of wmemchr.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 */
 ENTRY(WMEMCHR_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__ */
 
        clgije  %r4,0,.Lnf_end  /* If len == 0 then exit.  */
 
@@ -61,13 +56,8 @@ ENTRY(WMEMCHR_Z13)
        lghi    %r5,16          /* current_len = 16.  */
 
        /* Check range of maxlen and convert to byte-count.  */
-# ifdef __s390x__
        tmhh    %r4,49152       /* Test bit 0 or 1 of maxlen.  */
        lghi    %r1,-4          /* Max byte-count is 18446744073709551612.  */
-# else
-       tmlh    %r4,49152       /* Test bit 0 or 1 of maxlen.  */
-       llilf   %r1,4294967292  /* Max byte-count is 4294967292.  */
-# endif /* !__s390x__ */
        sllg    %r4,%r4,2       /* Convert character-count to byte-count.  */
        locgrne %r4,%r1         /* Use max byte-count, if bit 0/1 was one.  */
 
index 3d07b815a09d732ba1a65159fd345488a6563237..6a2997d74b592e1b57ccf763e8a7b49d193aea27 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector Optimized 32/64 bit S/390 version of wmemcmp.
+/* Vector Optimized 64 bit S/390 version of wmemcmp.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 */
 ENTRY(WMEMCMP_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__ */
        clgije  %r4,0,.Lend_equal /* Nothing to do if n == 0.  */
 
        /* Check range of maxlen and convert to byte-count.  */
-# ifdef __s390x__
        tmhh    %r4,49152       /* Test bit 0 or 1 of maxlen.  */
        lghi    %r1,-4          /* Max byte-count is 18446744073709551612.  */
-# else
-       tmlh    %r4,49152       /* Test bit 0 or 1 of maxlen.  */
-       llilf   %r1,4294967292  /* Max byte-count is 4294967292.  */
-# endif /* !__s390x__ */
        sllg    %r4,%r4,2       /* Convert character-count to byte-count.  */
        locgrne %r4,%r1         /* Use max byte-count, if bit 0/1 was one.  */
 
index 4f3661297cebf83cee34b28abd13891746ea64cc..f7ab5dd8c70b3d6e14574c96b46a77a8cdffe8fd 100644 (file)
@@ -1,4 +1,4 @@
-/* Vector Optimized 32/64 bit S/390 version of wmemset.
+/* Vector Optimized 64 bit S/390 version of wmemset.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
 */
 ENTRY(WMEMSET_Z13)
        .machine "z13"
-       .machinemode "zarch_nohighgprs"
-
-# if !defined __s390x__
-       llgfr   %r4,%r4
-# endif /* !defined __s390x__ */
 
        vlvgg   %v31,%r2,0      /* Save destination pointer for return.  */
        clgije  %r4,0,.Lend
@@ -54,13 +49,8 @@ ENTRY(WMEMSET_Z13)
        vrepf   %v16,%v16,0
 
        /* Check range of maxlen and convert to byte-count.  */
-# ifdef __s390x__
        tmhh    %r4,49152       /* Test bit 0 or 1 of maxlen.  */
        lghi    %r5,-4          /* Max byte-count is 18446744073709551612.  */
-# else
-       tmlh    %r4,49152       /* Test bit 0 or 1 of maxlen.  */
-       llilf   %r5,4294967292  /* Max byte-count is 4294967292.  */
-# endif /* !__s390x__ */
        sllg    %r4,%r4,2       /* Convert character-count to byte-count.  */
        locgrne %r4,%r5         /* Use max byte-count, if bit 0/1 was one.  */
 
index 2b45a31c2d1fdde1c784f082bd7c071bfcb08d6d..a034345ee3753e8d91dd27fcade5c0d038c977be 100644 (file)
@@ -43,7 +43,7 @@ __fxstat (int vers, int fd, struct stat *buf)
        return r ?: stat_overflow (buf);
 # else
        /* Old kABIs with old non-LFS support, e.g. arm, i386, hppa, m68k,
-          microblaze, s390, sh, powerpc, and sparc.  */
+          microblaze, sh, powerpc, and sparc.  */
        return INLINE_SYSCALL_CALL (fstat, fd, buf);
 # endif
       }
index 8f4dcdd3a96d621066b329d5fa6203a42dc58d0b..12d743f61e624bb43f5fa983a44c2eb7ac63df56 100644 (file)
@@ -43,7 +43,7 @@ __fxstatat (int vers, int fd, const char *file, struct stat *st, int flag)
   return INLINE_SYSCALL_ERROR_RETURN_VALUE (EINVAL);
 #else
   /* Old kABIs with old non-LFS support, e.g. arm, i386, hppa, m68k, mips32,
-     microblaze, s390, sh, powerpc32, and sparc32.  */
+     microblaze, sh, powerpc32, and sparc32.  */
   struct stat64 st64;
   int r = INLINE_SYSCALL_CALL (fstatat64, fd, file, &st64, flag);
   return r ?: __xstat32_conv (vers, &st64, st);
index 24f6867e0ed1818c70630ea933143f47000681ce..2b75a49b1eaf376fb42d1ea822e88bc8b1c4dfe6 100644 (file)
@@ -48,8 +48,8 @@ struct __old_ipc_perm
 #define MSGRCV_ARGS(__msgp, __msgtyp) \
   ((long int []){ (long int) __msgp, __msgtyp })
 
-/* This macro is required to handle the s390 variants, which passes the
-   arguments in a different order than default.  */
+/* This macro is required to handle s390x, which passes the arguments in a
+   different order than default.  */
 #define SEMTIMEDOP_IPC_ARGS(__nsops, __sops, __timeout) \
   (__nsops), 0, (__sops), (__timeout)
 
index 94bdbbb730aeb21ff009263895f4718f52174cfc..85f6e888dba58fe7e4b27fc594d80e02092187f6 100644 (file)
    similar to kernel:
 
    - __ASSUME_CLONE_BACKWARDS: for variant 1.
-   - __ASSUME_CLONE_BACKWARDS2: for variant 2 (s390).
+   - __ASSUME_CLONE_BACKWARDS2: for variant 2 (s390x).
    - __ASSUME_CLONE_BACKWARDS3: for variant 3 (microblaze).
    - __ASSUME_CLONE_DEFAULT: for variant 4.
    */
index a65e2715a8328f50ab966586d07a894f8da11d69..6efe1698bc76f730e66dad3819d9ffba0ef6ebca 100644 (file)
@@ -44,7 +44,7 @@ __lxstat (int vers, const char *name, struct stat *buf)
        return r ?: stat_overflow (buf);
 # else
        /* Old kABIs with old non-LFS support, e.g. arm, i386, hppa, m68k,
-          microblaze, s390, sh, powerpc, and sparc.  */
+          microblaze, sh, powerpc, and sparc.  */
        return INLINE_SYSCALL_CALL (lstat, name, buf);
 # endif
       }
index 22b0bedbf1246492a82fb90b7df05d8cd89d9e22..e743aaec4aa65838bd5032719d1fcb505d8c48cd 100644 (file)
@@ -75,7 +75,7 @@ ___lxstat64 (int vers, const char *name, struct stat64 *buf)
                                AT_SYMLINK_NOFOLLOW);
 # else
   /* Old kABIs with old non-LFS support, e.g. arm, i386, hppa, m68k,
-     microblaze, s390, sh, mips32, powerpc32, and sparc32.  */
+     microblaze, sh, mips32, powerpc32, and sparc32.  */
   return INLINE_SYSCALL_CALL (lstat64, name, buf);
 # endif /* STAT_IS_KERNEL_STAT  */
 #endif /* XSTAT_IS_XSTAT64  */
index b62cf8c002ae5085e8e351147e840841730b9f84..01c450de31e3e041cb4f09695297ef19be34d924 100644 (file)
    __NR_fadvise64_64 (without the alignment argument required for the ABI).
 
    Third option will be used by mips o32.  Mips will use a 7 argument
-   syscall with __NR_fadvise64.
-
-   s390 implements fadvice64_64 using a specific struct with arguments
-   packed inside.  This is the only implementation handled in arch-specific
-   code.  */
+   syscall with __NR_fadvise64.  */
 
 int
 posix_fadvise (int fd, off_t offset, off_t len, int advise)
index 56748fd7fe90f1d299ba4fc21a29119d6bc93a0d..b19b5deb560b91cb7f45c4ba4df022c5d7dbaa70 100644 (file)
@@ -25,11 +25,7 @@ libc_hidden_proto (__posix_fadvise64_l64)
 
 /* Both arm and powerpc implements fadvise64_64 with last 'advise' argument
    just after 'fd' to avoid the requirement of implementing 7-arg syscalls.
-   ARM also defines __NR_fadvise64_64 as __NR_arm_fadvise64_64.
-
-   s390 implements fadvice64_64 using a specific struct with arguments
-   packed inside.  This is the only implementation handled in arch-specific
-   code.  */
+   ARM also defines __NR_fadvise64_64 as __NR_arm_fadvise64_64.  */
 
 #ifndef __NR_fadvise64_64
 # define __NR_fadvise64_64 __NR_fadvise64
index d5433f1dd9a434d5f27cf9b33e0b2370c1db1f8e..218aff1aeedc353404f8b61d20386168c3f1de9a 100644 (file)
@@ -1,7 +1,3 @@
-abi-variants := 32 64
-abi-32-condition := __WORDSIZE == 32
-abi-64-condition := __WORDSIZE == 64
-
 ifeq ($(subdir),rt)
 librt-routines += rt-sysdep
 librt-shared-only-routines += rt-sysdep
index 723aa1189aae22e61e7540ef2a15126eff005d24..59de7fbef6a66a9db3dcf378976136b83a831528 100644 (file)
 
 #define __ELF_NATIVE_CLASS __WORDSIZE
 
-#if __WORDSIZE == 64
 /* 64 bit Linux for S/390 is exceptional as it has .hash section with
    64 bit entries.  */
 typedef uint64_t Elf_Symndx;
-#else
-/* 32 bit Linux for S/390 has normal .hash section entries with 32 bits.  */
-typedef uint32_t Elf_Symndx;
-#endif
index 75ea4e23c6e83ecd910cb7e69b02ca5abccba10f..0531f13efd66e432d8e99d400c252a66b7456183 100644 (file)
 
 #include <bits/wordsize.h>
 
-#if __WORDSIZE == 64
 /* Not necessary, files are always with 64bit off_t.  */
-# define __O_LARGEFILE 0
-#endif
+#define __O_LARGEFILE  0
 
-#if __WORDSIZE == 64
 /* Not necessary, we always have 64-bit offsets.  */
-# define F_GETLK64     5       /* Get record locking info.  */
-# define F_SETLK64     6       /* Set record locking info (non-blocking).  */
-# define F_SETLKW64    7       /* Set record locking info (blocking).  */
-#endif
+#define F_GETLK64      5       /* Get record locking info.  */
+#define F_SETLK64      6       /* Set record locking info (non-blocking).  */
+#define F_SETLKW64     7       /* Set record locking info (blocking).  */
 
 struct flock
   {
     short int l_type;  /* Type of lock: F_RDLCK, F_WRLCK, or F_UNLCK.  */
     short int l_whence;        /* Where `l_start' is relative to (like `lseek').  */
-#if __WORDSIZE == 64 || !defined __USE_FILE_OFFSET64
     __off_t l_start;   /* Offset where the lock begins.  */
     __off_t l_len;     /* Size of the locked area; zero means until EOF.  */
-#else
-    __off64_t l_start; /* Offset where the lock begins.  */
-    __off64_t l_len;   /* Size of the locked area; zero means until EOF.  */
-#endif
     __pid_t l_pid;     /* Process holding the lock.  */
   };
 
@@ -59,13 +50,8 @@ struct flock64
   };
 #endif
 
-#if __WORDSIZE == 64
-# define __POSIX_FADV_DONTNEED 6 /* Don't need these pages.  */
-# define __POSIX_FADV_NOREUSE  7 /* Data will be accessed once.  */
-#else
-# define __POSIX_FADV_DONTNEED 4 /* Don't need these pages.  */
-# define __POSIX_FADV_NOREUSE  5 /* Data will be accessed once.  */
-#endif
+#define __POSIX_FADV_DONTNEED  6 /* Don't need these pages.  */
+#define __POSIX_FADV_NOREUSE   7 /* Data will be accessed once.  */
 
 /* Include generic Linux declarations.  */
 #include <bits/fcntl-linux.h>
index 7f761808dcf0f91805739b655acc0432c0331419..19cdb14c328710f200ff5d10c267d54d3fa46d66 100644 (file)
@@ -1,4 +1,4 @@
-/* Definitions for 31 & 64 bit S/390 sigaction.
+/* Definitions for 64 bit S/390 sigaction.
    Copyright (C) 2001-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -23,9 +23,6 @@
 # error "Never include <bits/sigaction.h> directly; use <signal.h> instead."
 #endif
 
-#include <bits/wordsize.h>
-
-#if __WORDSIZE == 64
 /* Structure describing the action to be taken when a signal arrives.  */
 struct sigaction
   {
@@ -55,36 +52,6 @@ struct sigaction
     /* Additional set of signals to be blocked.         */
     __sigset_t sa_mask;
   };
-#else
-/* Structure describing the action to be taken when a signal arrives.  */
-struct sigaction
-  {
-    /* Signal handler.  */
-#if defined __USE_POSIX199309 || defined __USE_XOPEN_EXTENDED
-    union
-      {
-       /* Used if SA_SIGINFO is not set.  */
-       __sighandler_t sa_handler;
-       /* Used if SA_SIGINFO is set.  */
-       void (*sa_sigaction) (int, siginfo_t *, void *);
-      }
-    __sigaction_handler;
-# define sa_handler    __sigaction_handler.sa_handler
-# define sa_sigaction  __sigaction_handler.sa_sigaction
-#else
-    __sighandler_t sa_handler;
-#endif
-
-    /* Additional set of signals to be blocked.  */
-    __sigset_t sa_mask;
-
-    /* Special flags.  */
-    int sa_flags;
-
-    /* Restore handler.  */
-    void (*sa_restorer) (void);
-  };
-#endif
 
 /* Bits in `sa_flags'.  */
 #define        SA_NOCLDSTOP  1          /* Don't send SIGCHLD when children stop.  */
index e98192d7ef1aeabab592ccad665458499f7ef004..f6a3a785a1d33b6c37f240d12d7e0f0870029649 100644 (file)
@@ -25,7 +25,6 @@
 
 #include <bits/wordsize.h>
 
-#if __WORDSIZE == 64
 struct stat
   {
     __dev_t st_dev;            /* Device.  */
@@ -62,70 +61,8 @@ struct stat
     __blkcnt_t st_blocks;      /* Nr. 512-byte blocks allocated.  */
     long int __glibc_reserved[3];
   };
-#else
-struct stat
-  {
-# ifdef __USE_TIME64_REDIRECTS
-#  include <bits/struct_stat_time64_helper.h>
-# else
-    __dev_t st_dev;                    /* Device.  */
-    unsigned int __pad1;
-#  ifndef __USE_FILE_OFFSET64
-    __ino_t st_ino;                    /* File serial number.  */
-#  else
-    __ino_t __st_ino;                  /* 32bit file serial number.    */
-#  endif
-    __mode_t st_mode;                  /* File mode.  */
-    __nlink_t st_nlink;                        /* Link count.  */
-    __uid_t st_uid;                    /* User ID of the file's owner. */
-    __gid_t st_gid;                    /* Group ID of the file's group.*/
-    __dev_t st_rdev;                   /* Device number, if device.  */
-    unsigned int __pad2;
-#  ifndef __USE_FILE_OFFSET64
-    __off_t st_size;                   /* Size of file, in bytes.  */
-#  else
-    __off64_t st_size;                 /* Size of file, in bytes.  */
-#  endif
-    __blksize_t st_blksize;            /* Optimal block size for I/O.  */
-
-#  ifndef __USE_FILE_OFFSET64
-    __blkcnt_t st_blocks;              /* Number 512-byte blocks allocated. */
-#  else
-    __blkcnt64_t st_blocks;            /* Number 512-byte blocks allocated. */
-#  endif
-#  ifdef __USE_XOPEN2K8
-    /* Nanosecond resolution timestamps are stored in a format
-       equivalent to 'struct timespec'.  This is the type used
-       whenever possible but the Unix namespace rules do not allow the
-       identifier 'timespec' to appear in the <sys/stat.h> header.
-       Therefore we have to handle the use of this header in strictly
-       standard-compliant sources special.  */
-    struct timespec st_atim;           /* Time of last access.  */
-    struct timespec st_mtim;           /* Time of last modification.  */
-    struct timespec st_ctim;           /* Time of last status change.  */
-#   define st_atime st_atim.tv_sec     /* Backward compatibility.  */
-#   define st_mtime st_mtim.tv_sec
-#   define st_ctime st_ctim.tv_sec
-#  else
-    __time_t st_atime;                 /* Time of last access.  */
-    unsigned long int st_atimensec;    /* Nscecs of last access.  */
-    __time_t st_mtime;                 /* Time of last modification.  */
-    unsigned long int st_mtimensec;    /* Nsecs of last modification.  */
-    __time_t st_ctime;                 /* Time of last status change.  */
-    unsigned long int st_ctimensec;    /* Nsecs of last status change.  */
-#  endif
-#  ifndef __USE_FILE_OFFSET64
-    unsigned long int __glibc_reserved4;
-    unsigned long int __glibc_reserved5;
-#  else
-    __ino64_t st_ino;                  /* File serial number.  */
-#  endif
-# endif
-  };
-# endif
 
 #ifdef __USE_LARGEFILE64
-# if __WORDSIZE == 64
 /* Note stat64 is the same shape as stat.  */
 struct stat64
   {
@@ -138,7 +75,7 @@ struct stat64
     int __glibc_reserved0;
     __dev_t st_rdev;           /* Device number, if device.  */
     __off_t st_size;           /* Size of file, in bytes.  */
-#  ifdef __USE_XOPEN2K8
+# ifdef __USE_XOPEN2K8
     /* Nanosecond resolution timestamps are stored in a format
        equivalent to 'struct timespec'.  This is the type used
        whenever possible but the Unix namespace rules do not allow the
@@ -148,66 +85,21 @@ struct stat64
     struct timespec st_atim;           /* Time of last access.  */
     struct timespec st_mtim;           /* Time of last modification.  */
     struct timespec st_ctim;           /* Time of last status change.  */
-#   define st_atime st_atim.tv_sec     /* Backward compatibility.  */
-#   define st_mtime st_mtim.tv_sec
-#   define st_ctime st_ctim.tv_sec
-#  else
+#  define st_atime st_atim.tv_sec      /* Backward compatibility.  */
+#  define st_mtime st_mtim.tv_sec
+#  define st_ctime st_ctim.tv_sec
+# else
     __time_t st_atime;                 /* Time of last access.  */
     unsigned long int st_atimensec;    /* Nscecs of last access.  */
     __time_t st_mtime;                 /* Time of last modification.  */
     unsigned long int st_mtimensec;    /* Nsecs of last modification.  */
     __time_t st_ctime;                 /* Time of last status change.  */
     unsigned long int st_ctimensec;    /* Nsecs of last status change.  */
-#  endif
+# endif
     __blksize_t st_blksize;    /* Optimal block size for I/O.  */
     __blkcnt64_t st_blocks;    /* Nr. 512-byte blocks allocated.  */
     long int __glibc_reserved[3];
   };
-# else
-struct stat64
-  {
-#  ifdef __USE_TIME64_REDIRECTS
-#   include <bits/struct_stat_time64_helper.h>
-#  else
-    __dev_t st_dev;                    /* Device.  */
-    unsigned int __pad1;
-
-    __ino_t __st_ino;                  /* 32bit file serial number.    */
-    __mode_t st_mode;                  /* File mode.  */
-    __nlink_t st_nlink;                        /* Link count.  */
-    __uid_t st_uid;                    /* User ID of the file's owner. */
-    __gid_t st_gid;                    /* Group ID of the file's group.*/
-    __dev_t st_rdev;                   /* Device number, if device.  */
-    unsigned int __pad2;
-    __off64_t st_size;                 /* Size of file, in bytes.  */
-    __blksize_t st_blksize;            /* Optimal block size for I/O.  */
-
-    __blkcnt64_t st_blocks;            /* Number 512-byte blocks allocated. */
-#   ifdef __USE_XOPEN2K8
-    /* Nanosecond resolution timestamps are stored in a format
-       equivalent to 'struct timespec'.  This is the type used
-       whenever possible but the Unix namespace rules do not allow the
-       identifier 'timespec' to appear in the <sys/stat.h> header.
-       Therefore we have to handle the use of this header in strictly
-       standard-compliant sources special.  */
-    struct timespec st_atim;           /* Time of last access.  */
-    struct timespec st_mtim;           /* Time of last modification.  */
-    struct timespec st_ctim;           /* Time of last status change.  */
-#    define st_atime st_atim.tv_sec    /* Backward compatibility.  */
-#    define st_mtime st_mtim.tv_sec
-#    define st_ctime st_ctim.tv_sec
-#   else
-    __time_t st_atime;                 /* Time of last access.  */
-    unsigned long int st_atimensec;    /* Nscecs of last access.  */
-    __time_t st_mtime;                 /* Time of last modification.  */
-    unsigned long int st_mtimensec;    /* Nsecs of last modification.  */
-    __time_t st_ctime;                 /* Time of last status change.  */
-    unsigned long int st_ctimensec;    /* Nsecs of last status change.  */
-#   endif
-    __ino64_t st_ino;                  /* File serial number.          */
-#  endif
-  };
-# endif
 #endif
 
 /* Tell code we have these members.  */
index 826a1e425c1a2b3b1ee712643d53284412275bfa..6e2be2270f3ef2352418c9ca49af32ecd9e1f9ca 100644 (file)
 #define __TIMER_T_TYPE         void *
 #define __BLKSIZE_T_TYPE       __SLONGWORD_TYPE
 #define __FSID_T_TYPE          struct { int __val[2]; }
-#if defined __GNUC__ && __GNUC__ <= 2
-/* Compatibility with g++ 2.95.x.  */
-#define __SSIZE_T_TYPE         __SWORD_TYPE
-#else
-/* size_t is unsigned long int on s390 -m31.  */
-#define __SSIZE_T_TYPE         __SLONGWORD_TYPE
-#endif
+
+/* With s390-32, __SSIZE_T_TYPE was __SWORD_TYPE for compatibility with
+   g++ 2.95.x.  Afterwards __SLONGWORD_TYPE was needed as size_t was
+   unsigned long int on s390-32.
+   Now as only s390-64 exists, __SWORD_TYPE can be used as also used in the
+   generic version as both types result in long int.  */
+#define __SSIZE_T_TYPE         __SWORD_TYPE
+
 #define __SYSCALL_SLONG_TYPE   __SLONGWORD_TYPE
 #define __SYSCALL_ULONG_TYPE   __ULONGWORD_TYPE
-#define __CPU_MASK_TYPE        __ULONGWORD_TYPE
+#define __CPU_MASK_TYPE                __ULONGWORD_TYPE
 
-#ifdef __s390x__
 /* Tell the libc code that off_t and off64_t are actually the same type
    for all ABI purposes, even if possibly expressed as different base types
    for C type-checking purposes.  */
-# define __OFF_T_MATCHES_OFF64_T       1
+#define __OFF_T_MATCHES_OFF64_T        1
 
 /* Same for ino_t and ino64_t.  */
-# define __INO_T_MATCHES_INO64_T       1
+#define __INO_T_MATCHES_INO64_T        1
 
 /* And for __rlim_t and __rlim64_t.  */
-# define __RLIM_T_MATCHES_RLIM64_T     1
+#define __RLIM_T_MATCHES_RLIM64_T      1
 
 /* And for fsblkcnt_t, fsblkcnt64_t, fsfilcnt_t and fsfilcnt64_t.  */
-# define __STATFS_MATCHES_STATFS64  1
+#define __STATFS_MATCHES_STATFS64  1
 
 /* And for getitimer, setitimer and rusage  */
-# define __KERNEL_OLD_TIMEVAL_MATCHES_TIMEVAL64 1
-#else
-# define __RLIM_T_MATCHES_RLIM64_T     0
-
-# define __STATFS_MATCHES_STATFS64  0
-
-/* And for getitimer, setitimer and rusage  */
-# define __KERNEL_OLD_TIMEVAL_MATCHES_TIMEVAL64 0
-#endif
+#define __KERNEL_OLD_TIMEVAL_MATCHES_TIMEVAL64 1
 
 /* Number of descriptors that can fit in an `fd_set'.  */
 #define        __FD_SETSIZE            1024
index a955c18738ad557e51a261b279eb2e3111870924..d7af29285fc538b2deda44f9aab98e5fcb60fef1 100644 (file)
@@ -47,9 +47,6 @@
 # undef __ASSUME_DIRECT_SYSVIPC_SYSCALLS
 # undef __ASSUME_SYSVIPC_DEFAULT_IPC_64
 #endif
-#ifndef __s390x__
-# define __ASSUME_SYSVIPC_BROKEN_MODE_T
-#endif
 
 #undef __ASSUME_CLONE_DEFAULT
 #define __ASSUME_CLONE_BACKWARDS2
index 6229b705d228c12f090a25c805569008d134d395..87e900f5365ad4ecf8a2576bf7ef6b4acaa41075 100644 (file)
@@ -16,9 +16,6 @@
    <https://www.gnu.org/licenses/>.  */
 
 
-int process_elf32_file (const char *file_name, const char *lib,
-                       int *flag, unsigned int *isa_level, char **soname,
-                       void *file_contents, size_t file_length);
 int process_elf64_file (const char *file_name, const char *lib,
                        int *flag, unsigned int *isa_level, char **soname,
                        void *file_contents, size_t file_length);
@@ -29,29 +26,15 @@ process_elf_file (const char *file_name, const char *lib, int *flag,
                  unsigned int *isa_level, char **soname, void *file_contents,
                  size_t file_length)
 {
-  ElfW(Ehdr) *elf_header = (ElfW(Ehdr) *) file_contents;
-  int ret;
-
-  if (elf_header->e_ident [EI_CLASS] == ELFCLASS32)
-    return process_elf32_file (file_name, lib, flag, isa_level, soname,
-                              file_contents, file_length);
-  else
-    {
-      ret = process_elf64_file (file_name, lib, flag, isa_level, soname,
-                               file_contents, file_length);
-      /* S/390 64bit libraries are always libc.so.6+.  */
-      if (!ret)
-       *flag = FLAG_S390_LIB64|FLAG_ELF_LIBC6;
-      return ret;
-    }
+  int ret = process_elf64_file (file_name, lib, flag, isa_level, soname,
+                               file_contents, file_length);
+  /* S/390 64bit libraries are always libc.so.6+ which is already set
+     in process_elf64_file.  */
+  if (!ret)
+    *flag |= FLAG_S390_LIB64;
+  return ret;
 }
 
-#undef __ELF_NATIVE_CLASS
-#undef process_elf_file
-#define process_elf_file process_elf32_file
-#define __ELF_NATIVE_CLASS 32
-#include "elf/readelflib.c"
-
 #undef __ELF_NATIVE_CLASS
 #undef process_elf_file
 #define process_elf_file process_elf64_file
index 679573474734ad1fbadf54776de4eebfbd739859..0c338cba36586ef19f6a3130c5aa885368d00ce5 100644 (file)
@@ -1,6 +1,3 @@
-# See Makeconfig regarding the use of default-abi.
-default-abi := 64
-
 ifeq ($(subdir),misc)
 sysdep_headers += sys/elf.h
 endif
index 08679ffc82b5fe689fdbf1258df8bdbf2dab325e..ac1fc28dc3eba13296fabe25b1b3f8d932c5b413 100644 (file)
 static inline uintptr_t
 sigcontext_get_pc (const ucontext_t *ctx)
 {
-#ifdef __s390x__
  return ctx->uc_mcontext.psw.addr;
-#else
- return ctx->uc_mcontext.psw.addr & 0x7FFFFFFF;
-#endif
 }
 
 #endif
index 1d4d979b6c1fb1603773acf5d30bff2af13796f2..3bbddd08bac3b2de10fc48802eaeaae8a4296a71 100644 (file)
@@ -45,11 +45,7 @@ typedef unsigned long greg_t;
    the register set is an array, we make gregset_t a simple array
    that has the same size as s390_regs.  This is needed for the
    elf_prstatus structure.  */
-#if __WORDSIZE == 64
-# define __NGREG 27
-#else
-# define __NGREG 36
-#endif
+#define __NGREG 27
 #ifdef __USE_MISC
 # define NGREG __NGREG
 #endif
index 7083b637370ce7143b92734f32221a6c1df658de..57ccaed4e39dd2ccb842f88a7a2e0ae3add35764 100644 (file)
@@ -1,4 +1,4 @@
-/* Get system parameters, e.g. cache information.  S390/S390x version.
+/* Get system parameters, e.g. cache information.  S390x version.
    Copyright (C) 2015-2026 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -50,14 +50,9 @@ get_cache_info (int level, int attr, int type)
 
   /* Check if ecag-instruction is available.
      ecag - extract CPU attribute (only in zarch; arch >= z10; in as 2.24)  */
-  if (!(features->hwcap & HWCAP_S390_STFLE)
-#if !defined __s390x__
-      || !(features->hwcap & HWCAP_S390_ZARCH)
-      || !(features->hwcap & HWCAP_S390_HIGH_GPRS)
-#endif /* !__s390x__ */
-      )
+  if (!(features->hwcap & HWCAP_S390_STFLE))
     {
-      /* stfle (or zarch, high-gprs on s390-32) is not available.
+      /* stfle is not available.
         We are on an old machine. Return 256byte for LINESIZE for L1 d/i-cache,
         otherwise 0.  */
       if (level == 1 && attr == CACHE_ATTR_LINESIZE)
@@ -81,7 +76,6 @@ get_cache_info (int level, int attr, int type)
   arg = (CACHE_LEVEL_MAX - level) * 8;
   __asm__ __volatile__ (".machine push\n\t"
                        ".machine \"z10\"\n\t"
-                       ".machinemode \"zarch_nohighgprs\"\n\t"
                        "ecag %0,%%r0,0\n\t"   /* returns 64bit unsigned integer.  */
                        "srlg %0,%0,0(%1)\n\t" /* right align 8bit cache info field.  */
                        ".machine pop"
@@ -97,7 +91,6 @@ get_cache_info (int level, int attr, int type)
   cmd = (attr << 4) | ((level - 1) << 1) | type;
   __asm__ __volatile__ (".machine push\n\t"
                        ".machine \"z10\"\n\t"
-                       ".machinemode \"zarch_nohighgprs\"\n\t"
                        "ecag %0,%%r0,0(%1)\n\t"
                        ".machine pop"
                        : "=d" (val)
index ee2d92edff1f0ee2fb8e0a25217e35dccbd0ff30..593e70dc1ea85964c26bea831e0636e0ca89ca3b 100644 (file)
 #define VDSO_HASH  123718585
 
 /* List of system calls which are supported as vsyscalls.  */
-#ifdef __s390x__
 #define HAVE_CLOCK_GETRES64_VSYSCALL   "__kernel_clock_getres"
 #define HAVE_CLOCK_GETTIME64_VSYSCALL  "__kernel_clock_gettime"
 #define HAVE_GETRANDOM_VSYSCALL                "__kernel_getrandom"
-#else
-#define HAVE_CLOCK_GETRES_VSYSCALL     "__kernel_clock_getres"
-#define HAVE_CLOCK_GETTIME_VSYSCALL    "__kernel_clock_gettime"
-#endif
 #define HAVE_GETTIMEOFDAY_VSYSCALL     "__kernel_gettimeofday"
 #define HAVE_GETCPU_VSYSCALL           "__kernel_getcpu"
 
index 9923199e407ccd8c3c341695841bcc07802c0189..f24ab4a9ee158d7f0890cd228b20bf1e278d332b 100644 (file)
@@ -1,19 +1,10 @@
 /* Versions of the 'struct stat' data structure used in compatibility xstat
    functions.  */
-
-#include <bits/wordsize.h>
-
-#if __WORDSIZE == 64
-# define _STAT_VER_KERNEL      0
-# define _STAT_VER_LINUX       1
-# define _MKNOD_VER_LINUX      0
-#else
-# define _STAT_VER_LINUX_OLD   1
-# define _STAT_VER_KERNEL      1
-# define _STAT_VER_SVR4                2
-# define _STAT_VER_LINUX       3
-# define _MKNOD_VER_LINUX      1
-# define _MKNOD_VER_SVR4       2
-#endif
+#define _STAT_VER_KERNEL       0
+#define _STAT_VER_LINUX                1
 #define _STAT_VER              _STAT_VER_LINUX
+
+/* Versions of the 'xmknod' interface used in compatibility xmknod
+   functions.  */
+#define _MKNOD_VER_LINUX       0
 #define _MKNOD_VER             _MKNOD_VER_LINUX
index f9cdde322281137a1cb89389676262c1a954cd1d..0947fff1576d3d4612fd57a1a28907a61d243416 100644 (file)
@@ -41,9 +41,9 @@ do_prepare (int argc, char **argv)
 
 /* Linux between 4.13 and 4.15 return EOVERFLOW for LFS OFD locks usage
    in compat mode (non-LFS ABI running on a LFS default kernel, such as
-   i386 on a x86_64 kernel or s390-32 on a s390-64 kernel) [1].  This is
-   a kernel issue because __NR_fcntl64 is the expected way to use OFD locks
-   (used on GLIBC for both fcntl and fcntl64).
+   i386 on a x86_64 kernel) [1].  This is a kernel issue because __NR_fcntl64
+   is the expected way to use OFD locks (used on GLIBC for both fcntl and
+   fcntl64).
 
    [1] https://sourceware.org/ml/libc-alpha/2018-07/msg00243.html  */
 
index a67139cafaa385a0ffea8193caef1d46f3e7c2ba..33863c3cb7acab25fa69d783e1292d705a0de20e 100644 (file)
@@ -43,7 +43,7 @@ __xstat (int vers, const char *name, struct stat *buf)
        return r ?: stat_overflow (buf);
 # else
        /* Old kABIs with old non-LFS support, e.g. arm, i386, hppa, m68k,
-          microblaze, s390, sh, powerpc, and sparc32.  */
+          microblaze, sh, powerpc, and sparc32.  */
        return INLINE_SYSCALL_CALL (stat, name, buf);
 # endif
       }
index 8baa8214bcbe3cf54e9a98b88eda258c97e3c003..7d513e4af0dff0e773f40df2f1769e0bd8706f6b 100644 (file)
@@ -72,7 +72,7 @@ ___xstat64 (int vers, const char *name, struct stat64 *buf)
     return INLINE_SYSCALL_CALL (fstatat64, AT_FDCWD, name, buf, 0);
 # else
   /* Old kABIs with old non-LFS support, e.g. arm, i386, hppa, m68k,
-     microblaze, s390, sh, mips32, powerpc32, and sparc32.  */
+     microblaze, sh, mips32, powerpc32, and sparc32.  */
   return INLINE_SYSCALL_CALL (stat64, name, buf);
 # endif /* STAT_IS_KERNEL_STAT  */
 #endif /* XSTAT_IS_XSTAT64  */