[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <alpine.DEB.2.11.1501221305150.14136@vincent-weaver-1.umelst.maine.edu>
Date: Thu, 22 Jan 2015 13:09:11 -0500 (EST)
From: Vince Weaver <vincent.weaver@...ne.edu>
To: Jiri Olsa <jolsa@...hat.com>
cc: Vince Weaver <vincent.weaver@...ne.edu>,
linux-kernel@...r.kernel.org, Jiri Olsa <jolsa@...nel.org>,
Peter Zijlstra <a.p.zijlstra@...llo.nl>,
Arnaldo Carvalho de Melo <acme@...hat.com>,
Ingo Molnar <mingo@...nel.org>,
Paul Mackerras <paulus@...ba.org>
Subject: Re: perf: behavior of poll() changed in 3.18
On Thu, 22 Jan 2015, Jiri Olsa wrote:
> > So what happens if you are using a signal handler to monitor a child and
> > the child exits?
>
> AFAICS wrt to SIGIO, we notify only with POLL_IN if there's new data
> and POLL_HUP if we reached the event_limit - the one you set with
> PERF_EVENT_IOC_REFRESH ioctl
I wrote a test for this: if you are monitoring another process with a
SIGIO handler and the other process dies, then you get no signal for this
at all, and in fact depending on the timing the last valid SIGIO overflow
event signal might get lost (in my test I usually get one fewer
POLL_IN signal than I would get from the equivelent poll() code).
> I've actually never used the SIGIO interface in perf other than
> when I was checking your gi repo with test code ;-)
Yes, it seems that PAPI is really the only infrastructure that tries to do
self-monitoring using the SIGIO interface. Which shows, as it breaks now
and then. That was the whole reason I started writing my perf_event_test
infrastructure in the first place.
Vince
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists