diff options
| author | Ingo Molnar <mingo@kernel.org> | 2012-11-13 13:05:09 -0500 |
|---|---|---|
| committer | Ingo Molnar <mingo@kernel.org> | 2012-11-13 13:13:41 -0500 |
| commit | ccf59d8da119ab03dcbdf95fb5e5adcef6ba51f2 (patch) | |
| tree | d390f9230edac3d9c42a8ad8b030182890b6e609 | |
| parent | 95d18aa2b6c05351181934b3bc34ce038cc7b637 (diff) | |
| parent | 27f94d52394003d444a383eaf8d4824daf32432e (diff) | |
Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core
Pull perf/core improvements and fixes from Arnaldo Carvalho de Melo:
* Don't show scripts menu for 'perf top', fix from Feng Tang
* Add framework for automated perf_event_attr tests, where tools with
different command line options will be run from a 'perf test', via
python glue, and the perf syscall will be intercepted to verify that
the perf_event_attr fields set by the tool are those expected,
from Jiri Olsa
* Use normalized arch name for searching objdump path. This fixes cases
where the system's objdump (e.g. x86_64) supports the architecture in
the perf.data file (e.g. i686), but is not the same,
fix from Namhyung Kim.
* Postpone objdump check until annotation requested, from Namhyung Kim.
* Add a 'link' method for hists, so that we can have the leader with
buckets for all the entries in all the hists. This new method
is now used in the default 'diff' output, making the sum of the 'baseline'
column be 100%, eliminating blind spots. Now we need to use this
for 'diff' with > 2 perf.data files and for multi event 'report' and
'annotate'.
* libtraceevent fixes for compiler warnings trying to make perf it build
on some distros, like fedora 14, 32-bit, some of the warnings really
pointed to real bugs.
* Remove temp dir on failure in 'perf test', fix from Jiri Olsa.
* Fixes for handling data, stack mmaps, from Namhyung Kim.
* Fix live annotation bug related to recent objdump lookup patches, from
Namhyung Kim
* Don't try to follow jump target on PLT symbols in the annotation browser,
fix from Namhyung Kim.
* Fix leak on hist_entry delete, from Namhyung Kim.
* Fix a CPU_ALLOC related build error on builtin-test, from Zheng Liu.
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
67 files changed, 2118 insertions, 504 deletions
diff --git a/tools/lib/traceevent/event-parse.c b/tools/lib/traceevent/event-parse.c index f2989c525e48..5a824e355d04 100644 --- a/tools/lib/traceevent/event-parse.c +++ b/tools/lib/traceevent/event-parse.c | |||
| @@ -174,7 +174,7 @@ static int cmdline_init(struct pevent *pevent) | |||
| 174 | return 0; | 174 | return 0; |
| 175 | } | 175 | } |
| 176 | 176 | ||
| 177 | static char *find_cmdline(struct pevent *pevent, int pid) | 177 | static const char *find_cmdline(struct pevent *pevent, int pid) |
| 178 | { | 178 | { |
| 179 | const struct cmdline *comm; | 179 | const struct cmdline *comm; |
| 180 | struct cmdline key; | 180 | struct cmdline key; |
| @@ -2637,7 +2637,7 @@ process_func_handler(struct event_format *event, struct pevent_function_handler | |||
| 2637 | struct print_arg *farg; | 2637 | struct print_arg *farg; |
| 2638 | enum event_type type; | 2638 | enum event_type type; |
| 2639 | char *token; | 2639 | char *token; |
| 2640 | char *test; | 2640 | const char *test; |
| 2641 | int i; | 2641 | int i; |
| 2642 | 2642 | ||
| 2643 | arg->type = PRINT_FUNC; | 2643 | arg->type = PRINT_FUNC; |
| @@ -3889,7 +3889,7 @@ static void print_mac_arg(struct trace_seq *s, int mac, void *data, int size, | |||
| 3889 | struct event_format *event, struct print_arg *arg) | 3889 | struct event_format *event, struct print_arg *arg) |
| 3890 | { | 3890 | { |
| 3891 | unsigned char *buf; | 3891 | unsigned char *buf; |
| 3892 | char *fmt = "%.2x:%.2x:%.2x:%.2x:%.2x:%.2x"; | 3892 | const char *fmt = "%.2x:%.2x:%.2x:%.2x:%.2x:%.2x"; |
| 3893 | 3893 | ||
| 3894 | if (arg->type == PRINT_FUNC) { | 3894 | if (arg->type == PRINT_FUNC) { |
| 3895 | process_defined_func(s, data, size, event, arg); | 3895 | process_defined_func(s, data, size, event, arg); |
| @@ -3931,7 +3931,8 @@ static int is_printable_array(char *p, unsigned int len) | |||
| 3931 | return 1; | 3931 | return 1; |
| 3932 | } | 3932 | } |
| 3933 | 3933 | ||
| 3934 | static void print_event_fields(struct trace_seq *s, void *data, int size, | 3934 | static void print_event_fields(struct trace_seq *s, void *data, |
| 3935 | int size __maybe_unused, | ||
| 3935 | struct event_format *event) | 3936 | struct event_format *event) |
| 3936 | { | 3937 | { |
| 3937 | struct format_field *field; | 3938 | struct format_field *field; |
| @@ -4408,7 +4409,7 @@ void pevent_event_info(struct trace_seq *s, struct event_format *event, | |||
| 4408 | void pevent_print_event(struct pevent *pevent, struct trace_seq *s, | 4409 | void pevent_print_event(struct pevent *pevent, struct trace_seq *s, |
| 4409 | struct pevent_record *record) | 4410 | struct pevent_record *record) |
| 4410 | { | 4411 | { |
| 4411 | static char *spaces = " "; /* 20 spaces */ | 4412 | static const char *spaces = " "; /* 20 spaces */ |
| 4412 | struct event_format *event; | 4413 | struct event_format *event; |
| 4413 | unsigned long secs; | 4414 | unsigned long secs; |
| 4414 | unsigned long usecs; | 4415 | unsigned long usecs; |
| @@ -5070,8 +5071,8 @@ static const char * const pevent_error_str[] = { | |||
| 5070 | }; | 5071 | }; |
| 5071 | #undef _PE | 5072 | #undef _PE |
| 5072 | 5073 | ||
| 5073 | int pevent_strerror(struct pevent *pevent, enum pevent_errno errnum, | 5074 | int pevent_strerror(struct pevent *pevent __maybe_unused, |
| 5074 | char *buf, size_t buflen) | 5075 | enum pevent_errno errnum, char *buf, size_t buflen) |
| 5075 | { | 5076 | { |
| 5076 | int idx; | 5077 | int idx; |
| 5077 | const char *msg; | 5078 | const char *msg; |
| @@ -5100,6 +5101,7 @@ int pevent_strerror(struct pevent *pevent, enum pevent_errno errnum, | |||
| 5100 | case PEVENT_ERRNO__READ_FORMAT_FAILED: | 5101 | case PEVENT_ERRNO__READ_FORMAT_FAILED: |
| 5101 | |||
