Re: [PATCH 04/10] perf sched timehist: Split is_idle_sample()

From: David Ahern
Date: Mon Dec 05 2016 - 22:57:54 EST


On 12/5/16 7:40 PM, Namhyung Kim wrote:
> The is_idle_sample() function actually does more than determining
> whether sample come from idle task. Split the callchain part into
> save_task_callchain() to make it clearer. Also checking prev_pid from
> trace data looks unnecessary since it should be always same as
> sample->pid.

The timehist command is 3-4 years old now, and over that time it has been used on a variety of OS'es -- RHEL6, WRL5, WRL6, various Fedora and debian releases, etc.

The idle_sample checks were added for a reason. Given the range of kernels that have sched tracepoints I'd be wary of just removing it regardless of how silly it seems against top of tree kernels.