Messages in this thread |  | | | Subject | Re: [PATCH 2/2] perf: Walk through the relevant events only | | From | Peter Zijlstra <> | | Date | Fri, 05 Mar 2010 10:39:29 +0100 |
| |
On Fri, 2010-03-05 at 08:00 +0100, Frederic Weisbecker wrote: > Each time a trace event triggers, we walk through the entire > list of events from the active contexts to find the perf events > that match the current one. > > This is wasteful. To solve this, we maintain a per cpu list of > the active perf events for each running trace events and we > directly commit to these.
Right, so this seems a little trace specific. I once thought about using a hash table to do this for all software events. It also keeps it all nicely inside perf_event.[ch].
|  |