aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/util/event.h
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2011-11-28 04:56:39 -0500
committerArnaldo Carvalho de Melo <acme@redhat.com>2011-11-28 07:39:12 -0500
commit743eb868657bdb1b26c7b24077ca21c67c82c777 (patch)
tree4803b557725213043ccd5d3f83d2eec796a49f69 /tools/perf/util/event.h
parentd20deb64e0490ee9442b5181bc08a62d2cadcb90 (diff)
perf tools: Resolve machine earlier and pass it to perf_event_ops
Reducing the exposure of perf_session further, so that we can use the classes in cases where no perf.data file is created. Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/n/tip-stua66dcscsezzrcdugvbmvd@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/event.h')
-rw-r--r--tools/perf/util/event.h21
1 files changed, 9 insertions, 12 deletions
diff --git a/tools/perf/util/event.h b/tools/perf/util/event.h
index 669409d35710..1564877e8703 100644
--- a/tools/perf/util/event.h
+++ b/tools/perf/util/event.h
@@ -142,56 +142,53 @@ union perf_event {
142void perf_event__print_totals(void); 142void perf_event__print_totals(void);
143 143
144struct perf_event_ops; 144struct perf_event_ops;
145struct perf_session;
146struct thread_map; 145struct thread_map;
147 146
148typedef int (*perf_event__handler_t)(struct perf_event_ops *ops, 147typedef int (*perf_event__handler_t)(struct perf_event_ops *ops,
149 union perf_event *event, 148 union perf_event *event,
150 struct perf_sample *sample, 149 struct perf_sample *sample,
151 struct perf_session *session); 150 struct machine *machine);
152 151
153int perf_event__synthesize_thread_map(struct perf_event_ops *ops, 152int perf_event__synthesize_thread_map(struct perf_event_ops *ops,
154 struct thread_map *threads, 153 struct thread_map *threads,
155 perf_event__handler_t process, 154 perf_event__handler_t process,
156 struct perf_session *session); 155 struct machine *machine);
157int perf_event__synthesize_threads(struct perf_event_ops *ops, 156int perf_event__synthesize_threads(struct perf_event_ops *ops,
158 perf_event__handler_t process, 157 perf_event__handler_t process,
159 struct perf_session *session); 158 struct machine *machine);
160int perf_event__synthesize_kernel_mmap(struct perf_event_ops *ops, 159int perf_event__synthesize_kernel_mmap(struct perf_event_ops *ops,
161 perf_event__handler_t process, 160 perf_event__handler_t process,
162 struct perf_session *session,
163 struct machine *machine, 161 struct machine *machine,
164 const char *symbol_name); 162 const char *symbol_name);
165 163
166int perf_event__synthesize_modules(struct perf_event_ops *ops, 164int perf_event__synthesize_modules(struct perf_event_ops *ops,
167 perf_event__handler_t process, 165 perf_event__handler_t process,
168 struct perf_session *session,
169 struct machine *machine); 166 struct machine *machine);
170 167
171int perf_event__process_comm(struct perf_event_ops *ops, 168int perf_event__process_comm(struct perf_event_ops *ops,
172 union perf_event *event, 169 union perf_event *event,
173 struct perf_sample *sample, 170 struct perf_sample *sample,
174 struct perf_session *session); 171 struct machine *machine);
175int perf_event__process_lost(struct perf_event_ops *ops, 172int perf_event__process_lost(struct perf_event_ops *ops,
176 union perf_event *event, 173 union perf_event *event,
177 struct perf_sample *sample, 174 struct perf_sample *sample,
178 struct perf_session *session); 175 struct machine *machine);
179int perf_event__process_mmap(struct perf_event_ops *ops, 176int perf_event__process_mmap(struct perf_event_ops *ops,
180 union perf_event *event, 177 union perf_event *event,
181 struct perf_sample *sample, 178 struct perf_sample *sample,
182 struct perf_session *session); 179 struct machine *machine);
183int perf_event__process_task(struct perf_event_ops *ops, 180int perf_event__process_task(struct perf_event_ops *ops,
184 union perf_event *event, 181 union perf_event *event,
185 struct perf_sample *sample, 182 struct perf_sample *sample,
186 struct perf_session *session); 183 struct machine *machine);
187int perf_event__process(struct perf_event_ops *ops, 184int perf_event__process(struct perf_event_ops *ops,
188 union perf_event *event, 185 union perf_event *event,
189 struct perf_sample *sample, 186 struct perf_sample *sample,
190 struct perf_session *session); 187 struct machine *machine);
191 188
192struct addr_location; 189struct addr_location;
193int perf_event__preprocess_sample(const union perf_event *self, 190int perf_event__preprocess_sample(const union perf_event *self,
194 struct perf_session *session, 191 struct machine *machine,
195 struct addr_location *al, 192 struct addr_location *al,
196 struct perf_sample *sample, 193 struct perf_sample *sample,
197 symbol_filter_t filter); 194 symbol_filter_t filter);