diff options
author | Arnaldo Carvalho de Melo <acme@redhat.com> | 2018-05-28 11:50:21 -0300 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2018-06-04 10:28:53 -0300 |
commit | a47e843edca81058b9f4187b78f8b98320ebbd59 (patch) | |
tree | 71d40fb6d93decf5f86f78b81ab1cc1a89b493e7 /tools/perf/util/annotate.c | |
parent | 1eddd9e4101d21709c453d80a42d2efc4277cb27 (diff) | |
download | lwn-a47e843edca81058b9f4187b78f8b98320ebbd59.tar.gz lwn-a47e843edca81058b9f4187b78f8b98320ebbd59.zip |
perf annotate: Move disassembler_style global to annotation_options
Continuing to group annotation specific stuff into a struct.
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Wang Nan <wangnan0@huawei.com>
Link: https://lkml.kernel.org/n/tip-p3cdhltj58jt0byjzg3g7obx@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/annotate.c')
-rw-r--r-- | tools/perf/util/annotate.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/tools/perf/util/annotate.c b/tools/perf/util/annotate.c index ff8f4f474b22..a90777717b60 100644 --- a/tools/perf/util/annotate.c +++ b/tools/perf/util/annotate.c @@ -51,7 +51,6 @@ struct annotation_options annotation__default_options = { .offset_level = ANNOTATION__OFFSET_JUMP_TARGETS, }; -const char *disassembler_style; const char *objdump_path; static regex_t file_lineno; @@ -1659,8 +1658,8 @@ static int symbol__disassemble(struct symbol *sym, struct annotate_args *args) " --stop-address=0x%016" PRIx64 " -l -d %s %s -C \"%s\" 2>/dev/null|grep -v \"%s:\"|expand", objdump_path ? objdump_path : "objdump", - disassembler_style ? "-M " : "", - disassembler_style ? disassembler_style : "", + opts->disassembler_style ? "-M " : "", + opts->disassembler_style ?: "", map__rip_2objdump(map, sym->start), map__rip_2objdump(map, sym->end), opts->show_asm_raw ? "" : "--no-show-raw", |