aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/annotate.h
diff options
context:
space:
mode:
Diffstat (limited to 'tools/perf/util/annotate.h')
-rw-r--r--tools/perf/util/annotate.h22
1 files changed, 13 insertions, 9 deletions
diff --git a/tools/perf/util/annotate.h b/tools/perf/util/annotate.h
index 6314335007f0..a6f60d5c5138 100644
--- a/tools/perf/util/annotate.h
+++ b/tools/perf/util/annotate.h
@@ -9,10 +9,15 @@
9 9
10struct ins; 10struct ins;
11 11
12struct ins_operands {
13 char *raw;
14 u64 target;
15};
16
12struct ins_ops { 17struct ins_ops {
13 int (*parse_target)(const char *operands, u64 *target); 18 int (*parse)(struct ins_operands *ops);
14 int (*scnprintf)(struct ins *ins, char *bf, size_t size, 19 int (*scnprintf)(struct ins *ins, char *bf, size_t size,
15 const char *operands, u64 target); 20 struct ins_operands *ops, bool addrs);
16}; 21};
17 22
18struct ins { 23struct ins {
@@ -24,13 +29,12 @@ bool ins__is_jump(const struct ins *ins);
24bool ins__is_call(const struct ins *ins); 29bool ins__is_call(const struct ins *ins);
25 30
26struct disasm_line { 31struct disasm_line {
27 struct list_head node; 32 struct list_head node;
28 s64 offset; 33 s64 offset;
29 u64 target; 34 char *line;
30 char *line; 35 char *name;
31 char *name; 36 struct ins *ins;
32 struct ins *ins; 37 struct ins_operands ops;
33 char *operands;
34}; 38};
35 39
36void disasm_line__free(struct disasm_line *dl); 40void disasm_line__free(struct disasm_line *dl);