From 85a84e4f813912ab77d872ff6882dd7b435fbf4e Mon Sep 17 00:00:00 2001 From: Arnaldo Carvalho de Melo Date: Tue, 20 Mar 2018 16:19:08 -0300 Subject: perf annotate: Pass function descriptor to its instruction parsing routines We need that to figure out if jumps have targets in a different function. E.g. _cpp_lex_token(), in /usr/libexec/gcc/x86_64-redhat-linux/5.3.1/cc1 has a line like this: jne c469be Cc: Adrian Hunter Cc: David Ahern Cc: Jiri Olsa Cc: Namhyung Kim Cc: Wang Nan Link: https://lkml.kernel.org/n/tip-ris0ioziyp469pofpzix2atb@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo --- tools/perf/arch/s390/annotate/instructions.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'tools/perf/arch/s390') diff --git a/tools/perf/arch/s390/annotate/instructions.c b/tools/perf/arch/s390/annotate/instructions.c index 46c21831f2ac..cee4e2f7c057 100644 --- a/tools/perf/arch/s390/annotate/instructions.c +++ b/tools/perf/arch/s390/annotate/instructions.c @@ -2,9 +2,10 @@ #include static int s390_call__parse(struct arch *arch, struct ins_operands *ops, - struct map *map) + struct map_symbol *ms) { char *endptr, *tok, *name; + struct map *map = ms->map; struct addr_map_symbol target = { .map = map, }; @@ -54,7 +55,7 @@ static struct ins_ops s390_call_ops = { static int s390_mov__parse(struct arch *arch __maybe_unused, struct ins_operands *ops, - struct map *map __maybe_unused) + struct map_symbol *ms __maybe_unused) { char *s = strchr(ops->raw, ','), *target, *endptr; -- cgit v1.2.3-55-g7522