[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20161207020629.GB17879@sejong>
Date: Wed, 7 Dec 2016 11:06:29 +0900
From: Namhyung Kim <namhyung@...nel.org>
To: David Ahern <dsahern@...il.com>
CC: Arnaldo Carvalho de Melo <acme@...nel.org>,
Ingo Molnar <mingo@...nel.org>,
Peter Zijlstra <peterz@...radead.org>,
Jiri Olsa <jolsa@...nel.org>,
LKML <linux-kernel@...r.kernel.org>,
Andi Kleen <andi@...stfloor.org>,
Minchan Kim <minchan@...nel.org>
Subject: Re: [PATCH 03/10] perf sched timehist: Handle zero sample->tid
properly
On Mon, Dec 05, 2016 at 07:52:57PM -0800, David Ahern wrote:
> On 12/5/16 7:40 PM, Namhyung Kim wrote:
> > Sometimes samples have tid of 0 but non-0 pid. It ends up having a
>
> Any idea how that happens?
It seems that an exiting task wakes up its parent and the parent might
call wait(2) concurrently. So at the time of calling last schedule(),
its pid (and tgid) link might be unhashed by the parent and can have 0
sample->tid and/or sample->pid depending on timing IMHO. Not sure
anything guarantees that the sample tid/pid is preserved during the
event. From a quick look I couldn't find..
If that's true we need to somehow make sure that sample->tid of 0 is
actually from idle task or not.
Thanks,
Namhyung
Powered by blists - more mailing lists