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

Unified Diff: runtime/vm/service.cc

Issue 1533323004: Support narrowing a timeline to a given time window (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years 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
« no previous file with comments | « runtime/vm/profiler.cc ('k') | runtime/vm/timeline.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/service.cc
diff --git a/runtime/vm/service.cc b/runtime/vm/service.cc
index 963b820b7faaead06a7d7bf2f8b6eaa60155aec6..4735b51036403ae329e2e5fc0c99c7b2f773dbc1 100644
--- a/runtime/vm/service.cc
+++ b/runtime/vm/service.cc
@@ -2635,6 +2635,8 @@ static bool ClearVMTimeline(Thread* thread, JSONStream* js) {
static const MethodParameter* get_vm_timeline_params[] = {
NO_ISOLATE_PARAMETER,
+ new Int64Parameter("timeOriginMicros", false),
+ new Int64Parameter("timeExtentMicros", false),
NULL,
};
@@ -2647,7 +2649,11 @@ static bool GetVMTimeline(Thread* thread, JSONStream* js) {
TimelineEventRecorder* timeline_recorder = Timeline::recorder();
// TODO(johnmccutchan): Return an error.
ASSERT(timeline_recorder != NULL);
- TimelineEventFilter filter;
+ int64_t time_origin_micros =
+ Int64Parameter::Parse(js->LookupParam("timeOriginMicros"));
+ int64_t time_extent_micros =
+ Int64Parameter::Parse(js->LookupParam("timeExtentMicros"));
+ TimelineEventFilter filter(time_origin_micros, time_extent_micros);
timeline_recorder->PrintJSON(js, &filter);
return true;
}
« no previous file with comments | « runtime/vm/profiler.cc ('k') | runtime/vm/timeline.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698