Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(828)

Unified Diff: base/security_unittest.cc

Issue 2907563002: allocator/Windows: delete the old non-unified allocator-shim (Closed)
Patch Set: remove comment Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/process/memory_unittest.cc ('k') | build/config/allocator.gni » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/security_unittest.cc
diff --git a/base/security_unittest.cc b/base/security_unittest.cc
index 519c997eb0a1486834ad35f59e55321787b7b68d..61c7cf91524d8555c4d18eef0c1733bccda83540 100644
--- a/base/security_unittest.cc
+++ b/base/security_unittest.cc
@@ -14,6 +14,7 @@
#include <limits>
#include <memory>
+#include "base/allocator/features.h"
#include "base/files/file_util.h"
#include "base/logging.h"
#include "base/memory/free_deleter.h"
@@ -44,15 +45,10 @@ NOINLINE Type HideValueFromCompiler(volatile Type value) {
return value;
}
-// Tcmalloc and Windows allocator shim support setting malloc limits.
+// TCmalloc, currently supported only by Linux/CrOS, supports malloc limits.
// - NO_TCMALLOC (should be defined if compiled with use_allocator!="tcmalloc")
-// - ADDRESS_SANITIZER and SYZYASAN because they have their own memory allocator
-// - IOS does not use tcmalloc
-// - OS_MACOSX does not use tcmalloc
-// - Windows allocator shim defines ALLOCATOR_SHIM
-#if (!defined(NO_TCMALLOC) || defined(ALLOCATOR_SHIM)) && \
- !defined(ADDRESS_SANITIZER) && !defined(OS_IOS) && !defined(OS_MACOSX) && \
- !defined(SYZYASAN)
+// - ADDRESS_SANITIZER it has its own memory allocator
+#if defined(OS_LINUX) && !defined(NO_TCMALLOC) && !defined(ADDRESS_SANITIZER)
#define MALLOC_OVERFLOW_TEST(function) function
#else
#define MALLOC_OVERFLOW_TEST(function) DISABLED_##function
« no previous file with comments | « base/process/memory_unittest.cc ('k') | build/config/allocator.gni » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698