From dd4cea4c9fc46763f720e4f056b45c651b8a3f0c Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: Tue, 28 Jul 2020 08:15:04 -0400 Subject: [PATCH] import compiler-rt-10.0.0-2.module+el8.3.0+7004+904a04ce --- .compiler-rt.metadata | 3 +- .gitignore | 3 +- ...ck-protector-from-the-compiler-flags.patch | 14 ++-- ...-strict-aliasing-warning-in-msan.cpp.patch | 68 ++++++++++++++++++ SOURCES/compiler-rt-10.0.0.src.tar.xz.sig | Bin 0 -> 566 bytes SPECS/compiler-rt.spec | 52 ++++++++++---- 6 files changed, 117 insertions(+), 23 deletions(-) create mode 100644 SOURCES/0001-Fix-strict-aliasing-warning-in-msan.cpp.patch create mode 100644 SOURCES/compiler-rt-10.0.0.src.tar.xz.sig diff --git a/.compiler-rt.metadata b/.compiler-rt.metadata index 829e254..df53cce 100644 --- a/.compiler-rt.metadata +++ b/.compiler-rt.metadata @@ -1 +1,2 @@ -4e00cb231ff87fd4f970f35b2da86185a612e0e2 SOURCES/compiler-rt-9.0.0.src.tar.xz +4744490da9c1186ba7f730d8a8f4fa4b0d4ee0bc SOURCES/compiler-rt-10.0.0.src.tar.xz +32fa4b0193960f05064f2ab31b5a89c7cf48a0b9 SOURCES/hans-gpg-key.asc diff --git a/.gitignore b/.gitignore index 8bcaaa3..bb7c9af 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ -SOURCES/compiler-rt-9.0.0.src.tar.xz +SOURCES/compiler-rt-10.0.0.src.tar.xz +SOURCES/hans-gpg-key.asc diff --git a/SOURCES/0001-Drop-fno-stack-protector-from-the-compiler-flags.patch b/SOURCES/0001-Drop-fno-stack-protector-from-the-compiler-flags.patch index eea43d6..d7a57a5 100644 --- a/SOURCES/0001-Drop-fno-stack-protector-from-the-compiler-flags.patch +++ b/SOURCES/0001-Drop-fno-stack-protector-from-the-compiler-flags.patch @@ -1,17 +1,17 @@ -From 66b952a4aeab83a7692d9d80a046034de79fe2e2 Mon Sep 17 00:00:00 2001 +From f007934385dc76b9299bd72cdef102fe979af93b Mon Sep 17 00:00:00 2001 From: Tom Stellard Date: Wed, 5 Sep 2018 21:07:42 -0700 Subject: [PATCH] Drop -fno-stack-protector from the compiler flags --- - CMakeLists.txt | 1 - + compiler-rt/CMakeLists.txt | 1 - 1 file changed, 1 deletion(-) -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 4b953b2..043cc31 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -207,7 +207,6 @@ if(NOT COMPILER_RT_DEBUG AND NOT APPLE) +diff --git compiler-rt.orig/CMakeLists.txt compiler-rt/CMakeLists.txt +index f26ae25..a6ac032 100644 +--- compiler-rt.orig/CMakeLists.txt ++++ b/compiler-rt/CMakeLists.txt +@@ -271,7 +271,6 @@ if(NOT COMPILER_RT_DEBUG AND NOT APPLE) append_list_if(COMPILER_RT_HAS_FOMIT_FRAME_POINTER_FLAG -fomit-frame-pointer SANITIZER_COMMON_CFLAGS) endif() append_list_if(COMPILER_RT_HAS_FUNWIND_TABLES_FLAG -funwind-tables SANITIZER_COMMON_CFLAGS) diff --git a/SOURCES/0001-Fix-strict-aliasing-warning-in-msan.cpp.patch b/SOURCES/0001-Fix-strict-aliasing-warning-in-msan.cpp.patch new file mode 100644 index 0000000..b1f41e8 --- /dev/null +++ b/SOURCES/0001-Fix-strict-aliasing-warning-in-msan.cpp.patch @@ -0,0 +1,68 @@ +From af38074874c605f9e598ae3f7e5d4befa3fe92bb Mon Sep 17 00:00:00 2001 +From: serge-sans-paille +Date: Thu, 28 May 2020 17:50:31 +0200 +Subject: [PATCH] Fix strict aliasing warning in msan.cpp + +Use internal_memcpy instead. + +Differential Revision: https://reviews.llvm.org/D80732 +--- + compiler-rt/lib/msan/msan.cpp | 21 ++++++++++++++------- + 1 file changed, 14 insertions(+), 7 deletions(-) + +diff --git compiler-rt.orig/lib/msan/msan.cpp compiler-rt/lib/msan/msan.cpp +index 7095ee1bf20..8c789901adc 100644 +--- compiler-rt.orig/lib/msan/msan.cpp ++++ compiler-rt/lib/msan/msan.cpp +@@ -617,34 +617,41 @@ u32 __msan_get_umr_origin() { + } + + u16 __sanitizer_unaligned_load16(const uu16 *p) { +- *(uu16 *)&__msan_retval_tls[0] = *(uu16 *)MEM_TO_SHADOW((uptr)p); ++ internal_memcpy(&__msan_retval_tls[0], (void *)MEM_TO_SHADOW((uptr)p), ++ sizeof(uu16)); + if (__msan_get_track_origins()) + __msan_retval_origin_tls = GetOriginIfPoisoned((uptr)p, sizeof(*p)); + return *p; + } + u32 __sanitizer_unaligned_load32(const uu32 *p) { +- *(uu32 *)&__msan_retval_tls[0] = *(uu32 *)MEM_TO_SHADOW((uptr)p); ++ internal_memcpy(&__msan_retval_tls[0], (void *)MEM_TO_SHADOW((uptr)p), ++ sizeof(uu32)); + if (__msan_get_track_origins()) + __msan_retval_origin_tls = GetOriginIfPoisoned((uptr)p, sizeof(*p)); + return *p; + } + u64 __sanitizer_unaligned_load64(const uu64 *p) { +- __msan_retval_tls[0] = *(uu64 *)MEM_TO_SHADOW((uptr)p); ++ internal_memcpy(&__msan_retval_tls[0], (void *)MEM_TO_SHADOW((uptr)p), ++ sizeof(uu64)); + if (__msan_get_track_origins()) + __msan_retval_origin_tls = GetOriginIfPoisoned((uptr)p, sizeof(*p)); + return *p; + } + void __sanitizer_unaligned_store16(uu16 *p, u16 x) { +- u16 s = *(uu16 *)&__msan_param_tls[1]; +- *(uu16 *)MEM_TO_SHADOW((uptr)p) = s; ++ static_assert(sizeof(uu16) == sizeof(u16), "incompatible types"); ++ u16 s; ++ internal_memcpy(&s, &__msan_param_tls[1], sizeof(uu16)); ++ internal_memcpy((void *)MEM_TO_SHADOW((uptr)p), &s, sizeof(uu16)); + if (s && __msan_get_track_origins()) + if (uu32 o = __msan_param_origin_tls[2]) + SetOriginIfPoisoned((uptr)p, (uptr)&s, sizeof(s), o); + *p = x; + } + void __sanitizer_unaligned_store32(uu32 *p, u32 x) { +- u32 s = *(uu32 *)&__msan_param_tls[1]; +- *(uu32 *)MEM_TO_SHADOW((uptr)p) = s; ++ static_assert(sizeof(uu32) == sizeof(u32), "incompatible types"); ++ u32 s; ++ internal_memcpy(&s, &__msan_param_tls[1], sizeof(uu32)); ++ internal_memcpy((void *)MEM_TO_SHADOW((uptr)p), &s, sizeof(uu32)); + if (s && __msan_get_track_origins()) + if (uu32 o = __msan_param_origin_tls[2]) + SetOriginIfPoisoned((uptr)p, (uptr)&s, sizeof(s), o); +-- +2.25.2 + diff --git a/SOURCES/compiler-rt-10.0.0.src.tar.xz.sig b/SOURCES/compiler-rt-10.0.0.src.tar.xz.sig new file mode 100644 index 0000000000000000000000000000000000000000..883eb04e00b5b007beacf6a60f393d002815f383 GIT binary patch literal 566 zcmV-60?GY}0y6{v0SW*e79j+-$oYbTxkTfz)xuK`!vrogTF_ku0$zFilK=_{5D&uy zE;L%uUAeIj{xxvkXN>b;tD*Kf0?KPRKQkXxz-KODuj~yYv^VNDI~TZHeFd@+Z3Ah) z)Z#rdOKc@`Gr3f+MQzG2Rl@mioma`}u^^&v2XTvO4nUczZ(o#@7P66D|0s#)f9*%K z{Hh@w<%Abt%B+slhR;0geX&fkxpgHT3aI|5I(k%<+j=`n3JPNT&oM}mL~Ni19V8BuT3}zm&0-Z96a;G-g)JBkw;|AENBx_{o9t_23xW zOd=i8g~Qi5Us{E8YDZ?AT2%^F&tXW{Ba@k`yXX6)T4X602$;261x_QBNt`+F6oM>n - 9.0.1-2 +- Update fno-stack-protector patch to apply with -p2 + +* Fri Dec 20 2019 Tom Stellard - 9.0.1-1 +- 9.0.1 Release + * Fri Sep 27 2019 Tom Stellard - 9.0.0-1 - 9.0.0 Release