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

Unified Diff: net/disk_cache/disk_cache.h

Issue 2661333002: Track SimpleCache memory usage in net/ MemoryDumpProvider (Closed)
Patch Set: Address ssid comments Created 3 years, 11 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 | net/disk_cache/simple/simple_backend_impl.h » ('j') | net/http/http_cache.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/disk_cache/disk_cache.h
diff --git a/net/disk_cache/disk_cache.h b/net/disk_cache/disk_cache.h
index 09924065c4b7bc39be9b031246e9456a0042b888..18eb2558d23c95661af0102d2aac22aa88baa040 100644
--- a/net/disk_cache/disk_cache.h
+++ b/net/disk_cache/disk_cache.h
@@ -25,6 +25,9 @@
namespace base {
class FilePath;
class SingleThreadTaskRunner;
+namespace trace_event {
+class ProcessMemoryDump;
+}
}
namespace net {
@@ -174,6 +177,13 @@ class NET_EXPORT Backend {
// Called whenever an external cache in the system reuses the resource
// referred to by |key|.
virtual void OnExternalCacheHit(const std::string& key) = 0;
+
+ // Dumps memory allocation stats. |parent_dump_absolute_name| is the name
+ // used by the parent MemoryAllocatorDump in the memory dump hierarchy.
+ // TODO(xunjieli): Investigate memory usage from backends other than
+ // SimpleCache.
ssid 2017/02/01 02:45:48 Slightly weird place to have this TODO about imple
xunjieli 2017/02/01 14:55:18 Done.
+ virtual void DumpMemoryStats(base::trace_event::ProcessMemoryDump* pmd,
+ const std::string& parent_absolute_name) const {}
};
// This interface represents an entry in the disk cache.
« no previous file with comments | « no previous file | net/disk_cache/simple/simple_backend_impl.h » ('j') | net/http/http_cache.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698