| Index: gpu/command_buffer/client/cmd_buffer_helper.cc
|
| diff --git a/gpu/command_buffer/client/cmd_buffer_helper.cc b/gpu/command_buffer/client/cmd_buffer_helper.cc
|
| index 0304b8f7e5d1ae6d4322bdd889729477746a822c..e08c78c03cf8dcaa37c5991e28bbd4bbe8b02a5e 100644
|
| --- a/gpu/command_buffer/client/cmd_buffer_helper.cc
|
| +++ b/gpu/command_buffer/client/cmd_buffer_helper.cc
|
| @@ -340,9 +340,6 @@
|
| bool CommandBufferHelper::OnMemoryDump(
|
| const base::trace_event::MemoryDumpArgs& args,
|
| base::trace_event::ProcessMemoryDump* pmd) {
|
| - using base::trace_event::MemoryAllocatorDump;
|
| - using base::trace_event::MemoryDumpLevelOfDetail;
|
| -
|
| if (!HaveRingBuffer())
|
| return true;
|
|
|
| @@ -350,20 +347,19 @@
|
| base::trace_event::MemoryDumpManager::GetInstance()
|
| ->GetTracingProcessId();
|
|
|
| - MemoryAllocatorDump* dump = pmd->CreateAllocatorDump(base::StringPrintf(
|
| - "gpu/command_buffer_memory/buffer_%d", ring_buffer_id_));
|
| - dump->AddScalar(MemoryAllocatorDump::kNameSize,
|
| - MemoryAllocatorDump::kUnitsBytes, ring_buffer_size_);
|
| -
|
| - if (args.level_of_detail != MemoryDumpLevelOfDetail::BACKGROUND) {
|
| - dump->AddScalar(
|
| - "free_size", MemoryAllocatorDump::kUnitsBytes,
|
| - GetTotalFreeEntriesNoWaiting() * sizeof(CommandBufferEntry));
|
| - auto guid = GetBufferGUIDForTracing(tracing_process_id, ring_buffer_id_);
|
| - const int kImportance = 2;
|
| - pmd->CreateSharedGlobalAllocatorDump(guid);
|
| - pmd->AddOwnershipEdge(dump->guid(), guid, kImportance);
|
| - }
|
| + base::trace_event::MemoryAllocatorDump* dump =
|
| + pmd->CreateAllocatorDump(base::StringPrintf(
|
| + "gpu/command_buffer_memory/buffer_%d", ring_buffer_id_));
|
| + dump->AddScalar(base::trace_event::MemoryAllocatorDump::kNameSize,
|
| + base::trace_event::MemoryAllocatorDump::kUnitsBytes,
|
| + ring_buffer_size_);
|
| + dump->AddScalar("free_size",
|
| + base::trace_event::MemoryAllocatorDump::kUnitsBytes,
|
| + GetTotalFreeEntriesNoWaiting() * sizeof(CommandBufferEntry));
|
| + auto guid = GetBufferGUIDForTracing(tracing_process_id, ring_buffer_id_);
|
| + const int kImportance = 2;
|
| + pmd->CreateSharedGlobalAllocatorDump(guid);
|
| + pmd->AddOwnershipEdge(dump->guid(), guid, kImportance);
|
|
|
| return true;
|
| }
|
|
|