Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

perf tools: Move events_stats struct to event.h

This is the only bit of hist.h that session.[ch] will end up using, so
move it out of hist.h to make that abundantly clear.

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Borislav Petkov <bp@suse.de>
Cc: David Ahern <dsahern@gmail.com>
Cc: Don Zickus <dzickus@redhat.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Jean Pihet <jean.pihet@linaro.org>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Link: http://lkml.kernel.org/n/tip-l9ftsl21ggw0c1g2ig87otmd@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>

+26 -26
+26
tools/perf/util/event.h
··· 190 190 PERF_RECORD_HEADER_MAX 191 191 }; 192 192 193 + /* 194 + * The kernel collects the number of events it couldn't send in a stretch and 195 + * when possible sends this number in a PERF_RECORD_LOST event. The number of 196 + * such "chunks" of lost events is stored in .nr_events[PERF_EVENT_LOST] while 197 + * total_lost tells exactly how many events the kernel in fact lost, i.e. it is 198 + * the sum of all struct lost_event.lost fields reported. 199 + * 200 + * The total_period is needed because by default auto-freq is used, so 201 + * multipling nr_events[PERF_EVENT_SAMPLE] by a frequency isn't possible to get 202 + * the total number of low level events, it is necessary to to sum all struct 203 + * sample_event.period and stash the result in total_period. 204 + */ 205 + struct events_stats { 206 + u64 total_period; 207 + u64 total_non_filtered_period; 208 + u64 total_lost; 209 + u64 total_invalid_chains; 210 + u32 nr_events[PERF_RECORD_HEADER_MAX]; 211 + u32 nr_non_filtered_samples; 212 + u32 nr_lost_warned; 213 + u32 nr_unknown_events; 214 + u32 nr_invalid_chains; 215 + u32 nr_unknown_id; 216 + u32 nr_unprocessable_samples; 217 + }; 218 + 193 219 struct attr_event { 194 220 struct perf_event_header header; 195 221 struct perf_event_attr attr;
-26
tools/perf/util/hist.h
··· 23 23 HIST_FILTER__HOST, 24 24 }; 25 25 26 - /* 27 - * The kernel collects the number of events it couldn't send in a stretch and 28 - * when possible sends this number in a PERF_RECORD_LOST event. The number of 29 - * such "chunks" of lost events is stored in .nr_events[PERF_EVENT_LOST] while 30 - * total_lost tells exactly how many events the kernel in fact lost, i.e. it is 31 - * the sum of all struct lost_event.lost fields reported. 32 - * 33 - * The total_period is needed because by default auto-freq is used, so 34 - * multipling nr_events[PERF_EVENT_SAMPLE] by a frequency isn't possible to get 35 - * the total number of low level events, it is necessary to to sum all struct 36 - * sample_event.period and stash the result in total_period. 37 - */ 38 - struct events_stats { 39 - u64 total_period; 40 - u64 total_non_filtered_period; 41 - u64 total_lost; 42 - u64 total_invalid_chains; 43 - u32 nr_events[PERF_RECORD_HEADER_MAX]; 44 - u32 nr_non_filtered_samples; 45 - u32 nr_lost_warned; 46 - u32 nr_unknown_events; 47 - u32 nr_invalid_chains; 48 - u32 nr_unknown_id; 49 - u32 nr_unprocessable_samples; 50 - }; 51 - 52 26 enum hist_column { 53 27 HISTC_SYMBOL, 54 28 HISTC_DSO,