aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/symbol.h
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2009-11-18 17:20:53 -0500
committerIngo Molnar <mingo@elte.hu>2009-11-19 02:28:13 -0500
commit2446042c93bfc6eeebfc89e88fdef2435d2bb5c4 (patch)
tree3b442923926652127331449cf9a2da811a8fca4a /tools/perf/util/symbol.h
parentf1617b40596cb341ee6602a9d969c5e4cebe9260 (diff)
perf symbols: Capture the running kernel buildid too
[root@doppio linux-2.6-tip]# perf record -a -f sleep 3s ; perf buildid-list | grep vmlinux [ perf record: Woken up 1 times to write data ] [ perf record: Captured and wrote 0.171 MB perf.data (~7489 samples) ] 18e7cc53db62a7d35e9d6f6c9ddc23017d38ee9a vmlinux [root@doppio linux-2.6-tip]# Several refactorings were needed so that we can have symmetry between dsos__load_modules() and dsos__load_kernel(), i.e. those functions will respectively create and add to the dsos list the loaded modules and kernel, with its buildids, but not load its symbols. That is something the subcomands that need will have to call dso__load_kernel_sym(), just like we do with modules with dsos__load_module_sym()/dso__load_module_sym(). Next csets will actually use this info to stop producing bogus results using mismatched vmlinux and .ko files. Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Roland McGrath <roland@redhat.com> Cc: Frédéric Weisbecker <fweisbec@gmail.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Paul Mackerras <paulus@samba.org> LKML-Reference: <1258582853-8579-4-git-send-email-acme@infradead.org> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'tools/perf/util/symbol.h')
-rw-r--r--tools/perf/util/symbol.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/perf/util/symbol.h b/tools/perf/util/symbol.h
index da7ec1af255a..f0593a649c3d 100644
--- a/tools/perf/util/symbol.h
+++ b/tools/perf/util/symbol.h
@@ -77,10 +77,10 @@ void dso__delete(struct dso *self);
77 77
78struct symbol *dso__find_symbol(struct dso *self, u64 ip); 78struct symbol *dso__find_symbol(struct dso *self, u64 ip);
79 79
80int dsos__load_kernel(const char *vmlinux, symbol_filter_t filter, int modules);
81int dsos__load_modules(void); 80int dsos__load_modules(void);
82struct dso *dsos__findnew(const char *name); 81struct dso *dsos__findnew(const char *name);
83int dso__load(struct dso *self, struct map *map, symbol_filter_t filter); 82int dso__load(struct dso *self, struct map *map, symbol_filter_t filter);
83int dso__load_kernel_sym(struct dso *self, symbol_filter_t filter, int modules);
84void dsos__fprintf(FILE *fp); 84void dsos__fprintf(FILE *fp);
85size_t dsos__fprintf_buildid(FILE *fp); 85size_t dsos__fprintf_buildid(FILE *fp);
86 86
@@ -94,6 +94,7 @@ int sysfs__read_build_id(const char *filename, void *bf, size_t size);
94bool dsos__read_build_ids(void); 94bool dsos__read_build_ids(void);
95int build_id__sprintf(u8 *self, int len, char *bf); 95int build_id__sprintf(u8 *self, int len, char *bf);
96 96
97struct dso *dsos__load_kernel(void);
97int load_kernel(symbol_filter_t filter); 98int load_kernel(symbol_filter_t filter);
98 99
99void symbol__init(unsigned int priv_size); 100void symbol__init(unsigned int priv_size);