Skip to content

Commit

Permalink
perf tools: Report number of pmu type of unknown events
Browse files Browse the repository at this point in the history
If detection fails and an event name is unknown, report the type number.
Example perf header output:

 # Samples: 10K of event 'unknown attr type: 7'

Signed-off-by: Robert Richter <robert.richter@amd.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/1345144224-27280-3-git-send-email-robert.richter@amd.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
  • Loading branch information
Robert Richter authored and Arnaldo Carvalho de Melo committed Aug 17, 2012
1 parent f4d8343 commit ca1b145
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tools/perf/util/evsel.c
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,8 @@ const char *perf_evsel__name(struct perf_evsel *evsel)
break;

default:
scnprintf(bf, sizeof(bf), "%s", "unknown attr type");
scnprintf(bf, sizeof(bf), "unknown attr type: %d",
evsel->attr.type);
break;
}

Expand Down

0 comments on commit ca1b145

Please sign in to comment.