Accepting request 235134 from devel:libraries:c_c++

Update to latest release, 2.2; Released 3 May 2014; removed patches that have been incorporated upstream. (forwarded request 235130 from ganglia)

OBS-URL: https://build.opensuse.org/request/show/235134
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/gperftools?expand=0&rev=9
This commit is contained in:
Stephan Kulow 2014-05-23 05:51:41 +00:00 committed by Git OBS Bridge
commit 77f7d251c2
8 changed files with 63 additions and 169 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:ce1c732c65c7d1151bfddedbdf21cb0a6fed3063c2ea80d988baf219e608a249
size 1085081

3
gperftools-2.2.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:2407799467db2753a4a70c00dbb1b8429e23998427df31ee96361d2115cd63a4
size 1367117

View File

@ -1,29 +0,0 @@
Index: gperftools-2.0/src/base/linux_syscall_support.h
===================================================================
--- gperftools-2.0.orig/src/base/linux_syscall_support.h
+++ gperftools-2.0/src/base/linux_syscall_support.h
@@ -250,7 +250,7 @@ struct siginfo;
struct kernel_old_sigaction {
union {
void (*sa_handler_)(int);
- void (*sa_sigaction_)(int, struct siginfo *, void *);
+ void (*sa_sigaction_)(int, siginfo_t *, void *);
};
unsigned long sa_mask;
unsigned long sa_flags;
@@ -287,13 +287,13 @@ struct kernel_sigaction {
unsigned long sa_flags;
union {
void (*sa_handler_)(int);
- void (*sa_sigaction_)(int, struct siginfo *, void *);
+ void (*sa_sigaction_)(int, siginfo_t *, void *);
};
struct kernel_sigset_t sa_mask;
#else
union {
void (*sa_handler_)(int);
- void (*sa_sigaction_)(int, struct siginfo *, void *);
+ void (*sa_sigaction_)(int, siginfo_t *, void *);
};
unsigned long sa_flags;
void (*sa_restorer)(void);

View File

@ -1,3 +1,61 @@
-------------------------------------------------------------------
Mon May 19 15:39:40 UTC 2014 - cgardner@suse.com
- gperftools 2.2, released 3 May 2014.
* issue 620 (crash on windows when c runtime dll is reloaded) was
fixed
* a number of fixes for a number compilers and platforms. Notably
Visual Studio 2013, recent mingw with c++ threads and some OSX
fixes.
* we now have mips and mips64 support! (courtesy of Jovan Zelincevic,
Jean Lee, user xiaoyur347 and others)
* we now have aarch64 (aka arm64) support! (contributed by Riku
Voipio)
* there's now support for ppc64-le (by Raphael Moreira Zinsly and
Adhemerval Zanella)
* there's now some support of uclibc (contributed by user xiaoyur347)
* google/ headers will now give you deprecation warning. They are
deprecated since 2.0
* there's now new api: tc_malloc_skip_new_handler (ported from chromium
fork)
* issue-557: added support for dumping heap profile via signal (by
Jean Lee)
* issue-567: Petr Hosek contributed SysAllocator support for windows
* Joonsoo Kim contributed several speedups for central freelist code
* TCMALLOC_MAX_TOTAL_THREAD_CACHE_BYTES environment variable now works
* configure scripts are now using AM_MAINTAINER_MODE. It'll only
affect folks who modify source from .tar.gz and want automake to
automatically rebuild Makefile-s. See automake documentation for
that.
* issue-586: detect main executable even if PIE is active (based on
patch by user themastermind1). Notably, it fixes profiler use with
ruby.
* there is now support for switching backtrace capturing method at
runtime (via TCMALLOC_STACKTRACE_METHOD and
TCMALLOC_STACKTRACE_METHOD_VERBOSE environment variables)
* there is new backtrace capturing method using -finstrument-functions
prologues contributed by user xiaoyur347
* few cases of crashes/deadlocks in profiler were addressed. See
(famous) issue-66, issue-547 and issue-579.
* issue-464 (memory corruption in debugalloc's realloc after
memallign) is now fixed
* tcmalloc is now able to release memory back to OS on windows
(issue-489). The code was ported from chromium fork (by a number of
authors).
* Together with issue-489 we ported chromium's "aggressive decommit"
mode. In this mode (settable via malloc extension and via
environment variable TCMALLOC_AGGRESSIVE_DECOMMIT), free pages are
returned back to OS immediately.
* MallocExtension::instance() is now faster (based on patch by
Adhemerval Zanella)
* issue-610 (hangs on windows in multibyte locales) is now fixed
- Removed the following patches. All have either been incorporated
upstream or are no longer applicable in current distros.
* gperftools_fix_multiple_install_headers.patch
* gperftools-glibc216.patch
* spinlock-rand.patch
* gperftools_use_older_autoconf.diff
-------------------------------------------------------------------
Mon Aug 12 15:49:12 UTC 2013 - cgardner@suse.com

View File

@ -17,17 +17,13 @@
Name: gperftools
Version: 2.1
Version: 2.2
Release: 0
Url: http://code.google.com/p/gperftools/
Source0: %{name}-%{version}.tar.bz2
Source0: %{name}-%{version}.tar.gz
Patch4: %{name}-fix_docdir.patch
# Patch11: %{name}_fix_multiple_install_headers.patch
Patch12: %{name}_fix_unassigned_malloc_in_unittest.patch
Patch14: %{name}_gcc46.patch
#Patch15: %{name}-glibc216.patch
#Patch16: spinlock-rand.patch
Patch17: %{name}_use_older_autoconf.diff
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: gcc-c++
@ -65,12 +61,8 @@ files for developing applications that use the gperftools package.
%prep
%setup -q
%patch4 -p1
#patch11 -p1
%patch12 -p1
%patch14 -p1
#patch15 -p1
#patch16 -p1
%patch17 -p1
%build
autoreconf -fi

View File

@ -1,77 +0,0 @@
Index: gperftools-2.0/Makefile.am
===================================================================
--- gperftools-2.0.orig/Makefile.am
+++ gperftools-2.0/Makefile.am
@@ -121,8 +121,7 @@ googleinclude_HEADERS = \
src/google/malloc_hook_c.h \
src/google/profiler.h \
src/google/stacktrace.h \
- src/google/tcmalloc.h \
- src/windows/google/tcmalloc.h
+ src/google/tcmalloc.h
docdir = $(prefix)/share/doc/packages/$(PACKAGE)
# This is for HTML and other documentation you want to install.
@@ -296,8 +295,6 @@ TESTS += low_level_alloc_unittest
WINDOWS_PROJECTS += vsprojects/low_level_alloc_unittest/low_level_alloc_unittest.vcproj
LOW_LEVEL_ALLOC_UNITTEST_INCLUDES = src/base/low_level_alloc.h \
src/base/basictypes.h \
- src/gperftools/malloc_hook.h \
- src/gperftools/malloc_hook_c.h \
src/malloc_hook-inl.h \
src/malloc_hook_mmap_linux.h \
src/malloc_hook_mmap_freebsd.h \
@@ -432,10 +429,9 @@ S_TCMALLOC_MINIMAL_INCLUDES = src/common
SG_TCMALLOC_MINIMAL_INCLUDES = src/gperftools/malloc_hook.h \
src/gperftools/malloc_hook_c.h \
src/gperftools/malloc_extension.h \
- src/gperftools/malloc_extension_c.h \
- src/gperftools/stacktrace.h
+ src/gperftools/malloc_extension_c.h
TCMALLOC_MINIMAL_INCLUDES = $(S_TCMALLOC_MINIMAL_INCLUDES) $(SG_TCMALLOC_MINIMAL_INCLUDES)
-perftoolsinclude_HEADERS += $(SG_TCMALLOC_MINIMAL_INCLUDES)
+# perftoolsinclude_HEADERS += $(SG_TCMALLOC_MINIMAL_INCLUDES)
### Making the library
@@ -627,9 +623,7 @@ TESTS += malloc_extension_test
WINDOWS_PROJECTS += vsprojects/malloc_extension_test/malloc_extension_test.vcproj
malloc_extension_test_SOURCES = src/tests/malloc_extension_test.cc \
src/config_for_unittests.h \
- src/base/logging.h \
- src/gperftools/malloc_extension.h \
- src/gperftools/malloc_extension_c.h
+ src/base/logging.h
malloc_extension_test_CXXFLAGS = $(PTHREAD_CFLAGS) $(AM_CXXFLAGS)
malloc_extension_test_LDFLAGS = $(PTHREAD_CFLAGS) $(TCMALLOC_FLAGS)
malloc_extension_test_LDADD = $(LIBTCMALLOC_MINIMAL) $(PTHREAD_LIBS)
@@ -896,8 +890,7 @@ LIBS_TO_WEAKEN += libtcmalloc.la
### Unittests
TESTS += tcmalloc_unittest
-TCMALLOC_UNITTEST_INCLUDES = src/config_for_unittests.h \
- src/gperftools/malloc_extension.h
+TCMALLOC_UNITTEST_INCLUDES = src/config_for_unittests.h
tcmalloc_unittest_SOURCES = src/tests/tcmalloc_unittest.cc \
src/tcmalloc.h \
src/tests/testutil.h src/tests/testutil.cc \
@@ -988,8 +981,7 @@ sampling_test.sh$(EXEEXT): $(top_srcdir)
# The -g is so pprof can get symbol information.
noinst_PROGRAMS += sampling_test
SAMPLING_TEST_INCLUDES = src/config_for_unittests.h \
- src/base/logging.h \
- src/gperftools/malloc_extension.h
+ src/base/logging.h
sampling_test_SOURCES = src/tests/sampling_test.cc \
$(SAMPLING_TEST_INCLUDES)
sampling_test_CXXFLAGS = -g $(PTHREAD_CFLAGS) $(AM_CXXFLAGS)
@@ -1186,8 +1178,7 @@ S_CPU_PROFILER_INCLUDES = src/profiledat
src/base/sysinfo.h \
$(SPINLOCK_INCLUDES) \
$(LOGGING_INCLUDES)
-SG_CPU_PROFILER_INCLUDES = src/gperftools/profiler.h \
- src/gperftools/stacktrace.h
+SG_CPU_PROFILER_INCLUDES = src/gperftools/profiler.h
CPU_PROFILER_INCLUDES = $(S_CPU_PROFILER_INCLUDES) $(SG_CPU_PROFILER_INCLUDES)
perftoolsinclude_HEADERS += $(SG_CPU_PROFILER_INCLUDES)

View File

@ -1,13 +0,0 @@
Index: gperftools-2.1/configure.ac
===================================================================
--- gperftools-2.1.orig/configure.ac
+++ gperftools-2.1/configure.ac
@@ -2,7 +2,7 @@
## In general, the safest way to proceed is to run ./autogen.sh
# make sure we're interpreted by some minimal autoconf
-AC_PREREQ([2.68])
+AC_PREREQ([2.59])
AC_INIT([gperftools],[2.1],[google-perftools@googlegroups.com])
# Update this value for every release! (A:B:C will map to foo.so.(A-C).C.B)

View File

@ -1,37 +0,0 @@
diff --git a/src/base/spinlock_internal.cc b/src/base/spinlock_internal.cc
index b9fadde..172a637 100644
--- a/src/base/spinlock_internal.cc
+++ b/src/base/spinlock_internal.cc
@@ -80,6 +80,7 @@ int32 SpinLockWait(volatile Atomic32 *w, int n,
static int SuggestedDelayNS(int loop) {
// Weak pseudo-random number generator to get some spread between threads
// when many are spinning.
+#ifdef BASE_HAS_ATOMIC64
static base::subtle::Atomic64 rand;
uint64 r = base::subtle::NoBarrier_Load(&rand);
r = 0x5deece66dLL * r + 0xb; // numbers from nrand48()
@@ -96,6 +97,24 @@ static int SuggestedDelayNS(int loop) {
// The futex path multiplies this by 16, since we expect explicit wakeups
// almost always on that path.
return r >> (44 - (loop >> 3));
+#else
+ static Atomic32 rand;
+ uint32 r = base::subtle::NoBarrier_Load(&rand);
+ r = 0x343fd * r + 0x269ec3; // numbers from MSVC++
+ base::subtle::NoBarrier_Store(&rand, r);
+
+ r <<= 1; // 31-bit random number now in top 31-bits.
+ if (loop < 0 || loop > 32) { // limit loop to 0..32
+ loop = 32;
+ }
+ // loop>>3 cannot exceed 4 because loop cannot exceed 32.
+ // Select top 20..24 bits of lower 31 bits,
+ // giving approximately 0ms to 16ms.
+ // Mean is exponential in loop for first 32 iterations, then 8ms.
+ // The futex path multiplies this by 16, since we expect explicit wakeups
+ // almost always on that path.
+ return r >> (12 - (loop >> 3));
+#endif
}
} // namespace internal