diff options
author | jamesr@chromium.org <jamesr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-09-21 03:51:05 +0000 |
---|---|---|
committer | jamesr@chromium.org <jamesr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-09-21 03:51:05 +0000 |
commit | 80a91d77f1076149ff8abe301fed8e9314fbc162 (patch) | |
tree | 927ea1b2730bafc6c87654193607911a22df415f /third_party | |
parent | b53d0f29c8f85db1ace3a052a70eece6b64bdd30 (diff) | |
download | chromium_src-80a91d77f1076149ff8abe301fed8e9314fbc162.zip chromium_src-80a91d77f1076149ff8abe301fed8e9314fbc162.tar.gz chromium_src-80a91d77f1076149ff8abe301fed8e9314fbc162.tar.bz2 |
Enable tcmalloc validation by default in debug builds
BUG=none
TEST=
Review URL: http://codereview.chromium.org/7976011
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@102083 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'third_party')
-rw-r--r-- | third_party/tcmalloc/chromium/src/tcmalloc.cc | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/third_party/tcmalloc/chromium/src/tcmalloc.cc b/third_party/tcmalloc/chromium/src/tcmalloc.cc index 4afe5e7..51fe5b3 100644 --- a/third_party/tcmalloc/chromium/src/tcmalloc.cc +++ b/third_party/tcmalloc/chromium/src/tcmalloc.cc @@ -1791,11 +1791,13 @@ void *(*__MALLOC_HOOK_VOLATILE __memalign_hook)(size_t, size_t, const void *) = // to be hashed encoding of the location, so that they can't be copied over a // different region (by accident) without being detected (most of the time). -// Uncomment the following define to turn on all the TCMalloc checking. -// It will cost abotu 2% in performance, but it will catch double frees (most of +// Enable the following define to turn on all the TCMalloc checking. +// It will cost about 2% in performance, but it will catch double frees (most of // the time), and will often catch allocated-buffer overrun errors. This // validation is only active when TCMalloc is used as the allocator. -// #define TCMALLOC_VALIDATION +#ifndef NDEBUG +#define TCMALLOC_VALIDATION +#endif #if !defined(TCMALLOC_VALIDATION) |