From 3c1b0828282e6409c70ed0ac75406f805f93befa Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: Aug 25 2021 00:14:26 +0000 Subject: import compiler-rt-12.0.1-1.module+el8.5.0+11871+08d0eab5 --- diff --git a/.compiler-rt.metadata b/.compiler-rt.metadata index 2873426..d2a6fc5 100644 --- a/.compiler-rt.metadata +++ b/.compiler-rt.metadata @@ -1,2 +1,2 @@ -7b02a455fbc6fe395da8d5411072acc04d669d94 SOURCES/compiler-rt-12.0.0.src.tar.xz +d33af648dc9b901c6c9f6c5872af2f59203f1a25 SOURCES/compiler-rt-12.0.1.src.tar.xz b8d2648a01d36ed0186fd2c5af325fd28797f9a0 SOURCES/tstellar-gpg-key.asc diff --git a/.gitignore b/.gitignore index 13b84c6..b91f9de 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,2 @@ -SOURCES/compiler-rt-12.0.0.src.tar.xz +SOURCES/compiler-rt-12.0.1.src.tar.xz SOURCES/tstellar-gpg-key.asc diff --git a/SOURCES/0002-PATCH-compiler-rt-Sanitizer-built-against-glibc-2.34.patch b/SOURCES/0002-PATCH-compiler-rt-Sanitizer-built-against-glibc-2.34.patch deleted file mode 100644 index 0f438f1..0000000 --- a/SOURCES/0002-PATCH-compiler-rt-Sanitizer-built-against-glibc-2.34.patch +++ /dev/null @@ -1,71 +0,0 @@ -From ffd0f69c375f12f081a1a5158a02a05000b7a93c Mon Sep 17 00:00:00 2001 -From: Vitaly Buka -Date: Fri, 16 Apr 2021 09:50:24 -0700 -Subject: [PATCH][compiler-rt] Sanitizer built against glibc 2.34 doesn't work - -As mentioned in https://gcc.gnu.org/PR100114 , glibc starting with the -https://sourceware.org/git/?p=glibc.git;a=commit;h=6c57d320484988e87e446e2e60ce42816bf51d53 -change doesn't define SIGSTKSZ and MINSIGSTKSZ macros to constants, but to sysconf function call. -sanitizer_posix_libcdep.cpp has -static const uptr kAltStackSize = SIGSTKSZ * 4; // SIGSTKSZ is not enough. -which is generally fine, just means that when SIGSTKSZ is not a compile time constant will be initialized later. -The problem is that kAltStackSize is used in SetAlternateSignalStack which is called very early, from .preinit_array -initialization, i.e. far before file scope variables are constructed, which means it is not initialized and -mmapping 0 will fail: -==145==ERROR: AddressSanitizer failed to allocate 0x0 (0) bytes of SetAlternateSignalStack (error code: 22) - -Here is one possible fix, another one could be to make kAltStackSize a preprocessor macro if _SG_SIGSTKSZ is defined -(but perhaps with having an automatic const variable initialized to it so that sysconf isn't at least called twice -during SetAlternateSignalStack. - -Reviewed By: vitalybuka - -Differential Revision: https://reviews.llvm.org/D100645 - -(cherry picked from commit 82150606fb11d28813ae6da1101f5bda638165fe) ---- - compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cpp | 12 ++++++++---- - 1 file changed, 8 insertions(+), 4 deletions(-) - -diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cpp -index d29438c..2b10bdd 100644 ---- a/compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cpp -+++ b/compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cpp -@@ -165,7 +165,11 @@ bool SupportsColoredOutput(fd_t fd) { - - #if !SANITIZER_GO - // TODO(glider): different tools may require different altstack size. --static const uptr kAltStackSize = SIGSTKSZ * 4; // SIGSTKSZ is not enough. -+static uptr GetAltStackSize() { -+ // SIGSTKSZ is not enough. -+ static const uptr kAltStackSize = SIGSTKSZ * 4; -+ return kAltStackSize; -+} - - void SetAlternateSignalStack() { - stack_t altstack, oldstack; -@@ -176,10 +180,10 @@ void SetAlternateSignalStack() { - // TODO(glider): the mapped stack should have the MAP_STACK flag in the - // future. It is not required by man 2 sigaltstack now (they're using - // malloc()). -- void* base = MmapOrDie(kAltStackSize, __func__); -+ void *base = MmapOrDie(GetAltStackSize(), __func__); - altstack.ss_sp = (char*) base; - altstack.ss_flags = 0; -- altstack.ss_size = kAltStackSize; -+ altstack.ss_size = GetAltStackSize(); - CHECK_EQ(0, sigaltstack(&altstack, nullptr)); - } - -@@ -187,7 +191,7 @@ void UnsetAlternateSignalStack() { - stack_t altstack, oldstack; - altstack.ss_sp = nullptr; - altstack.ss_flags = SS_DISABLE; -- altstack.ss_size = kAltStackSize; // Some sane value required on Darwin. -+ altstack.ss_size = GetAltStackSize(); // Some sane value required on Darwin. - CHECK_EQ(0, sigaltstack(&altstack, &oldstack)); - UnmapOrDie(oldstack.ss_sp, oldstack.ss_size); - } --- -1.8.3.1 - diff --git a/SOURCES/0003-PATCH-compiler-rt-Prevent-introduction-of-a-dependen.patch b/SOURCES/0003-PATCH-compiler-rt-Prevent-introduction-of-a-dependen.patch deleted file mode 100644 index 98e0240..0000000 --- a/SOURCES/0003-PATCH-compiler-rt-Prevent-introduction-of-a-dependen.patch +++ /dev/null @@ -1,54 +0,0 @@ -From 96339090681ae1dd9afe186ea14a460b61794707 Mon Sep 17 00:00:00 2001 -From: serge-sans-paille -Date: Tue, 11 May 2021 14:38:21 +0200 -Subject: [PATCH][compiler-rt] Prevent introduction of a dependency of - libasan.a on libstdc++ - -This an attempt to fix an issue introduced by https://reviews.llvm.org/D70662 - -Function-scope static initialization are guarded in C++, so we should probably -not use it because it introduces a dependency on __cxa_guard* symbols. -In the context of clang, libasan is linked statically, and it currently needs to -the odd situation where compiling C code with clang and asan requires -lstdc++. - -I'm unsure of the portability requirements, providing a potential solution in -this review. - -Differential Revision: https://reviews.llvm.org/D102475 ---- - compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cpp | 12 +++++++++--- - 1 file changed, 9 insertions(+), 3 deletions(-) - -diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cpp -index 2b10bdd..818f1af 100644 ---- a/compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cpp -+++ b/compiler-rt/lib/sanitizer_common/sanitizer_posix_libcdep.cpp -@@ -15,6 +15,7 @@ - - #if SANITIZER_POSIX - -+#include "sanitizer_atomic.h" - #include "sanitizer_common.h" - #include "sanitizer_flags.h" - #include "sanitizer_platform_limits_netbsd.h" -@@ -166,9 +167,14 @@ bool SupportsColoredOutput(fd_t fd) { - #if !SANITIZER_GO - // TODO(glider): different tools may require different altstack size. - static uptr GetAltStackSize() { -- // SIGSTKSZ is not enough. -- static const uptr kAltStackSize = SIGSTKSZ * 4; -- return kAltStackSize; -+ static atomic_uintptr_t kAltStackSize{0}; -+ uptr ret = atomic_load(&kAltStackSize, memory_order_relaxed); -+ if (ret == 0) { -+ // SIGSTKSZ is not enough. -+ ret = SIGSTKSZ * 4; -+ atomic_store(&kAltStackSize, ret, memory_order_relaxed); -+ } -+ return ret; - } - - void SetAlternateSignalStack() { --- -1.8.3.1 - diff --git a/SOURCES/0004-PATCH-compiler-rt-libsanitizer-Remove-cyclades-inclu.patch b/SOURCES/0004-PATCH-compiler-rt-libsanitizer-Remove-cyclades-inclu.patch deleted file mode 100644 index d2c4401..0000000 --- a/SOURCES/0004-PATCH-compiler-rt-libsanitizer-Remove-cyclades-inclu.patch +++ /dev/null @@ -1,120 +0,0 @@ -From c9a8c70be89cfa62aa51862f4c8e0fa4c50134d2 Mon Sep 17 00:00:00 2001 -From: Tamar Christina -Date: Thu, 20 May 2021 18:55:11 +0100 -Subject: [PATCH][compiler-rt] libsanitizer: Remove cyclades inclusion in - sanitizer - -The Linux kernel has removed the interface to cyclades from -the latest kernel headers[1] due to them being orphaned for the -past 13 years. - -libsanitizer uses this header when compiling against glibc, but -glibcs itself doesn't seem to have any references to cyclades. - -Further more it seems that the driver is broken in the kernel and -the firmware doesn't seem to be available anymore. - -As such since this is breaking the build of libsanitizer (and so the -GCC bootstrap[2]) I propose to remove this. - -[1] https://lkml.org/lkml/2021/3/2/153 -[2] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100379 - -Reviewed By: eugenis - -Differential Revision: https://reviews.llvm.org/D102059 - -(cherry picked from commit 68d5235cb58f988c71b403334cd9482d663841ab) ---- - .../sanitizer_common/sanitizer_common_interceptors_ioctl.inc | 9 --------- - .../lib/sanitizer_common/sanitizer_platform_limits_posix.cpp | 11 ----------- - .../lib/sanitizer_common/sanitizer_platform_limits_posix.h | 10 ---------- - 3 files changed, 30 deletions(-) - -diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc b/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc -index 7f18125..b7da659 100644 ---- a/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc -+++ b/compiler-rt/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc -@@ -370,15 +370,6 @@ static void ioctl_table_fill() { - - #if SANITIZER_GLIBC - // _(SIOCDEVPLIP, WRITE, struct_ifreq_sz); // the same as EQL_ENSLAVE -- _(CYGETDEFTHRESH, WRITE, sizeof(int)); -- _(CYGETDEFTIMEOUT, WRITE, sizeof(int)); -- _(CYGETMON, WRITE, struct_cyclades_monitor_sz); -- _(CYGETTHRESH, WRITE, sizeof(int)); -- _(CYGETTIMEOUT, WRITE, sizeof(int)); -- _(CYSETDEFTHRESH, NONE, 0); -- _(CYSETDEFTIMEOUT, NONE, 0); -- _(CYSETTHRESH, NONE, 0); -- _(CYSETTIMEOUT, NONE, 0); - _(EQL_EMANCIPATE, WRITE, struct_ifreq_sz); - _(EQL_ENSLAVE, WRITE, struct_ifreq_sz); - _(EQL_GETMASTRCFG, WRITE, struct_ifreq_sz); -diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp -index 12dd39e..7abaeb8 100644 ---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp -+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp -@@ -143,7 +143,6 @@ typedef struct user_fpregs elf_fpregset_t; - # include - #endif - #include --#include - #include - #include - #include -@@ -459,7 +458,6 @@ unsigned struct_ElfW_Phdr_sz = sizeof(Elf_Phdr); - - #if SANITIZER_GLIBC - unsigned struct_ax25_parms_struct_sz = sizeof(struct ax25_parms_struct); -- unsigned struct_cyclades_monitor_sz = sizeof(struct cyclades_monitor); - #if EV_VERSION > (0x010000) - unsigned struct_input_keymap_entry_sz = sizeof(struct input_keymap_entry); - #else -@@ -823,15 +821,6 @@ unsigned struct_ElfW_Phdr_sz = sizeof(Elf_Phdr); - #endif // SANITIZER_LINUX - - #if SANITIZER_LINUX && !SANITIZER_ANDROID -- unsigned IOCTL_CYGETDEFTHRESH = CYGETDEFTHRESH; -- unsigned IOCTL_CYGETDEFTIMEOUT = CYGETDEFTIMEOUT; -- unsigned IOCTL_CYGETMON = CYGETMON; -- unsigned IOCTL_CYGETTHRESH = CYGETTHRESH; -- unsigned IOCTL_CYGETTIMEOUT = CYGETTIMEOUT; -- unsigned IOCTL_CYSETDEFTHRESH = CYSETDEFTHRESH; -- unsigned IOCTL_CYSETDEFTIMEOUT = CYSETDEFTIMEOUT; -- unsigned IOCTL_CYSETTHRESH = CYSETTHRESH; -- unsigned IOCTL_CYSETTIMEOUT = CYSETTIMEOUT; - unsigned IOCTL_EQL_EMANCIPATE = EQL_EMANCIPATE; - unsigned IOCTL_EQL_ENSLAVE = EQL_ENSLAVE; - unsigned IOCTL_EQL_GETMASTRCFG = EQL_GETMASTRCFG; -diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h -index 836b178..8a156b7 100644 ---- a/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h -+++ b/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h -@@ -983,7 +983,6 @@ extern unsigned struct_vt_mode_sz; - - #if SANITIZER_LINUX && !SANITIZER_ANDROID - extern unsigned struct_ax25_parms_struct_sz; --extern unsigned struct_cyclades_monitor_sz; - extern unsigned struct_input_keymap_entry_sz; - extern unsigned struct_ipx_config_data_sz; - extern unsigned struct_kbdiacrs_sz; -@@ -1328,15 +1327,6 @@ extern unsigned IOCTL_VT_WAITACTIVE; - #endif // SANITIZER_LINUX - - #if SANITIZER_LINUX && !SANITIZER_ANDROID --extern unsigned IOCTL_CYGETDEFTHRESH; --extern unsigned IOCTL_CYGETDEFTIMEOUT; --extern unsigned IOCTL_CYGETMON; --extern unsigned IOCTL_CYGETTHRESH; --extern unsigned IOCTL_CYGETTIMEOUT; --extern unsigned IOCTL_CYSETDEFTHRESH; --extern unsigned IOCTL_CYSETDEFTIMEOUT; --extern unsigned IOCTL_CYSETTHRESH; --extern unsigned IOCTL_CYSETTIMEOUT; - extern unsigned IOCTL_EQL_EMANCIPATE; - extern unsigned IOCTL_EQL_ENSLAVE; - extern unsigned IOCTL_EQL_GETMASTRCFG; --- -1.8.3.1 - diff --git a/SOURCES/compiler-rt-12.0.0.src.tar.xz.sig b/SOURCES/compiler-rt-12.0.0.src.tar.xz.sig deleted file mode 100644 index 4b017e4..0000000 Binary files a/SOURCES/compiler-rt-12.0.0.src.tar.xz.sig and /dev/null differ diff --git a/SOURCES/compiler-rt-12.0.1.src.tar.xz.sig b/SOURCES/compiler-rt-12.0.1.src.tar.xz.sig new file mode 100644 index 0000000..c41c624 Binary files /dev/null and b/SOURCES/compiler-rt-12.0.1.src.tar.xz.sig differ diff --git a/SPECS/compiler-rt.spec b/SPECS/compiler-rt.spec index 5f4b32f..cdd58b7 100644 --- a/SPECS/compiler-rt.spec +++ b/SPECS/compiler-rt.spec @@ -9,8 +9,8 @@ %global optflags %(echo %{optflags} -Dasm=__asm__) Name: compiler-rt -Version: 12.0.0%{?rc_ver:~rc%{rc_ver}} -Release: 2%{?dist} +Version: 12.0.1%{?rc_ver:~rc%{rc_ver}} +Release: 1%{?dist} Summary: LLVM "compiler-rt" runtime libraries License: NCSA or MIT @@ -20,9 +20,6 @@ Source1: https://github.com/llvm/llvm-project/releases/download/llvmorg-%{versio Source2: tstellar-gpg-key.asc Patch0: 0001-PATCH-compiler-rt-Workaround-libstdc-limitation-wrt..patch -Patch1: 0002-PATCH-compiler-rt-Sanitizer-built-against-glibc-2.34.patch -Patch3: 0003-PATCH-compiler-rt-Prevent-introduction-of-a-dependen.patch -Patch4: 0004-PATCH-compiler-rt-libsanitizer-Remove-cyclades-inclu.patch # RHEL-specific patches Patch100: 0001-Drop-fno-stack-protector-from-the-compiler-flags.patch @@ -116,6 +113,9 @@ popd %endif %changelog +* Fri Jul 16 2021 sguelton@redhat.com - 12.0.1-1 +- 12.0.1 release + * Tue May 25 2021 sguelton@redhat.com - 12.0.0-2 - Backport several compatibility patches