diff options
Diffstat (limited to 'tools/perf/builtin-stat.c')
-rw-r--r-- | tools/perf/builtin-stat.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/tools/perf/builtin-stat.c b/tools/perf/builtin-stat.c index da77077450cf..6a4a8a399d95 100644 --- a/tools/perf/builtin-stat.c +++ b/tools/perf/builtin-stat.c | |||
@@ -66,7 +66,8 @@ static struct perf_event_attr default_attrs[] = { | |||
66 | { .type = PERF_TYPE_SOFTWARE, .config = PERF_COUNT_SW_PAGE_FAULTS }, | 66 | { .type = PERF_TYPE_SOFTWARE, .config = PERF_COUNT_SW_PAGE_FAULTS }, |
67 | 67 | ||
68 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_CPU_CYCLES }, | 68 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_CPU_CYCLES }, |
69 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_STALLED_CYCLES }, | 69 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_STALLED_CYCLES_FRONTEND }, |
70 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_STALLED_CYCLES_BACKEND }, | ||
70 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_INSTRUCTIONS }, | 71 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_INSTRUCTIONS }, |
71 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_BRANCH_INSTRUCTIONS }, | 72 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_BRANCH_INSTRUCTIONS }, |
72 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_BRANCH_MISSES }, | 73 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_BRANCH_MISSES }, |
@@ -84,7 +85,8 @@ static struct perf_event_attr detailed_attrs[] = { | |||
84 | { .type = PERF_TYPE_SOFTWARE, .config = PERF_COUNT_SW_PAGE_FAULTS }, | 85 | { .type = PERF_TYPE_SOFTWARE, .config = PERF_COUNT_SW_PAGE_FAULTS }, |
85 | 86 | ||
86 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_CPU_CYCLES }, | 87 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_CPU_CYCLES }, |
87 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_STALLED_CYCLES }, | 88 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_STALLED_CYCLES_FRONTEND }, |
89 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_STALLED_CYCLES_BACKEND }, | ||
88 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_INSTRUCTIONS }, | 90 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_INSTRUCTIONS }, |
89 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_BRANCH_INSTRUCTIONS }, | 91 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_BRANCH_INSTRUCTIONS }, |
90 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_BRANCH_MISSES }, | 92 | { .type = PERF_TYPE_HARDWARE, .config = PERF_COUNT_HW_BRANCH_MISSES }, |
@@ -249,7 +251,7 @@ static void update_shadow_stats(struct perf_evsel *counter, u64 *count) | |||
249 | update_stats(&runtime_nsecs_stats[0], count[0]); | 251 | update_stats(&runtime_nsecs_stats[0], count[0]); |
250 | else if (perf_evsel__match(counter, HARDWARE, HW_CPU_CYCLES)) | 252 | else if (perf_evsel__match(counter, HARDWARE, HW_CPU_CYCLES)) |
251 | update_stats(&runtime_cycles_stats[0], count[0]); | 253 | update_stats(&runtime_cycles_stats[0], count[0]); |
252 | else if (perf_evsel__match(counter, HARDWARE, HW_STALLED_CYCLES)) | 254 | else if (perf_evsel__match(counter, HARDWARE, HW_STALLED_CYCLES_BACKEND)) |
253 | update_stats(&runtime_stalled_cycles_stats[0], count[0]); | 255 | update_stats(&runtime_stalled_cycles_stats[0], count[0]); |
254 | else if (perf_evsel__match(counter, HARDWARE, HW_BRANCH_INSTRUCTIONS)) | 256 | else if (perf_evsel__match(counter, HARDWARE, HW_BRANCH_INSTRUCTIONS)) |
255 | update_stats(&runtime_branches_stats[0], count[0]); | 257 | update_stats(&runtime_branches_stats[0], count[0]); |
@@ -607,7 +609,7 @@ static void abs_printout(int cpu, struct perf_evsel *evsel, double avg) | |||
607 | 609 | ||
608 | fprintf(stderr, " # %8.3f %% of all cache refs ", ratio); | 610 | fprintf(stderr, " # %8.3f %% of all cache refs ", ratio); |
609 | 611 | ||
610 | } else if (perf_evsel__match(evsel, HARDWARE, HW_STALLED_CYCLES)) { | 612 | } else if (perf_evsel__match(evsel, HARDWARE, HW_STALLED_CYCLES_BACKEND)) { |
611 | print_stalled_cycles(cpu, evsel, avg); | 613 | print_stalled_cycles(cpu, evsel, avg); |
612 | } else if (perf_evsel__match(evsel, HARDWARE, HW_CPU_CYCLES)) { | 614 | } else if (perf_evsel__match(evsel, HARDWARE, HW_CPU_CYCLES)) { |
613 | total = avg_stats(&runtime_nsecs_stats[cpu]); | 615 | total = avg_stats(&runtime_nsecs_stats[cpu]); |