forked from rpms/glibc
73667d0be6
* Thu Apr 28 2022 Carlos O'Donell <carlos@redhat.com> - 2.34-32 - Sync with upstream branch release/2.34/master, commit c66c92181ddbd82306537a608e8c0282587131de: - posix/glob.c: update from gnulib (BZ#25659) - linux: Fix fchmodat with AT_SYMLINK_NOFOLLOW for 64 bit time_t (BZ#29097) * Wed Apr 27 2022 Carlos O'Donell <carlos@redhat.com> - 2.34-31 - Sync with upstream branch release/2.34/master, commit 55640ed3fde48360a8e8083be4843bd2dc7cecfe: - i386: Regenerate ulps - linux: Fix missing internal 64 bit time_t stat usage - x86: Optimize L(less_vec) case in memcmp-evex-movbe.S - x86: Don't set Prefer_No_AVX512 for processors with AVX512 and AVX-VNNI - x86-64: Use notl in EVEX strcmp [BZ #28646] - x86: Shrink memcmp-sse4.S code size - x86: Double size of ERMS rep_movsb_threshold in dl-cacheinfo.h - x86: Optimize memmove-vec-unaligned-erms.S - x86-64: Replace movzx with movzbl - x86-64: Remove Prefer_AVX2_STRCMP - x86-64: Improve EVEX strcmp with masked load - x86: Replace sse2 instructions with avx in memcmp-evex-movbe.S - x86: Optimize memset-vec-unaligned-erms.S - x86: Optimize memcmp-evex-movbe.S for frontend behavior and size - x86: Modify ENTRY in sysdep.h so that p2align can be specified - x86-64: Optimize load of all bits set into ZMM register [BZ #28252] - scripts/glibcelf.py: Mark as UNSUPPORTED on Python 3.5 and earlier - dlfcn: Do not use rtld_active () to determine ld.so state (bug 29078) - INSTALL: Rephrase -with-default-link documentation - misc: Fix rare fortify crash on wchar funcs. [BZ 29030] - Default to --with-default-link=no (bug 25812) - scripts: Add glibcelf.py module * Thu Apr 21 2022 Carlos O'Donell <carlos@redhat.com> - 2.34-30 - Sync with upstream branch release/2.34/master, commit 71326f1f2fd09dafb9c34404765fb88129e94237: - nptl: Fix pthread_cancel cancelhandling atomic operations - mips: Fix mips64n32 64 bit time_t stat support (BZ#29069) - hurd: Fix arbitrary error code - nptl: Handle spurious EINTR when thread cancellation is disabled (BZ#29029) - S390: Add new s390 platform z16. - NEWS: Update fixed bug list for LD_AUDIT backports. - hppa: Fix bind-now audit (BZ #28857) - elf: Replace tst-audit24bmod2.so with tst-audit24bmod2 - Fix elf/tst-audit25a with default bind now toolchains - elf: Fix runtime linker auditing on aarch64 (BZ #26643) - elf: Issue la_symbind for bind-now (BZ #23734) - elf: Fix initial-exec TLS access on audit modules (BZ #28096) - elf: Add la_activity during application exit - elf: Do not fail for failed dlmopen on audit modules (BZ #28061) - elf: Issue audit la_objopen for vDSO - elf: Add audit tests for modules with TLSDESC - elf: Avoid unnecessary slowdown from profiling with audit (BZ#15533) - elf: Add _dl_audit_pltexit - elf: Add _dl_audit_pltenter - elf: Add _dl_audit_preinit - elf: Add _dl_audit_symbind_alt and _dl_audit_symbind - elf: Add _dl_audit_objclose - elf: Add _dl_audit_objsearch - elf: Add _dl_audit_activity_map and _dl_audit_activity_nsid - elf: Add _dl_audit_objopen - elf: Move la_activity (LA_ACT_ADD) after _dl_add_to_namespace_list() (BZ #28062) - elf: Move LAV_CURRENT to link_lavcurrent.h - elf: Fix elf_get_dynamic_info() for bootstrap - elf: Fix dynamic-link.h usage on rtld.c - elf: Fix elf_get_dynamic_info definition - elf: Avoid nested functions in the loader [BZ #27220] - powerpc: Delete unneeded ELF_MACHINE_BEFORE_RTLD_RELOC - hppa: Use END instead of PSEUDO_END in swapcontext.S - hppa: Implement swapcontext in assembler (bug 28960) Resolves: #2003291 Resolves: #2064181 Resolves: #2072328 Resolves: #2075713 Resolves: #2077838
243 lines
9.1 KiB
Diff
243 lines
9.1 KiB
Diff
commit 0c03cb54c808173d8e7ba96f6152dfcf627ac496
|
|
Author: Stefan Liebler <stli@linux.ibm.com>
|
|
Date: Wed Apr 13 14:36:09 2022 +0200
|
|
|
|
S390: Add new s390 platform z16.
|
|
|
|
The new IBM z16 is added to platform string array.
|
|
The macro _DL_PLATFORMS_COUNT is incremented.
|
|
|
|
_dl_hwcaps_subdir is extended by "z16" if HWCAP_S390_VXRS_PDE2
|
|
is set. HWCAP_S390_NNPA is not tested in _dl_hwcaps_subdirs_active
|
|
as those instructions may be replaced or removed in future.
|
|
|
|
tst-glibc-hwcaps.c is extended in order to test z16 via new marker5.
|
|
|
|
A fatal glibc error is dumped if glibc was build with architecture
|
|
level set for z16, but run on an older machine. (See dl-hwcap-check.h)
|
|
|
|
(cherry picked from commit 2376944b9e5c0364b9fb473e4d8dabca31b57167)
|
|
|
|
Conflicts:
|
|
sysdeps/s390/s390-64/dl-hwcap-check.h - Use GCCMACRO__ARCH__.
|
|
- Backported f01d482f0355a7029d0715ace0ccf3323e7e94bc requires it.
|
|
|
|
diff --git a/elf/Makefile b/elf/Makefile
|
|
index 3e17a0706f5ec2df..8e2dd91c583f9a62 100644
|
|
--- a/elf/Makefile
|
|
+++ b/elf/Makefile
|
|
@@ -571,6 +571,11 @@ modules-names = \
|
|
libmarkermod4-2 \
|
|
libmarkermod4-3 \
|
|
libmarkermod4-4 \
|
|
+ libmarkermod5-1 \
|
|
+ libmarkermod5-2 \
|
|
+ libmarkermod5-3 \
|
|
+ libmarkermod5-4 \
|
|
+ libmarkermod5-5 \
|
|
ltglobmod1 \
|
|
ltglobmod2 \
|
|
neededobj1 \
|
|
@@ -2412,6 +2417,7 @@ LDFLAGS-libmarkermod1-1.so += -Wl,-soname,libmarkermod1.so
|
|
LDFLAGS-libmarkermod2-1.so += -Wl,-soname,libmarkermod2.so
|
|
LDFLAGS-libmarkermod3-1.so += -Wl,-soname,libmarkermod3.so
|
|
LDFLAGS-libmarkermod4-1.so += -Wl,-soname,libmarkermod4.so
|
|
+LDFLAGS-libmarkermod5-1.so += -Wl,-soname,libmarkermod5.so
|
|
$(objpfx)libmarkermod%.os : markermodMARKER-VALUE.c
|
|
$(compile-command.c) \
|
|
-DMARKER=marker$(firstword $(subst -, ,$*)) \
|
|
@@ -2424,6 +2430,8 @@ $(objpfx)libmarkermod3.so: $(objpfx)libmarkermod3-1.so
|
|
cp $< $@
|
|
$(objpfx)libmarkermod4.so: $(objpfx)libmarkermod4-1.so
|
|
cp $< $@
|
|
+$(objpfx)libmarkermod5.so: $(objpfx)libmarkermod5-1.so
|
|
+ cp $< $@
|
|
|
|
# tst-glibc-hwcaps-prepend checks that --glibc-hwcaps-prepend is
|
|
# preferred over auto-detected subdirectories.
|
|
diff --git a/elf/tst-glibc-hwcaps-cache.script b/elf/tst-glibc-hwcaps-cache.script
|
|
index c3271f61f9e50f2e..d58fc8c5de3c5198 100644
|
|
--- a/elf/tst-glibc-hwcaps-cache.script
|
|
+++ b/elf/tst-glibc-hwcaps-cache.script
|
|
@@ -4,6 +4,7 @@
|
|
cp $B/elf/libmarkermod2-1.so $L/libmarkermod2.so
|
|
cp $B/elf/libmarkermod3-1.so $L/libmarkermod3.so
|
|
cp $B/elf/libmarkermod4-1.so $L/libmarkermod4.so
|
|
+cp $B/elf/libmarkermod5-1.so $L/libmarkermod5.so
|
|
|
|
mkdirp 0770 $L/glibc-hwcaps/power9
|
|
cp $B/elf/libmarkermod2-2.so $L/glibc-hwcaps/power9/libmarkermod2.so
|
|
@@ -20,6 +21,11 @@ mkdirp 0770 $L/glibc-hwcaps/z15
|
|
cp $B/elf/libmarkermod4-2.so $L/glibc-hwcaps/z13/libmarkermod4.so
|
|
cp $B/elf/libmarkermod4-3.so $L/glibc-hwcaps/z14/libmarkermod4.so
|
|
cp $B/elf/libmarkermod4-4.so $L/glibc-hwcaps/z15/libmarkermod4.so
|
|
+mkdirp 0770 $L/glibc-hwcaps/z16
|
|
+cp $B/elf/libmarkermod5-2.so $L/glibc-hwcaps/z13/libmarkermod5.so
|
|
+cp $B/elf/libmarkermod5-3.so $L/glibc-hwcaps/z14/libmarkermod5.so
|
|
+cp $B/elf/libmarkermod5-4.so $L/glibc-hwcaps/z15/libmarkermod5.so
|
|
+cp $B/elf/libmarkermod5-5.so $L/glibc-hwcaps/z16/libmarkermod5.so
|
|
|
|
mkdirp 0770 $L/glibc-hwcaps/x86-64-v2
|
|
cp $B/elf/libmarkermod2-2.so $L/glibc-hwcaps/x86-64-v2/libmarkermod2.so
|
|
diff --git a/sysdeps/s390/dl-procinfo.c b/sysdeps/s390/dl-procinfo.c
|
|
index 155f0bd99eccb3f9..755b54ff13a0fa2f 100644
|
|
--- a/sysdeps/s390/dl-procinfo.c
|
|
+++ b/sysdeps/s390/dl-procinfo.c
|
|
@@ -64,11 +64,12 @@ PROCINFO_CLASS const char _dl_s390_cap_flags[23][9]
|
|
#if !defined PROCINFO_DECL && defined SHARED
|
|
._dl_s390_platforms
|
|
#else
|
|
-PROCINFO_CLASS const char _dl_s390_platforms[10][7]
|
|
+PROCINFO_CLASS const char _dl_s390_platforms[11][7]
|
|
#endif
|
|
#ifndef PROCINFO_DECL
|
|
= {
|
|
- "g5", "z900", "z990", "z9-109", "z10", "z196", "zEC12", "z13", "z14", "z15"
|
|
+ "g5", "z900", "z990", "z9-109", "z10", "z196", "zEC12", "z13", "z14", "z15",
|
|
+ "z16"
|
|
}
|
|
#endif
|
|
#if !defined SHARED || defined PROCINFO_DECL
|
|
diff --git a/sysdeps/s390/dl-procinfo.h b/sysdeps/s390/dl-procinfo.h
|
|
index e4e3e334a5b3d47c..d44e1dd97441bd90 100644
|
|
--- a/sysdeps/s390/dl-procinfo.h
|
|
+++ b/sysdeps/s390/dl-procinfo.h
|
|
@@ -23,7 +23,7 @@
|
|
|
|
#define _DL_HWCAP_COUNT 23
|
|
|
|
-#define _DL_PLATFORMS_COUNT 10
|
|
+#define _DL_PLATFORMS_COUNT 11
|
|
|
|
/* The kernel provides up to 32 capability bits with elf_hwcap. */
|
|
#define _DL_FIRST_PLATFORM 32
|
|
diff --git a/sysdeps/s390/s390-64/Makefile b/sysdeps/s390/s390-64/Makefile
|
|
index e5da26871c862e63..66ed844e68df5159 100644
|
|
--- a/sysdeps/s390/s390-64/Makefile
|
|
+++ b/sysdeps/s390/s390-64/Makefile
|
|
@@ -7,8 +7,11 @@ CFLAGS-rtld.c += -Wno-uninitialized -Wno-unused
|
|
CFLAGS-dl-load.c += -Wno-unused
|
|
CFLAGS-dl-reloc.c += -Wno-unused
|
|
|
|
-$(objpfx)tst-glibc-hwcaps: $(objpfx)libmarkermod2-1.so \
|
|
- $(objpfx)libmarkermod3-1.so $(objpfx)libmarkermod4-1.so
|
|
+$(objpfx)tst-glibc-hwcaps: \
|
|
+ $(objpfx)libmarkermod2-1.so \
|
|
+ $(objpfx)libmarkermod3-1.so \
|
|
+ $(objpfx)libmarkermod4-1.so \
|
|
+ $(objpfx)libmarkermod5-1.so
|
|
$(objpfx)tst-glibc-hwcaps.out: \
|
|
$(objpfx)libmarkermod2.so \
|
|
$(objpfx)glibc-hwcaps/z13/libmarkermod2.so \
|
|
@@ -19,6 +22,11 @@ $(objpfx)tst-glibc-hwcaps.out: \
|
|
$(objpfx)glibc-hwcaps/z13/libmarkermod4.so \
|
|
$(objpfx)glibc-hwcaps/z14/libmarkermod4.so \
|
|
$(objpfx)glibc-hwcaps/z15/libmarkermod4.so \
|
|
+ $(objpfx)libmarkermod5.so \
|
|
+ $(objpfx)glibc-hwcaps/z13/libmarkermod5.so \
|
|
+ $(objpfx)glibc-hwcaps/z14/libmarkermod5.so \
|
|
+ $(objpfx)glibc-hwcaps/z15/libmarkermod5.so \
|
|
+ $(objpfx)glibc-hwcaps/z16/libmarkermod5.so
|
|
|
|
$(objpfx)glibc-hwcaps/z13/libmarkermod2.so: $(objpfx)libmarkermod2-2.so
|
|
$(make-target-directory)
|
|
@@ -38,6 +46,19 @@ $(objpfx)glibc-hwcaps/z14/libmarkermod4.so: $(objpfx)libmarkermod4-3.so
|
|
$(objpfx)glibc-hwcaps/z15/libmarkermod4.so: $(objpfx)libmarkermod4-4.so
|
|
$(make-target-directory)
|
|
cp $< $@
|
|
+$(objpfx)glibc-hwcaps/z13/libmarkermod5.so: $(objpfx)libmarkermod5-2.so
|
|
+ $(make-target-directory)
|
|
+ cp $< $@
|
|
+$(objpfx)glibc-hwcaps/z14/libmarkermod5.so: $(objpfx)libmarkermod5-3.so
|
|
+ $(make-target-directory)
|
|
+ cp $< $@
|
|
+$(objpfx)glibc-hwcaps/z15/libmarkermod5.so: $(objpfx)libmarkermod5-4.so
|
|
+ $(make-target-directory)
|
|
+ cp $< $@
|
|
+$(objpfx)glibc-hwcaps/z16/libmarkermod5.so: $(objpfx)libmarkermod5-5.so
|
|
+ $(make-target-directory)
|
|
+ cp $< $@
|
|
+
|
|
|
|
ifeq (no,$(build-hardcoded-path-in-tests))
|
|
# This is an ld.so.cache test, and RPATH/RUNPATH in the executable
|
|
diff --git a/sysdeps/s390/s390-64/dl-hwcap-check.h b/sysdeps/s390/s390-64/dl-hwcap-check.h
|
|
index 27f7e245b1d1a9e9..52c609571b32f4ab 100644
|
|
--- a/sysdeps/s390/s390-64/dl-hwcap-check.h
|
|
+++ b/sysdeps/s390/s390-64/dl-hwcap-check.h
|
|
@@ -26,7 +26,11 @@ static inline void
|
|
dl_hwcap_check (void)
|
|
{
|
|
#if defined __ARCH__
|
|
-# if GCCMACRO__ARCH__ >= 13
|
|
+# if GCCMACRO__ARCH__ >= 14
|
|
+ if (!(GLRO(dl_hwcap) & HWCAP_S390_VXRS_PDE2))
|
|
+ _dl_fatal_printf ("\
|
|
+Fatal glibc error: CPU lacks VXRS_PDE2 support (z16 or later required)\n");
|
|
+# elif GCCMACRO__ARCH__ >= 13
|
|
if (!(GLRO(dl_hwcap) & HWCAP_S390_VXRS_EXT2))
|
|
_dl_fatal_printf ("\
|
|
Fatal glibc error: CPU lacks VXRS_EXT2 support (z15 or later required)\n");
|
|
diff --git a/sysdeps/s390/s390-64/dl-hwcaps-subdirs.c b/sysdeps/s390/s390-64/dl-hwcaps-subdirs.c
|
|
index b9d094f3d73c2d7a..187d732d560c4a62 100644
|
|
--- a/sysdeps/s390/s390-64/dl-hwcaps-subdirs.c
|
|
+++ b/sysdeps/s390/s390-64/dl-hwcaps-subdirs.c
|
|
@@ -19,8 +19,8 @@
|
|
#include <dl-hwcaps.h>
|
|
#include <ldsodefs.h>
|
|
|
|
-const char _dl_hwcaps_subdirs[] = "z15:z14:z13";
|
|
-enum { subdirs_count = 3 }; /* Number of components in _dl_hwcaps_subdirs. */
|
|
+const char _dl_hwcaps_subdirs[] = "z16:z15:z14:z13";
|
|
+enum { subdirs_count = 4 }; /* Number of components in _dl_hwcaps_subdirs. */
|
|
|
|
uint32_t
|
|
_dl_hwcaps_subdirs_active (void)
|
|
@@ -50,5 +50,12 @@ _dl_hwcaps_subdirs_active (void)
|
|
return _dl_hwcaps_subdirs_build_bitmask (subdirs_count, active);
|
|
++active;
|
|
|
|
+ /* z16.
|
|
+ Note: We do not list HWCAP_S390_NNPA here as, according to the Principles of
|
|
+ Operation, those instructions may be replaced or removed in future. */
|
|
+ if (!(GLRO (dl_hwcap) & HWCAP_S390_VXRS_PDE2))
|
|
+ return _dl_hwcaps_subdirs_build_bitmask (subdirs_count, active);
|
|
+ ++active;
|
|
+
|
|
return _dl_hwcaps_subdirs_build_bitmask (subdirs_count, active);
|
|
}
|
|
diff --git a/sysdeps/s390/s390-64/tst-glibc-hwcaps.c b/sysdeps/s390/s390-64/tst-glibc-hwcaps.c
|
|
index 02397a478c552516..f3b8ef3dec80d2d1 100644
|
|
--- a/sysdeps/s390/s390-64/tst-glibc-hwcaps.c
|
|
+++ b/sysdeps/s390/s390-64/tst-glibc-hwcaps.c
|
|
@@ -25,6 +25,7 @@
|
|
extern int marker2 (void);
|
|
extern int marker3 (void);
|
|
extern int marker4 (void);
|
|
+extern int marker5 (void);
|
|
|
|
/* Return the arch level, 10 for the baseline libmarkermod*.so's. */
|
|
static int
|
|
@@ -63,9 +64,11 @@ compute_level (void)
|
|
return 12;
|
|
if (strcmp (platform, "z15") == 0)
|
|
return 13;
|
|
+ if (strcmp (platform, "z16") == 0)
|
|
+ return 14;
|
|
printf ("warning: unrecognized AT_PLATFORM value: %s\n", platform);
|
|
- /* Assume that the new platform supports z15. */
|
|
- return 13;
|
|
+ /* Assume that the new platform supports z16. */
|
|
+ return 14;
|
|
}
|
|
|
|
static int
|
|
@@ -76,6 +79,7 @@ do_test (void)
|
|
TEST_COMPARE (marker2 (), MIN (level - 9, 2));
|
|
TEST_COMPARE (marker3 (), MIN (level - 9, 3));
|
|
TEST_COMPARE (marker4 (), MIN (level - 9, 4));
|
|
+ TEST_COMPARE (marker5 (), MIN (level - 9, 5));
|
|
return 0;
|
|
}
|
|
|