Chromium Code Reviews| Index: content/child/child_discardable_shared_memory_manager.h |
| diff --git a/content/child/child_discardable_shared_memory_manager.h b/content/child/child_discardable_shared_memory_manager.h |
| index 881b59ec1dfe69a179af749bccb9e963faf4148c..02e0076c21875021a7471452862068befa83a57e 100644 |
| --- a/content/child/child_discardable_shared_memory_manager.h |
| +++ b/content/child/child_discardable_shared_memory_manager.h |
| @@ -8,6 +8,7 @@ |
| #include "base/memory/discardable_memory_allocator.h" |
| #include "base/memory/ref_counted.h" |
| #include "base/synchronization/lock.h" |
| +#include "base/trace_event/memory_dump_provider.h" |
| #include "content/child/thread_safe_sender.h" |
| #include "content/common/content_export.h" |
| #include "content/common/discardable_shared_memory_heap.h" |
| @@ -18,7 +19,8 @@ namespace content { |
| // Implementation of DiscardableMemoryAllocator that allocates |
| // discardable memory segments through the browser process. |
| class CONTENT_EXPORT ChildDiscardableSharedMemoryManager |
| - : public base::DiscardableMemoryAllocator { |
| + : public base::DiscardableMemoryAllocator, |
| + public base::trace_event::MemoryDumpProvider { |
| public: |
| explicit ChildDiscardableSharedMemoryManager(ThreadSafeSender* sender); |
| ~ChildDiscardableSharedMemoryManager() override; |
| @@ -34,6 +36,10 @@ class CONTENT_EXPORT ChildDiscardableSharedMemoryManager |
| void UnlockSpan(DiscardableSharedMemoryHeap::Span* span); |
| void ReleaseSpan(scoped_ptr<DiscardableSharedMemoryHeap::Span> span); |
| + // base::trace_event::MemoryDumpProvider implementation: |
|
reveman
2015/04/23 17:32:30
nit: "Overridden from base::trace_event::MemoryDum
ssid
2015/04/24 11:23:04
Done.
|
| + bool DumpInto(base::trace_event::ProcessMemoryDump* pmd) override; |
| + const char* GetFriendlyName() const override; |
|
reveman
2015/04/23 17:32:30
nit: please move this functions just below the fun
ssid
2015/04/24 11:23:04
Done.
|
| + |
| private: |
| scoped_ptr<base::DiscardableSharedMemory> |
| AllocateLockedDiscardableSharedMemory(size_t size, |