summaryrefslogtreecommitdiffstats
path: root/base/process/memory.h
diff options
context:
space:
mode:
authormostynb@opera.com <mostynb@opera.com@0039d316-1c4b-4281-b951-d872f2087c98>2014-03-04 04:54:26 +0000
committermostynb@opera.com <mostynb@opera.com@0039d316-1c4b-4281-b951-d872f2087c98>2014-03-04 04:54:26 +0000
commit6bad17eddafce5744209f2e6d3203a64731ce4d2 (patch)
tree13d827ebd391706d4e34c558c92ab5295b46748a /base/process/memory.h
parent4d7552f22c66e8db1861947f013565ad3a64d9c7 (diff)
downloadchromium_src-6bad17eddafce5744209f2e6d3203a64731ce4d2.zip
chromium_src-6bad17eddafce5744209f2e6d3203a64731ce4d2.tar.gz
chromium_src-6bad17eddafce5744209f2e6d3203a64731ce4d2.tar.bz2
only do linux pvalloc OutOfMemoryDeathTest on non-tcmalloc glibc builds
We only override libc's pvalloc if when using glibc and not tcmalloc (in base/process/memory_linux.cc), and pvalloc is not always available on uclibc, so let's use the same ifdef in the unit test. Review URL: https://codereview.chromium.org/184313002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@254659 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/process/memory.h')
-rw-r--r--base/process/memory.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/base/process/memory.h b/base/process/memory.h
index e6696cb..8187032 100644
--- a/base/process/memory.h
+++ b/base/process/memory.h
@@ -14,6 +14,14 @@
#include <windows.h>
#endif
+#ifdef PVALLOC_AVAILABLE
+// Build config explicitly tells us whether or not pvalloc is available.
+#elif defined(LIBC_GLIBC) && !defined(USE_TCMALLOC)
+#define PVALLOC_AVAILABLE 1
+#else
+#define PVALLOC_AVAILABLE 0
+#endif
+
namespace base {
// Enables low fragmentation heap (LFH) for every heaps of this process. This