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

Unified Diff: base/trace_event/malloc_dump_provider.h

Issue 2890363003: Enable sharding of AllocationRegister on desktop. (Closed)
Patch Set: comments from primiano, thakis. 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/trace_event/heap_profiler_allocation_register.cc ('k') | base/trace_event/malloc_dump_provider.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/trace_event/malloc_dump_provider.h
diff --git a/base/trace_event/malloc_dump_provider.h b/base/trace_event/malloc_dump_provider.h
index 384033c9b82abc55125405e9a29ede7aa9597c08..08495a7e4e934425bf51fd58cf7acdbeab7999aa 100644
--- a/base/trace_event/malloc_dump_provider.h
+++ b/base/trace_event/malloc_dump_provider.h
@@ -10,9 +10,9 @@
#include "base/macros.h"
#include "base/memory/singleton.h"
-#include "base/synchronization/lock.h"
#include "base/threading/platform_thread.h"
#include "base/trace_event/memory_dump_provider.h"
+#include "base/trace_event/sharded_allocation_register.h"
#include "build/build_config.h"
#if defined(OS_LINUX) || defined(OS_ANDROID) || defined(OS_WIN) || \
@@ -23,8 +23,6 @@
namespace base {
namespace trace_event {
-class AllocationRegister;
-
// Dump provider which collects process-wide memory stats.
class BASE_EXPORT MallocDumpProvider : public MemoryDumpProvider {
public:
@@ -51,9 +49,7 @@ class BASE_EXPORT MallocDumpProvider : public MemoryDumpProvider {
~MallocDumpProvider() override;
// For heap profiling.
- bool heap_profiler_enabled_;
- std::unique_ptr<AllocationRegister> allocation_register_;
- Lock allocation_register_lock_;
+ ShardedAllocationRegister allocation_register_;
// When in OnMemoryDump(), this contains the current thread ID.
// This is to prevent re-entrancy in the heap profiler when the heap dump
« no previous file with comments | « base/trace_event/heap_profiler_allocation_register.cc ('k') | base/trace_event/malloc_dump_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698