public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: Jiri Olsa <jolsa@redhat.com>
Cc: linux-kernel@vger.kernel.org,
	Arnaldo Carvalho de Melo <acme@ghostprotocols.net>,
	Ingo Molnar <mingo@elte.hu>, Paul Mackerras <paulus@samba.org>,
	Corey Ashford <cjashfor@linux.vnet.ibm.com>,
	Frederic Weisbecker <fweisbec@gmail.com>,
	Namhyung Kim <namhyung@kernel.org>,
	Stephane Eranian <eranian@google.com>
Subject: Re: [PATCH 1/2] perf: Enable wakeup_events logic for all events
Date: Thu, 30 May 2013 13:02:39 +0200	[thread overview]
Message-ID: <20130530110239.GN12193@twins.programming.kicks-ass.net> (raw)
In-Reply-To: <1369907587-8963-2-git-send-email-jolsa@redhat.com>

On Thu, May 30, 2013 at 11:53:06AM +0200, Jiri Olsa wrote:
> Currently the perf_events_attr::wakeup_events logic is
> checked only for regular samples.
> 
> If we have an event that produce only auxiliary events
> (MMAP|COMM|EXIT|FORK), the poll call does not follow
> the perf_events_attr wakeup_events setup and reports
> no data.
> 
> Fixing this by moving the perf_events_attr::wakeup_events
> checking logic into the function and calling it from
> perf_output_end. This way any output event is checked
> properly.
> 

So something like this came up before and ISTR doing a patch similar to
what you propose but ended up not going with it because... uhm...

I have vague memories about people (possibly me) wanting wake_events to
mean samples. Like get me a wakeup every 20 samples. With your patch the
side-band events now also count towards 'events'.

I think the most common use of wake_events is people setting it to 1 and
have perf generate a SIGfoo for every sample so they can do magic in
their userspace signal handler. This is popular for interpreters.

It would be unfortunate to get SIGfoos for side-band chatter.


Makes sense?

  reply	other threads:[~2013-05-30 11:03 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-30  9:53 [PATCH 0/2] perf: Fix wakeup_events logic Jiri Olsa
2013-05-30  9:53 ` [PATCH 1/2] perf: Enable wakeup_events logic for all events Jiri Olsa
2013-05-30 11:02   ` Peter Zijlstra [this message]
2013-05-30 11:45     ` Jiri Olsa
2013-05-30 11:51     ` Arnaldo Carvalho de Melo
2013-05-30 11:56       ` Jiri Olsa
2013-05-30  9:53 ` [PATCH 2/2] perf tests: Add auxiliary events poll automated test Jiri Olsa

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20130530110239.GN12193@twins.programming.kicks-ass.net \
    --to=peterz@infradead.org \
    --cc=acme@ghostprotocols.net \
    --cc=cjashfor@linux.vnet.ibm.com \
    --cc=eranian@google.com \
    --cc=fweisbec@gmail.com \
    --cc=jolsa@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=namhyung@kernel.org \
    --cc=paulus@samba.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox