diff options
author | ssid <ssid@chromium.org> | 2015-08-06 06:01:30 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-08-06 13:02:02 +0000 |
commit | 90694aeec592b22686ad54bc1a225c2b44cc468e (patch) | |
tree | f9f505dc2d345162f16f5552367ff49fdd833916 /gin/v8_isolate_memory_dump_provider.cc | |
parent | d369f9805ca82ca90b6b618b45ccc4af27d574a6 (diff) | |
download | chromium_src-90694aeec592b22686ad54bc1a225c2b44cc468e.zip chromium_src-90694aeec592b22686ad54bc1a225c2b44cc468e.tar.gz chromium_src-90694aeec592b22686ad54bc1a225c2b44cc468e.tar.bz2 |
[tracing] Introduce MemoryDumpArgs to enable light and heavy dumps
The memory dump providers dump a lot of details at each dump which
causes the trace size to be huge. So, this CL introduces MemoryDumpArgs
that will be passed to each DumpProvider as an argument of OnMemoryDump.
The args specify a high or low level of detail. This provides a means to
request a light or heavy dump from the providers when necessary.
TBR=reed@google.com, jam@chromium.org
BUG=499731
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel
Review URL: https://codereview.chromium.org/1262333005
Cr-Commit-Position: refs/heads/master@{#342103}
Diffstat (limited to 'gin/v8_isolate_memory_dump_provider.cc')
-rw-r--r-- | gin/v8_isolate_memory_dump_provider.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gin/v8_isolate_memory_dump_provider.cc b/gin/v8_isolate_memory_dump_provider.cc index 28a05ec..2d261eb 100644 --- a/gin/v8_isolate_memory_dump_provider.cc +++ b/gin/v8_isolate_memory_dump_provider.cc @@ -28,7 +28,11 @@ V8IsolateMemoryDumpProvider::~V8IsolateMemoryDumpProvider() { // Called at trace dump point time. Creates a snapshot with the memory counters // for the current isolate. bool V8IsolateMemoryDumpProvider::OnMemoryDump( + const base::trace_event::MemoryDumpArgs& args, base::trace_event::ProcessMemoryDump* process_memory_dump) { + // TODO(ssid): Use MemoryDumpArgs to create light dumps when requested + // (crbug.com/499731). + if (isolate_holder_->access_mode() == IsolateHolder::kUseLocker) { v8::Locker locked(isolate_holder_->isolate()); DumpHeapStatistics(process_memory_dump); |