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

Unified Diff: components/metrics/public/interfaces/call_stack_profile_collector.mojom

Issue 2254743003: Introduce mojo interface for collecting StackSamplingProfiler data (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkcr
Patch Set: disable test for iOS Created 4 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 side-by-side diff with in-line comments
Download patch
Index: components/metrics/public/interfaces/call_stack_profile_collector.mojom
diff --git a/components/metrics/public/interfaces/call_stack_profile_collector.mojom b/components/metrics/public/interfaces/call_stack_profile_collector.mojom
new file mode 100644
index 0000000000000000000000000000000000000000..80e9ac3ccc308515134335c1e3717ccdcfc411d3
--- /dev/null
+++ b/components/metrics/public/interfaces/call_stack_profile_collector.mojom
@@ -0,0 +1,40 @@
+// Copyright 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+module metrics.mojom;
+
+import "mojo/common/common_custom_types.mojom";
+
+// These structs mirror the corresponding types in base::StackSamplingProfiler.
+
+struct CallStackModule {
+ uint64 base_address;
+ string id;
+ mojo.common.mojom.FilePath filename;
+};
+
+struct CallStackFrame {
+ uint64 instruction_pointer;
+ uint64 module_index;
+};
+
+struct CallStackProfile {
+ array<CallStackModule> modules;
+ array<array<CallStackFrame>> samples;
+ mojo.common.mojom.TimeDelta profile_duration;
+ mojo.common.mojom.TimeDelta sampling_period;
+};
+
+enum Trigger {
+ UNKNOWN,
+ PROCESS_STARTUP,
+ JANKY_TASK,
+ THREAD_HUNG,
+};
+
+interface CallStackProfileCollector {
+ Collect(Trigger trigger, bool preserve_sample_ordering,
+ mojo.common.mojom.TimeTicks start_timestamp,
+ array<CallStackProfile> profiles);
+};

Powered by Google App Engine
This is Rietveld 408576698