This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: space query


Hi,

Here is some information, experts will correct any mistake:
- We shall see probes like extra code of a function. So it of course adds to the duration of the thread that triggered it or was running at that time

- kernel probes (kernel functions, tracepoints, ...) execute in kernel context as they instrument kernel. They add duration to the "run" state of the pid that triggered it. For example, if you probe a syscall, each time one thread calls it, probe handling will be added to its run time. But well, it is a bit more complex as not all functions are really triggered by a thread execution

- interrupts will not really be covered by schedtimes.stp. They will "add" to currently running thread (can be idle task "swapper")

- timer probes execute in kernel context and should add "duration" to the pid that was running at that time.

- don't know for user probes

- I don't know how the transport layer impacts duration. You will see a "stapio" thread in userspace taking care of reading trace if you made any. Systemtap also wakes-up regularly to check if there is any buffer trace to output. It used to be in a workqueue (so visible as a thread), but implementation has changed.


In your case, you have "sched_switch" and "sched_wakeup" probes. This is a bit specific because code decides itself to put duration inside prev or next thread.
- Execution cost of "sched_switch" will be shared between previous and next threads as per the code. Hard to say which part shall really go to previous and which one to next but approximation is OK
- "sched_wakeup" would be like interrupts, it fires inside a running task and will add to it even if not related.



Regards
Fred

OMAP Platform Business Unit - OMAP System Engineering - Platform Enablement - System Multimedia


>
Texas Instruments France SA, 821 Avenue Jack Kilby, 06270 Villeneuve Loubet. 036 420 040 R.C.S Antibes. Capital de EUR 753.920

-----Original Message-----
> From: systemtap-owner@sourceware.org [mailto:systemtap-owner@sourceware.org] On Behalf Of sscheider
> Sent: Sunday, March 11, 2012 8:09 PM
> To: systemtap@sourceware.org
> Subject: space query
>
>
> Howdy!  I am wondering if systemtap probes run in kernel or user space.  In
> either case, do the probes contribute to the "run" state duration of a given
> PID?  If so, which?  I'm using schedtimes.stp.
> Thanks!
> --
> View this message in context: http://old.nabble.com/space-query-tp33482258p33482258.html
> Sent from the Sourceware - systemtap mailing list archive at Nabble.com.



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]