diff --git a/.skip-heapchecker-in-arm-arch.patch.swp b/.skip-heapchecker-in-arm-arch.patch.swp new file mode 100644 index 0000000000000000000000000000000000000000..ccd10cb890bf33f6e5cbcf4fca288f8356030c2f Binary files /dev/null and b/.skip-heapchecker-in-arm-arch.patch.swp differ diff --git a/0001-Resolving-loongarch64-build-error.patch b/0001-Resolving-loongarch64-build-error.patch deleted file mode 100644 index 5c1cf3c9dc9f6f3531a362a96b43aa2c994ea026..0000000000000000000000000000000000000000 --- a/0001-Resolving-loongarch64-build-error.patch +++ /dev/null @@ -1,26 +0,0 @@ -From c0a42b47a90003b6d23c8251ec5b27ea849cc279 Mon Sep 17 00:00:00 2001 -From: doupengda -Date: Wed, 12 Jul 2023 06:29:11 +0000 -Subject: [PATCH] Resolving loongarch64 build error - ---- - src/base/linux_syscall_support.h | 3 +++ - 1 file changed, 3 insertions(+) - -diff --git a/src/base/linux_syscall_support.h b/src/base/linux_syscall_support.h -index b807b11..8400732 100644 ---- a/src/base/linux_syscall_support.h -+++ b/src/base/linux_syscall_support.h -@@ -993,6 +993,9 @@ struct kernel_stat { - #ifndef __NR_fstatat - #define __NR_fstatat 79 - #endif -+#ifndef __NR_fstat -+#define __NR_fstat 80 -+#endif - #ifndef __NR_getdents64 - #define __NR_getdents64 61 - #endif /* End of loongarch64 defininitions */ --- -2.33.0 - diff --git a/avoid-exceed-int-range.patch b/avoid-exceed-int-range.patch deleted file mode 100644 index 4d03938c7ca63d3be5323da523c1566c59922033..0000000000000000000000000000000000000000 --- a/avoid-exceed-int-range.patch +++ /dev/null @@ -1,33 +0,0 @@ -From 85158d45ec66c34f5903a15c3b74600a925703ef Mon Sep 17 00:00:00 2001 -From: zhangyiru -Date: Thu, 14 Oct 2021 22:16:15 +0800 -Subject: [PATCH] avoid display problem if memleak exceeds range of int -if memleak exceeds range of int, heap checker result is incorrect, so -change it to size_t ---- - src/heap-profile-table.cc | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) -diff --git a/src/heap-profile-table.cc b/src/heap-profile-table.cc -index c3ce41c..1001fb3 100644 ---- a/src/heap-profile-table.cc -+++ b/src/heap-profile-table.cc -@@ -517,7 +517,7 @@ HeapProfileTable::Snapshot* HeapProfileTable::NonLiveSnapshot( - // Information kept per unique bucket seen - struct HeapProfileTable::Snapshot::Entry { - int count; -- int bytes; -+ size_t bytes; - Bucket* bucket; - Entry() : count(0), bytes(0) { } - -@@ -592,7 +592,7 @@ void HeapProfileTable::Snapshot::ReportLeaks(const char* checker_name, - for (int i = 0; i < to_report; i++) { - const Entry& e = entries[i]; - base::RawPrinter printer(buffer, kBufSize); -- printer.Printf("Leak of %d bytes in %d objects allocated from:\n", -+ printer.Printf("Leak of %zu bytes in %d objects allocated from:\n", - e.bytes, e.count); - for (int j = 0; j < e.bucket->depth; j++) { - const void* pc = e.bucket->stack[j]; --- -2.27.0 diff --git a/gperftools-2.10.tar.gz b/gperftools-2.10.tar.gz deleted file mode 100644 index 8de8478ad52afdd9f4356c6b01112677e83e76b1..0000000000000000000000000000000000000000 Binary files a/gperftools-2.10.tar.gz and /dev/null differ diff --git a/gperftools-2.13.tar.gz b/gperftools-2.13.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..a5bdc614e44f81aa8a4de85e8e5fbc8a43088f8e Binary files /dev/null and b/gperftools-2.13.tar.gz differ diff --git a/gperftools.spec b/gperftools.spec index 78696d11713254b7ea500db7a408392e0014c921..d8e43807d1b74d80232af8e96446e47c3f01a356 100644 --- a/gperftools.spec +++ b/gperftools.spec @@ -1,19 +1,16 @@ Name: gperftools -Version: 2.10 -Release: 3 +Version: 2.13 +Release: 1 Summary: high-performance malloc and performance analysis tools License: BSD-3-Clause URL: https://github.com/gperftools/gperftools Source0: https://github.com/gperftools/gperftools/releases/download/%{name}-%{version}/%{name}-%{version}.tar.gz -patch1: gperftools-generic-dynamic-tls.patch -Patch9000: issue-1122-fix-bus-error-on-aarch64.patch -#https://github.com/gperftools/gperftools/issues/1309 -#Patch9001: skip-arm-in-stacktrace_unittest.patch -#https://github.com/gperftools/gperftools/issues/890 -Patch9001: skip-heapchecker-in-arm-arch.patch -Patch9002: avoid-exceed-int-range.patch -Patch9003: 0001-Resolving-loongarch64-build-error.patch + +patch1: gperftools-generic-dynamic-tls.patch + +Patch9000: skip-arm-in-stacktrace_unittest.patch +#Patch9001: skip-heapchecker-in-arm-arch.patch BuildRequires: autoconf automake gcc-c++ BuildRequires: libtool libunwind-devel perl-generators @@ -108,6 +105,9 @@ LD_LIBRARY_PATH=./.libs make check %{_mandir}/man1/*.1.gz %changelog +* Fri Dec 15 2023 Qingqing Li - 2.13-1 +- upgrade to 2.13 + * Wed Jul 12 2023 doupengda - 2.10-3 - Resolving loongarch64 build error diff --git a/issue-1122-fix-bus-error-on-aarch64.patch b/issue-1122-fix-bus-error-on-aarch64.patch deleted file mode 100644 index 3ba360db00bbdace721bb2264e4599f931b6663d..0000000000000000000000000000000000000000 --- a/issue-1122-fix-bus-error-on-aarch64.patch +++ /dev/null @@ -1,42 +0,0 @@ -From 42dbe9e2ced74ae7f0f3b70daabf634edf44d3d3 Mon Sep 17 00:00:00 2001 -From: Zhipeng Xie -Date: Thu, 13 Jun 2019 23:16:43 +0800 -Subject: [PATCH] issue-1122: fix bus error on aarch64 - -According to the ARMv8 Instruction Set Overview, among other documents, -"... if SP is used as the base register then the value of the stack -pointer prior to adding any offset must be quadword (16 byte) aligned, -or else a stack alignment exception will be generated.". So, we pass -the child_stack 16 byte aligned to sys_clone. - -Signed-off-by: Zhipeng Xie ---- - src/base/linuxthreads.cc | 5 ++++- - 1 file changed, 4 insertions(+), 1 deletion(-) - -diff --git a/src/base/linuxthreads.cc b/src/base/linuxthreads.cc -index 891e70c..00b1ea3 100644 ---- a/src/base/linuxthreads.cc -+++ b/src/base/linuxthreads.cc -@@ -105,6 +105,7 @@ static int local_clone (int (*fn)(void *), void *arg, ...) - #define CLONE_STACK_SIZE 4096 - #endif - -+#define ALIGN(x, a) (((x) + (a) - 1) & ~((a) - 1)) - static int local_clone (int (*fn)(void *), void *arg, ...) { - /* Leave 4kB of gap between the callers stack and the new clone. This - * should be more than sufficient for the caller to call waitpid() until -@@ -120,7 +121,9 @@ static int local_clone (int (*fn)(void *), void *arg, ...) { - * is being debugged. This is OK and the error code will be reported - * correctly. - */ -- return sys_clone(fn, (char *)&arg - CLONE_STACK_SIZE, -+ void *child_stack = (void *)ALIGN(((unsigned long)&arg - CLONE_STACK_SIZE), -+ 16); -+ return sys_clone(fn, child_stack, - CLONE_VM|CLONE_FS|CLONE_FILES|CLONE_UNTRACED, arg, 0, 0, 0); - } - --- -1.7.12.4 - diff --git a/skip-arm-in-stacktrace_unittest.patch b/skip-arm-in-stacktrace_unittest.patch index 745395383e48836df3aa9ade702cd0dd961e4828..1ada3cf6124f862ca2fe51affc875250e8382f7f 100644 --- a/skip-arm-in-stacktrace_unittest.patch +++ b/skip-arm-in-stacktrace_unittest.patch @@ -1,21 +1,19 @@ -From abf1ed0ce1340320474a4cf3b790b7b741b9a577 Mon Sep 17 00:00:00 2001 -From: zhangyiru -Date: Mon, 29 Nov 2021 10:35:01 +0800 -Subject: [PATCH] skip stacktrace_unittest in arm +From fb7b21dc3239b9ded98d8ac1158b6ec5c1bcb84b Mon Sep 17 00:00:00 2001 +From: liqingqing_1229 +Date: Thu, 14 Dec 2023 19:28:11 +0800 +Subject: [PATCH] skip stacktrace_unittest in arm the calling of unw_step in + arm stacktrace_unittest is incorrect, but the function is not affected, so + skip it. -the calling of unw_step in arm stacktrace_unittest is incorrect, but the -function is not affected, so skip it. - -Signed-off-by: zhangyiru --- src/tests/stacktrace_unittest.cc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/tests/stacktrace_unittest.cc b/src/tests/stacktrace_unittest.cc -index e55a632..85c0bcd 100644 +index 6f20ea1..f298ecd 100644 --- a/src/tests/stacktrace_unittest.cc +++ b/src/tests/stacktrace_unittest.cc -@@ -285,8 +285,13 @@ void ATTRIBUTE_NOINLINE CheckStackTrace(int i) { +@@ -349,8 +349,13 @@ void ATTRIBUTE_NOINLINE CheckStackTrace(int i) { //-----------------------------------------------------------------------// int main(int argc, char ** argv) { @@ -27,8 +25,8 @@ index e55a632..85c0bcd 100644 + exit(77); +#endif - #if TEST_UCONTEXT_BITS - leaf_capture_fn = CaptureLeafUContext; + printf("Will test capturing stack trace with nullptr ucontext\n"); + leaf_capture_fn = CaptureLeafPlainEmptyUCP; -- -1.8.3.1 +2.33.0 diff --git a/skip-heapchecker-in-arm-arch.patch b/skip-heapchecker-in-arm-arch.patch index 32b1ffacebed0d67769977bef31e6efc3b98e4b2..22842ca88cefa93f1da6f39f6ff44ad53e818732 100644 --- a/skip-heapchecker-in-arm-arch.patch +++ b/skip-heapchecker-in-arm-arch.patch @@ -9,8 +9,7 @@ testcases. Signed-off-by: zhangyiru --- src/tests/heap-checker-death_unittest.sh | 5 +++++ - src/tests/heap-checker_unittest.sh | 5 +++++ - 2 files changed, 10 insertions(+) + 1 files changed, 5 insertions(+) diff --git a/src/tests/heap-checker-death_unittest.sh b/src/tests/heap-checker-death_unittest.sh index 69db0c9..deac493 100755 @@ -28,22 +27,6 @@ index 69db0c9..deac493 100755 # We expect BINDIR to be set in the environment. # If not, we set it to some reasonable value. BINDIR="${BINDIR:-.}" -diff --git a/src/tests/heap-checker_unittest.sh b/src/tests/heap-checker_unittest.sh -index 3c9c0e9..7c27044 100755 ---- a/src/tests/heap-checker_unittest.sh -+++ b/src/tests/heap-checker_unittest.sh -@@ -37,6 +37,11 @@ - # and heap checker via environment variables. This test makes sure - # they all play well together. - -+arch=$(uname -r | grep x86) -+if [[ $arch == "" ]]; then -+# skip this test, libtool define EXIT_SKIP=77 -+ exit 77 -+fi - # We expect BINDIR and PPROF_PATH to be set in the environment. - # If not, we set them to some reasonable values - BINDIR="${BINDIR:-.}" -- 2.27.0