diff options
author | Scott Wood <scottwood@freescale.com> | 2014-04-07 23:49:35 (GMT) |
---|---|---|
committer | Scott Wood <scottwood@freescale.com> | 2014-04-07 23:49:35 (GMT) |
commit | 62b8c978ee6b8d135d9e7953221de58000dba986 (patch) | |
tree | 683b04b2e627f6710c22c151b23c8cc9a165315e /tools/perf/util/session.h | |
parent | 78fd82238d0e5716578c326404184a27ba67fd6e (diff) | |
download | linux-fsl-qoriq-62b8c978ee6b8d135d9e7953221de58000dba986.tar.xz |
Rewind v3.13-rc3+ (78fd82238d0e5716) to v3.12
Diffstat (limited to 'tools/perf/util/session.h')
-rw-r--r-- | tools/perf/util/session.h | 38 |
1 files changed, 20 insertions, 18 deletions
diff --git a/tools/perf/util/session.h b/tools/perf/util/session.h index 50f6409..04bf737 100644 --- a/tools/perf/util/session.h +++ b/tools/perf/util/session.h @@ -7,7 +7,6 @@ #include "machine.h" #include "symbol.h" #include "thread.h" -#include "data.h" #include <linux/rbtree.h> #include <linux/perf_event.h> @@ -30,13 +29,16 @@ struct ordered_samples { struct perf_session { struct perf_header header; + unsigned long size; struct machines machines; struct perf_evlist *evlist; struct pevent *pevent; struct events_stats stats; + int fd; + bool fd_pipe; bool repipe; struct ordered_samples ordered_samples; - struct perf_data_file *file; + char filename[1]; }; #define PRINT_IP_OPT_IP (1<<0) @@ -47,16 +49,17 @@ struct perf_session { struct perf_tool; -struct perf_session *perf_session__new(struct perf_data_file *file, - bool repipe, struct perf_tool *tool); +struct perf_session *perf_session__new(const char *filename, int mode, + bool force, bool repipe, + struct perf_tool *tool); void perf_session__delete(struct perf_session *session); -void perf_event_header__bswap(struct perf_event_header *hdr); +void perf_event_header__bswap(struct perf_event_header *self); -int __perf_session__process_events(struct perf_session *session, +int __perf_session__process_events(struct perf_session *self, u64 data_offset, u64 data_size, u64 size, struct perf_tool *tool); -int perf_session__process_events(struct perf_session *session, +int perf_session__process_events(struct perf_session *self, struct perf_tool *tool); int perf_session_queue_event(struct perf_session *s, union perf_event *event, @@ -64,38 +67,37 @@ int perf_session_queue_event(struct perf_session *s, union perf_event *event, void perf_tool__fill_defaults(struct perf_tool *tool); -int perf_session__resolve_callchain(struct perf_session *session, - struct perf_evsel *evsel, +int perf_session__resolve_callchain(struct perf_session *self, struct perf_evsel *evsel, struct thread *thread, struct ip_callchain *chain, struct symbol **parent); -bool perf_session__has_traces(struct perf_session *session, const char *msg); +bool perf_session__has_traces(struct perf_session *self, const char *msg); void mem_bswap_64(void *src, int byte_size); void mem_bswap_32(void *src, int byte_size); void perf_event__attr_swap(struct perf_event_attr *attr); -int perf_session__create_kernel_maps(struct perf_session *session); +int perf_session__create_kernel_maps(struct perf_session *self); void perf_session__set_id_hdr_size(struct perf_session *session); static inline -struct machine *perf_session__find_machine(struct perf_session *session, pid_t pid) +struct machine *perf_session__find_machine(struct perf_session *self, pid_t pid) { - return machines__find(&session->machines, pid); + return machines__find(&self->machines, pid); } static inline -struct machine *perf_session__findnew_machine(struct perf_session *session, pid_t pid) +struct machine *perf_session__findnew_machine(struct perf_session *self, pid_t pid) { - return machines__findnew(&session->machines, pid); + return machines__findnew(&self->machines, pid); } -struct thread *perf_session__findnew(struct perf_session *session, pid_t pid); -size_t perf_session__fprintf(struct perf_session *session, FILE *fp); +struct thread *perf_session__findnew(struct perf_session *self, pid_t pid); +size_t perf_session__fprintf(struct perf_session *self, FILE *fp); -size_t perf_session__fprintf_dsos(struct perf_session *session, FILE *fp); +size_t perf_session__fprintf_dsos(struct perf_session *self, FILE *fp); size_t perf_session__fprintf_dsos_buildid(struct perf_session *session, FILE *fp, bool (fn)(struct dso *dso, int parm), int parm); |