xref: /linux/tools/perf/util/symbol_conf.h (revision c7decec2f2d2ab0366567f9e30c0e1418cece43f)
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef __PERF_SYMBOL_CONF
3 #define __PERF_SYMBOL_CONF 1
4 
5 #include <stdbool.h>
6 #include <linux/bitmap.h>
7 #include "perf.h"
8 
9 struct strlist;
10 struct intlist;
11 
12 enum a2l_style {
13 	A2L_STYLE_UNKNOWN = 0,
14 	A2L_STYLE_LIBDW,
15 	A2L_STYLE_LLVM,
16 	A2L_STYLE_LIBBFD,
17 	A2L_STYLE_CMD,
18 };
19 #define MAX_A2L_STYLE (A2L_STYLE_CMD + 1)
20 
21 struct symbol_conf {
22 	bool		nanosecs;
23 	unsigned short	priv_size;
24 	bool		try_vmlinux_path,
25 			init_annotation,
26 			force,
27 			ignore_vmlinux,
28 			ignore_vmlinux_buildid,
29 			show_kernel_path,
30 			use_modules,
31 			allow_aliases,
32 			show_nr_samples,
33 			show_total_period,
34 			use_callchain,
35 			cumulate_callchain,
36 			show_branchflag_count,
37 			exclude_other,
38 			show_cpu_utilization,
39 			initialized,
40 			kptr_restrict,
41 			event_group,
42 			demangle,
43 			demangle_kernel,
44 			filter_relative,
45 			show_hist_headers,
46 			has_filter,
47 			show_ref_callgraph,
48 			hide_unresolved,
49 			raw_trace,
50 			report_hierarchy,
51 			report_block,
52 			report_individual_block,
53 			inline_name,
54 			disable_add2line_warn,
55 			no_buildid_mmap2,
56 			guest_code,
57 			lazy_load_kernel_maps,
58 			keep_exited_threads,
59 			annotate_data_member,
60 			annotate_data_sample,
61 			skip_empty,
62 			enable_latency,
63 			prefer_latency;
64 	const char	*vmlinux_name,
65 			*kallsyms_name,
66 			*source_prefix,
67 			*field_sep,
68 			*graph_function;
69 	const char	*default_guest_vmlinux_name,
70 			*default_guest_kallsyms,
71 			*default_guest_modules;
72 	const char	*guestmount;
73 	const char	*dso_list_str,
74 			*comm_list_str,
75 			*pid_list_str,
76 			*tid_list_str,
77 			*sym_list_str,
78 			*parallelism_list_str,
79 			*col_width_list_str,
80 			*bt_stop_list_str;
81 	const char		*addr2line_path;
82 	enum a2l_style	addr2line_style[MAX_A2L_STYLE];
83 	unsigned long	time_quantum;
84        struct strlist	*dso_list,
85 			*comm_list,
86 			*sym_list,
87 			*dso_from_list,
88 			*dso_to_list,
89 			*sym_from_list,
90 			*sym_to_list,
91 			*bt_stop_list;
92 	struct intlist	*pid_list,
93 			*tid_list,
94 			*addr_list;
95 	const char	*symfs;
96 	int		res_sample;
97 	int		pad_output_len_dso;
98 	int		group_sort_idx;
99 	int		addr_range;
100 	DECLARE_BITMAP(parallelism_filter, MAX_NR_CPUS + 1);
101 };
102 
103 extern struct symbol_conf symbol_conf;
104 
105 #endif // __PERF_SYMBOL_CONF
106