aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/data_map.h
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2009-12-11 18:24:02 -0500
committerIngo Molnar <mingo@elte.hu>2009-12-12 01:42:12 -0500
commit94c744b6c0c6c5802a85ebfebbec429ac5851f2b (patch)
treee34dcaca54f1d7752ab1e7974bb73f94ff3cf94c /tools/perf/util/data_map.h
parentea08d8cbd162fe3756e3e2298efbe0b8b12f92d1 (diff)
perf tools: Introduce perf_session class
That does all the initialization boilerplate, opening the file, reading the header, checking if it is valid, etc. And that will as well have the threads list, kmap (now) global variable, etc, so that we can handle two (or more) perf.data files describing sessions to compare. Signed-off-by: Arnaldo Carvalho de Melo <acme@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: <1260573842-19720-1-git-send-email-acme@infradead.org> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'tools/perf/util/data_map.h')
-rw-r--r--tools/perf/util/data_map.h9
1 files changed, 3 insertions, 6 deletions
diff --git a/tools/perf/util/data_map.h b/tools/perf/util/data_map.h
index 258a87bcc4fb..98c5b823388c 100644
--- a/tools/perf/util/data_map.h
+++ b/tools/perf/util/data_map.h
@@ -3,6 +3,7 @@
3 3
4#include "event.h" 4#include "event.h"
5#include "header.h" 5#include "header.h"
6#include "session.h"
6 7
7typedef int (*event_type_handler_t)(event_t *); 8typedef int (*event_type_handler_t)(event_t *);
8 9
@@ -21,12 +22,8 @@ struct perf_file_handler {
21}; 22};
22 23
23void register_perf_file_handler(struct perf_file_handler *handler); 24void register_perf_file_handler(struct perf_file_handler *handler);
24int mmap_dispatch_perf_file(struct perf_header **pheader, 25int perf_session__process_events(struct perf_session *self,
25 const char *input_name, 26 int full_paths, int *cwdlen, char **cwd);
26 int force,
27 int full_paths,
28 int *cwdlen,
29 char **cwd);
30int perf_header__read_build_ids(int input, u64 offset, u64 file_size); 27int perf_header__read_build_ids(int input, u64 offset, u64 file_size);
31 28
32#endif 29#endif