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
3 // found in the LICENSE file.
7 option optimize_for = LITE_RUNTIME;
11 // Stores output generated by the "perf stat" command.
13 // See https://perf.wiki.kernel.org/index.php/Tutorial#Counting_with_perf_stat
17 message PerfStatProto {
18 // All lines printed by "perf stat".
19 repeated PerfStatLine line = 1;
21 // The command line used to run "perf stat".
22 optional string command_line = 2;
24 // Represents one line of "perf stat" output.
27 // Time since the start of the "perf stat" command, in milliseconds.
29 // When running "perf stat" and printing the counters at the end, this is
30 // the total time taken by the run.
32 // Alternatively, "perf stat" can print its stats at regular intervals until
33 // the end of the run. For example, if "perf stat" runs for one second and
34 // prints at 200-ms intervals, it will print counter values for each event
35 // a total of five times. According to "perf stat" usage instructions, the
36 // printing interval should be no less than 100 ms.
37 optional uint64 time_ms = 1;
39 // Current count value of the event being counted. May be different from the
40 // nominal counter value reported by "perf stat", depending on the event.
41 // For example, memory access counters are in units of 64 bytes. A counter
42 // value of 1024 would represent 65536 bytes, and we would set this field to
44 optional uint64 count = 2;
46 // Name of event whose counter is listed on this line.
47 // This string should also appear as part of |PerfStatProto::command_line|.
48 // "perf stat" will preserve the event name exactly as it is passed in via
50 optional string event = 3;