lkml.org 
[lkml]   [2015]   [Jun]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC PATCH] perf: Add PERF_RECORD_SWITCH to indicate context switches
On 6/12/15 5:12 AM, Adrian Hunter wrote:
>>> This new PERF_RECORD_SWITCH event does not have those problems
>>> and it also has a couple of other small advantages. It is
>>> easier to use because it is an auxiliary event (like mmap,
>>> comm and task events) which can be enabled by setting a single
>>> bit. It is smaller than sched:sched_switch and easier to parse.
>>
>> Right, so the one wee problem I have is that this only provides sched_in
>> data, I imagine people might be interested in sched_out as well.
>
> That is not a problem although it would be interesting to know the use-case.
> To me it seemed unreasonable to expect to analyze scheduler behaviour
> without admin-level privileges since it is inherently an administrative
> activity.

One use case is wanting to analyze a set of processes -- how long they
run when scheduled, where they are when scheduled out, scheduling delay
on wakeups, time between scehd in. I wrote the timehist tool in 2010 it
has been really helpful understanding what is happening on each cpu and
characteristics of a set of processes (e.g. ping ponging between tasks
sending messages to each other).

In this case it is not necessarily scheduler behavior (though it does it
enter the picture to a degree), but rather behavior of a process or set
of tasks.


\
 
 \ /
  Last update: 2015-06-12 17:21    [W:1.673 / U:0.020 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site