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

Unified Diff: gpu/command_buffer/service/transfer_buffer_manager.cc

Issue 2535213002: [WIP] Add SharedMemoryTracker to dump base::SharedMemory usage
Patch Set: Remove unneeded calls Created 4 years, 1 month 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
Index: gpu/command_buffer/service/transfer_buffer_manager.cc
diff --git a/gpu/command_buffer/service/transfer_buffer_manager.cc b/gpu/command_buffer/service/transfer_buffer_manager.cc
index 9f583b9f656cee8958219f7c84253323e3d1bbb2..5e7373468fc77dbbe1184550d8a7e059c011d7ea 100644
--- a/gpu/command_buffer/service/transfer_buffer_manager.cc
+++ b/gpu/command_buffer/service/transfer_buffer_manager.cc
@@ -10,6 +10,7 @@
#include <memory>
#include "base/logging.h"
+#include "base/memory/shared_memory_dump_provider.h"
#include "base/process/process_handle.h"
#include "base/strings/stringprintf.h"
#include "base/threading/thread_task_runner_handle.h"
@@ -121,6 +122,8 @@ bool TransferBufferManager::OnMemoryDump(
dump->AddScalar(MemoryAllocatorDump::kNameSize,
MemoryAllocatorDump::kUnitsBytes,
shared_memory_bytes_allocated_);
+ base::SharedMemoryDumpProvider::GetInstance()->AddSuballocation(
+ pmd, dump->guid());
// Early out, no need for more detail in a BACKGROUND dump.
return true;

Powered by Google App Engine
This is Rietveld 408576698