Re: [PATCH RFC] perf kvm stat live: cache mmap()ed events

2014-09-15 Thread Arnaldo Carvalho de Melo
Em Mon, Sep 15, 2014 at 04:57:34PM +0400, Alexander Yarygin escreveu: > David Ahern writes: > > On 9/12/14, 10:27 AM, Alexander Yarygin wrote: > >> During mmap() process 'perf kvm stat live' gets a pointer to events and > >> passes them to the session queue. Events are stored in shared memory and

Re: [PATCH RFC] perf kvm stat live: cache mmap()ed events

2014-09-15 Thread David Ahern
On 9/15/14, 6:57 AM, Alexander Yarygin wrote: David Ahern writes: On 9/12/14, 10:27 AM, Alexander Yarygin wrote: During mmap() process 'perf kvm stat live' gets a pointer to events and passes them to the session queue. Events are stored in shared memory and eventually they will be

Re: [PATCH RFC] perf kvm stat live: cache mmap()ed events

2014-09-15 Thread Alexander Yarygin
David Ahern writes: > On 9/12/14, 10:27 AM, Alexander Yarygin wrote: >> During mmap() process 'perf kvm stat live' gets a pointer to events and >> passes them to the session queue. Events are stored in shared memory and >> eventually they will be overwritten by the kernel. The problem is, that

Re: [PATCH RFC] perf kvm stat live: cache mmap()ed events

2014-09-15 Thread Alexander Yarygin
David Ahern dsah...@gmail.com writes: On 9/12/14, 10:27 AM, Alexander Yarygin wrote: During mmap() process 'perf kvm stat live' gets a pointer to events and passes them to the session queue. Events are stored in shared memory and eventually they will be overwritten by the kernel. The problem

Re: [PATCH RFC] perf kvm stat live: cache mmap()ed events

2014-09-15 Thread David Ahern
On 9/15/14, 6:57 AM, Alexander Yarygin wrote: David Ahern dsah...@gmail.com writes: On 9/12/14, 10:27 AM, Alexander Yarygin wrote: During mmap() process 'perf kvm stat live' gets a pointer to events and passes them to the session queue. Events are stored in shared memory and eventually they

Re: [PATCH RFC] perf kvm stat live: cache mmap()ed events

2014-09-15 Thread Arnaldo Carvalho de Melo
Em Mon, Sep 15, 2014 at 04:57:34PM +0400, Alexander Yarygin escreveu: David Ahern dsah...@gmail.com writes: On 9/12/14, 10:27 AM, Alexander Yarygin wrote: During mmap() process 'perf kvm stat live' gets a pointer to events and passes them to the session queue. Events are stored in shared

Re: [PATCH RFC] perf kvm stat live: cache mmap()ed events

2014-09-14 Thread David Ahern
On 9/12/14, 10:27 AM, Alexander Yarygin wrote: During mmap() process 'perf kvm stat live' gets a pointer to events and passes them to the session queue. Events are stored in shared memory and eventually they will be overwritten by the kernel. The problem is, that when events come too fast, old

Re: [PATCH RFC] perf kvm stat live: cache mmap()ed events

2014-09-14 Thread Jiri Olsa
On Fri, Sep 12, 2014 at 08:27:43PM +0400, Alexander Yarygin wrote: SNIP > + > + list_for_each_safe(p, p2, >list) { > + struct events_cache *entry; > + > + entry = list_entry(p, struct events_cache, list); > + > + if (>event == event) { > +

Re: [PATCH RFC] perf kvm stat live: cache mmap()ed events

2014-09-14 Thread Jiri Olsa
On Fri, Sep 12, 2014 at 08:27:43PM +0400, Alexander Yarygin wrote: SNIP + + list_for_each_safe(p, p2, cache-list) { + struct events_cache *entry; + + entry = list_entry(p, struct events_cache, list); + + if (entry-event == event) { +

Re: [PATCH RFC] perf kvm stat live: cache mmap()ed events

2014-09-14 Thread David Ahern
On 9/12/14, 10:27 AM, Alexander Yarygin wrote: During mmap() process 'perf kvm stat live' gets a pointer to events and passes them to the session queue. Events are stored in shared memory and eventually they will be overwritten by the kernel. The problem is, that when events come too fast, old

[PATCH RFC] perf kvm stat live: cache mmap()ed events

2014-09-12 Thread Alexander Yarygin
During mmap() process 'perf kvm stat live' gets a pointer to events and passes them to the session queue. Events are stored in shared memory and eventually they will be overwritten by the kernel. The problem is, that when events come too fast, old events can be overwritten before they have been

[PATCH RFC] perf kvm stat live: cache mmap()ed events

2014-09-12 Thread Alexander Yarygin
During mmap() process 'perf kvm stat live' gets a pointer to events and passes them to the session queue. Events are stored in shared memory and eventually they will be overwritten by the kernel. The problem is, that when events come too fast, old events can be overwritten before they have been