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

Unified Diff: base/trace_event/memory_dump_manager.h

Issue 1995573003: [tracing] Introduce BACKGROUND mode in MemoryInfra (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: with periodic again. Created 4 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 | « no previous file | base/trace_event/memory_dump_manager.cc » ('j') | base/trace_event/memory_dump_manager.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/trace_event/memory_dump_manager.h
diff --git a/base/trace_event/memory_dump_manager.h b/base/trace_event/memory_dump_manager.h
index 817768afedd886a41db3b62cd5130ecf9530610e..49f2e23eb642a0ac01d1b22dc0308d2fd4f3b732 100644
--- a/base/trace_event/memory_dump_manager.h
+++ b/base/trace_event/memory_dump_manager.h
@@ -18,7 +18,6 @@
#include "base/memory/ref_counted.h"
#include "base/memory/singleton.h"
#include "base/synchronization/lock.h"
-#include "base/timer/timer.h"
#include "base/trace_event/memory_dump_request_args.h"
#include "base/trace_event/process_memory_dump.h"
#include "base/trace_event/trace_event.h"
@@ -146,6 +145,7 @@ class BASE_EXPORT MemoryDumpManager : public TraceLog::EnabledStateObserver {
friend struct DefaultSingletonTraits<MemoryDumpManager>;
friend class MemoryDumpManagerDelegate;
friend class MemoryDumpManagerTest;
+ class PeriodicGlobalDumpInvokeHelper;
Primiano Tucci (use gerrit) 2016/05/26 17:20:53 I think just PeriodicDumpHelper is enough (which a
ssid 2016/05/26 22:12:54 I think after including start and stop it is more
// Descriptor used to hold information about registered MDPs.
// Some important considerations about lifetime of this object:
@@ -200,6 +200,9 @@ class BASE_EXPORT MemoryDumpManager : public TraceLog::EnabledStateObserver {
// Flagged either by the auto-disable logic or during unregistration.
bool disabled;
+ // True if the dump provider is not whitelited for background mode.
Primiano Tucci (use gerrit) 2016/05/26 17:20:53 nit: whitelisted
ssid 2016/05/26 22:12:54 Done.
+ const bool disabled_for_background_mode;
Primiano Tucci (use gerrit) 2016/05/26 17:20:53 in order to make this less confusing (initially I
ssid 2016/05/26 22:12:54 Done thanks
+
private:
friend class base::RefCountedThreadSafe<MemoryDumpProviderInfo>;
~MemoryDumpProviderInfo();
@@ -325,7 +328,7 @@ class BASE_EXPORT MemoryDumpManager : public TraceLog::EnabledStateObserver {
subtle::AtomicWord memory_tracing_enabled_;
// For time-triggered periodic dumps.
- RepeatingTimer periodic_dump_timer_;
+ std::unique_ptr<PeriodicGlobalDumpInvokeHelper> periodic_dump_helper_;
// Thread used for MemoryDumpProviders which don't specify a task runner
// affinity.
« no previous file with comments | « no previous file | base/trace_event/memory_dump_manager.cc » ('j') | base/trace_event/memory_dump_manager.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698