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

Side by Side Diff: gin/v8_isolate_memory_dump_provider.h

Issue 1262333005: [tracing] Introduce MemoryDumpArgs to enable light and heavy dumps (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 5 years, 4 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 unified diff | Download patch
« no previous file with comments | « content/common/host_shared_bitmap_manager.cc ('k') | gin/v8_isolate_memory_dump_provider.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef GIN_V8_ISOLATE_MEMORY_DUMP_PROVIDER_H_ 5 #ifndef GIN_V8_ISOLATE_MEMORY_DUMP_PROVIDER_H_
6 #define GIN_V8_ISOLATE_MEMORY_DUMP_PROVIDER_H_ 6 #define GIN_V8_ISOLATE_MEMORY_DUMP_PROVIDER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/trace_event/memory_dump_provider.h" 10 #include "base/trace_event/memory_dump_provider.h"
11 #include "gin/gin_export.h" 11 #include "gin/gin_export.h"
12 12
13 namespace gin { 13 namespace gin {
14 14
15 class IsolateHolder; 15 class IsolateHolder;
16 16
17 // Memory dump provider for the chrome://tracing infrastructure. It dumps 17 // Memory dump provider for the chrome://tracing infrastructure. It dumps
18 // summarized memory stats about the V8 Isolate. 18 // summarized memory stats about the V8 Isolate.
19 class V8IsolateMemoryDumpProvider 19 class V8IsolateMemoryDumpProvider
20 : public base::trace_event::MemoryDumpProvider { 20 : public base::trace_event::MemoryDumpProvider {
21 public: 21 public:
22 explicit V8IsolateMemoryDumpProvider(IsolateHolder* isolate_holder); 22 explicit V8IsolateMemoryDumpProvider(IsolateHolder* isolate_holder);
23 ~V8IsolateMemoryDumpProvider() override; 23 ~V8IsolateMemoryDumpProvider() override;
24 24
25 // MemoryDumpProvider implementation. 25 // MemoryDumpProvider implementation.
26 bool OnMemoryDump( 26 bool OnMemoryDump(
27 const base::trace_event::MemoryDumpArgs& args,
27 base::trace_event::ProcessMemoryDump* process_memory_dump) override; 28 base::trace_event::ProcessMemoryDump* process_memory_dump) override;
28 29
29 private: 30 private:
30 void DumpHeapStatistics( 31 void DumpHeapStatistics(
31 base::trace_event::ProcessMemoryDump* process_memory_dump); 32 base::trace_event::ProcessMemoryDump* process_memory_dump);
32 33
33 IsolateHolder* isolate_holder_; // Not owned. 34 IsolateHolder* isolate_holder_; // Not owned.
34 35
35 DISALLOW_COPY_AND_ASSIGN(V8IsolateMemoryDumpProvider); 36 DISALLOW_COPY_AND_ASSIGN(V8IsolateMemoryDumpProvider);
36 }; 37 };
37 38
38 } // namespace gin 39 } // namespace gin
39 40
40 #endif // GIN_V8_ISOLATE_MEMORY_DUMP_PROVIDER_H_ 41 #endif // GIN_V8_ISOLATE_MEMORY_DUMP_PROVIDER_H_
OLDNEW
« no previous file with comments | « content/common/host_shared_bitmap_manager.cc ('k') | gin/v8_isolate_memory_dump_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698