aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/session.h
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2011-01-21 10:46:41 -0500
committerArnaldo Carvalho de Melo <acme@redhat.com>2011-01-24 10:17:56 -0500
commitd0dd74e853a0a6f37e8061d6d50be41c7034c54c (patch)
tree1292a98711611cbc4595785ed17605f20a90800c /tools/perf/util/session.h
parentfd78260b5376173faeb17127bd63b3c99a8e8bfb (diff)
perf tools: Move event__parse_sample to evsel.c
To avoid linking more stuff in the python binding I'm working on, future csets will make the sample type be taken from the evsel itself, but for that we need to first have one file per cpu and per sample_type, not a single perf.data file. Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Mike Galbraith <efault@gmx.de> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Tom Zanussi <tzanussi@gmail.com> LKML-Reference: <new-submission> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/session.h')
-rw-r--r--tools/perf/util/session.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/tools/perf/util/session.h b/tools/perf/util/session.h
index e815468eb888..78239767011e 100644
--- a/tools/perf/util/session.h
+++ b/tools/perf/util/session.h
@@ -155,4 +155,13 @@ size_t perf_session__fprintf_nr_events(struct perf_session *self, FILE *fp)
155{ 155{
156 return hists__fprintf_nr_events(&self->hists, fp); 156 return hists__fprintf_nr_events(&self->hists, fp);
157} 157}
158
159static inline int perf_session__parse_sample(struct perf_session *session,
160 const event_t *event,
161 struct sample_data *sample)
162{
163 return event__parse_sample(event, session->sample_type,
164 session->sample_id_all, sample);
165}
166
158#endif /* __PERF_SESSION_H */ 167#endif /* __PERF_SESSION_H */