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

Side by Side Diff: components/metrics/proto/call_stack_profile.proto

Issue 2444143002: Add process lifetime annotations to stack samples. (Closed)
Patch Set: fixed non-windows constant Created 4 years, 1 month 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
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 // Call stack sample data for a given profiling session. 5 // Call stack sample data for a given profiling session.
6 6
7 syntax = "proto2"; 7 syntax = "proto2";
8 8
9 option optimize_for = LITE_RUNTIME; 9 option optimize_for = LITE_RUNTIME;
10 option java_outer_classname = "CallStackProfileProtos"; 10 option java_outer_classname = "CallStackProfileProtos";
11 option java_package = "org.chromium.components.metrics"; 11 option java_package = "org.chromium.components.metrics";
12 12
13 package metrics; 13 package metrics;
14 14
15 import "execution_context.proto";
16
15 // Next tag: 5 17 // Next tag: 5
16 message CallStackProfile { 18 message CallStackProfile {
17 // Describes an entry in the callstack. 19 // Describes an entry in the callstack.
18 message Entry { 20 message Entry {
19 // Instruction pointer subtracted by module base. 21 // Instruction pointer subtracted by module base.
20 optional uint64 address = 1; 22 optional uint64 address = 1;
21 23
22 // Index to the module identifier in |module_ids| of CallStackProfile. 24 // Index to the module identifier in |module_ids| of CallStackProfile.
23 optional int32 module_id_index = 2; 25 optional int32 module_id_index = 2;
24 } 26 }
25 27
26 // A sample consisting of one or more callstacks with the same stack frames 28 // A sample consisting of one or more callstacks with the same stack frames
27 // and instruction pointers. 29 // and instruction pointers.
28 message Sample { 30 message Sample {
29 // The callstack. Sample.entries[0] represents the call on the top of the 31 // The callstack. Sample.entries[0] represents the call on the top of the
30 // stack. 32 // stack.
31 repeated Entry entry = 1; 33 repeated Entry entry = 1;
32 34
33 // Number of times this stack signature occurs. 35 // Number of times this stack signature occurs.
34 optional int64 count = 2; 36 optional int64 count = 2;
37
38 // This repeating field indicates the current phase of the system such as
39 // whether it is in startup, general operation, or shutdown. It is a full
40 // list with the first sample and after that each indicates only the new
41 // phases that are achieved.
42 repeated ProcessPhase process_phase = 3;
Alexei Svitkine (slow) 2016/11/07 23:22:07 This looks good to me! I'm not sure about the act
bcwhite 2016/11/08 01:02:36 Acknowledged.
43
44 // These repeating fields provide information about current activities of
45 // the system such as whether it is (for example) writing out profile
46 // information or uploading metrics. The first sample will indicate all
47 // activities that had previously started and after that each activity that
48 // began or ended since the previous sample.
49 repeated ProcessActivity activity_begun = 4;
50 repeated ProcessActivity activity_ended = 5;
35 } 51 }
36 52
37 // Uniquely identifies a module. 53 // Uniquely identifies a module.
38 message ModuleIdentifier { 54 message ModuleIdentifier {
39 // A hash that uniquely identifies a particular program version with high 55 // A hash that uniquely identifies a particular program version with high
40 // probability. This is parsed from headers of the loaded module. 56 // probability. This is parsed from headers of the loaded module.
41 // For binaries generated by GNU tools: 57 // For binaries generated by GNU tools:
42 // Contents of the .note.gnu.build-id field. 58 // Contents of the .note.gnu.build-id field.
43 // On Windows: 59 // On Windows:
44 // GUID + AGE in the debug image headers of a module. 60 // GUID + AGE in the debug image headers of a module.
45 optional string build_id = 1; 61 optional string build_id = 1;
46 62
47 // MD5Sum Prefix of the module name. This is the same hashing scheme as used 63 // MD5Sum Prefix of the module name. This is the same hashing scheme as used
48 // to hash UMA histogram names. 64 // to hash UMA histogram names.
49 optional fixed64 name_md5_prefix = 2; 65 optional fixed64 name_md5_prefix = 2;
50 } 66 }
51 67
52 // The callstack and counts. 68 // The callstack and counts.
53 repeated Sample sample = 1; 69 repeated Sample sample = 1;
54 70
55 // List of module ids found in this sample. 71 // List of module ids found in this sample.
56 repeated ModuleIdentifier module_id = 2; 72 repeated ModuleIdentifier module_id = 2;
57 73
58 // Duration of this profile. 74 // Duration of this profile.
59 optional int32 profile_duration_ms = 3; 75 optional int32 profile_duration_ms = 3;
60 76
61 // Time between samples. 77 // Time between samples.
62 optional int32 sampling_period_ms = 4; 78 optional int32 sampling_period_ms = 4;
63 } 79 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698