Index: content/browser/dom_storage/dom_storage_area.cc |
diff --git a/content/browser/dom_storage/dom_storage_area.cc b/content/browser/dom_storage/dom_storage_area.cc |
index 884082f15dee8a41260b244a4a3fff96a8668793..69c90596b0767a9b23baa5a6ff0930830c202257 100644 |
--- a/content/browser/dom_storage/dom_storage_area.cc |
+++ b/content/browser/dom_storage/dom_storage_area.cc |
@@ -374,6 +374,11 @@ void DOMStorageArea::OnMemoryDump(base::trace_event::ProcessMemoryDump* pmd) { |
pmd->AddSuballocation(commit_batch_mad->guid(), system_allocator_name); |
} |
+ // Report memory usage for local storage backing. The session storage usage |
+ // will be reported by DOMStorageContextImpl. |
+ if (namespace_id_ == kLocalStorageNamespaceId && backing_) |
+ backing_->ReportMemoryUsage(pmd, name + "/local_storage"); |
+ |
// Do not add storage map usage if less than 1KB. |
if (map_->bytes_used() < 1024) |
return; |
@@ -384,7 +389,6 @@ void DOMStorageArea::OnMemoryDump(base::trace_event::ProcessMemoryDump* pmd) { |
map_->bytes_used()); |
if (system_allocator_name) |
pmd->AddSuballocation(map_mad->guid(), system_allocator_name); |
- // TODO(ssid): Add memory usage of local backing storage crbug.com/605785. |
} |
void DOMStorageArea::InitialImportIfNeeded() { |