9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: Peter Bosch <pb@research.bell-labs.com>
To: 9fans@cse.psu.edu
Subject: Re: [9fans] trace.c
Date: Tue, 27 Jan 2004 14:58:52 -0500	[thread overview]
Message-ID: <d43d860f1c84bd4a71dada98076fa2d4@plan9.bell-labs.com> (raw)
In-Reply-To: <97ec848e6375883f7a411b0a78fb3a50@plan9.ucalgary.ca>

> trace.c came with the Jan 22 pull, but what is it?  it does show
> somewhat interesting pictures and tells me how much certain processes
> have been using the CPU, but without a man page the mind boggles :)

trace shows the kernel scheduling actions and when interrupts
occur.  it reads scheduling events from /proc/trace (unfortunately
binary format only).  the definition of a trace event can be found
in /sys/include/trace.h.

to switch on tracing:

	echo traceon > /proc/<pid>/ctl

to switch it off again:

	echo traceoff > /proc/<pid>/ctl

when real-time processes are used it also shows you the release
times and deadlines of processes.

'q'	quits trace
'+'	zooms in
'-'	zooms out
'p'	pauses trace

(hmm, i guess the above _is_ the man page ;-)).


peter.



  reply	other threads:[~2004-01-27 19:58 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-27 19:48 mirtchov
2004-01-27 19:58 ` Peter Bosch [this message]
2004-01-28  8:13   ` Skip Tavakkolian
2004-01-28 10:46     ` Bruce Ellis
2004-01-28 13:06       ` boyd, rounin
2004-01-28 13:00     ` Sape Mullender
2004-01-28 15:52       ` Rob Pike
2004-01-28 16:21         ` Sape Mullender
2004-01-29  1:48           ` Geoff Collyer
2004-01-29  1:56             ` Peter Bosch
2004-01-29  2:34               ` Geoff Collyer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=d43d860f1c84bd4a71dada98076fa2d4@plan9.bell-labs.com \
    --to=pb@research.bell-labs.com \
    --cc=9fans@cse.psu.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).