diff options
author | jkoshy <jkoshy@FreeBSD.org> | 2007-04-27 12:09:31 +0000 |
---|---|---|
committer | jkoshy <jkoshy@FreeBSD.org> | 2007-04-27 12:09:31 +0000 |
commit | 0dfc7735639067a12a4ccc63487f67169c17b9e1 (patch) | |
tree | ca768572366b64e2143b663b4f43d722aa1665d2 /usr.sbin/pmcstat/pmcstat.8 | |
parent | d4fd0c015ba0676684469ae2c5461c424aa260fb (diff) | |
download | FreeBSD-src-0dfc7735639067a12a4ccc63487f67169c17b9e1.zip FreeBSD-src-0dfc7735639067a12a4ccc63487f67169c17b9e1.tar.gz |
MFP4: Enhancements to pmcstat(8):
- Allow the "-t" option to take a regular expression naming command
line processes to attach process PMCs to.
- Update the manual page and add an example showing the use of the
new functionality.
- Update the (c) year on the affected source files.
Diffstat (limited to 'usr.sbin/pmcstat/pmcstat.8')
-rw-r--r-- | usr.sbin/pmcstat/pmcstat.8 | 39 |
1 files changed, 24 insertions, 15 deletions
diff --git a/usr.sbin/pmcstat/pmcstat.8 b/usr.sbin/pmcstat/pmcstat.8 index cd7ed74..951dba6 100644 --- a/usr.sbin/pmcstat/pmcstat.8 +++ b/usr.sbin/pmcstat/pmcstat.8 @@ -23,7 +23,7 @@ .\" .\" $FreeBSD$ .\" -.Dd April 22, 2007 +.Dd April 23, 2007 .Os .Dt PMCSTAT 8 .Sh NAME @@ -50,7 +50,7 @@ .Op Fl q .Op Fl r Ar fsroot .Op Fl s Ar event-spec -.Op Fl t Ar pid +.Op Fl t Ar process-spec .Op Fl v .Op Fl w Ar secs .Op Ar command Op Ar args @@ -63,18 +63,21 @@ utility measures system performance using the facilities provided by The .Nm utility can measure both hardware events seen by the system as a -whole, and those seen when a specified process is executing on the -system's CPUs. -If a specific process is being targeted (for example, +whole, and those seen when a specified set of processes are executing +on the system's CPUs. +If a specific set of processes is being targeted (for example, if the -.Fl t Ar pid +.Fl t Ar process-spec option is specified, or if a command line is specified using .Ar command ) , -then measurement occurs till the target process exits or -the +then measurement occurs till +.Ar command +exits, or till all target processes specified by the +.Fl t Ar process-spec +options exit, or till the .Nm utility is interrupted by the user. -If a specific process is not targeted for measurement, then +If a specific set of processes is not targeted for measurement, then .Nm will perform system-wide measurements till interrupted by the user. @@ -237,12 +240,13 @@ The default is Allocate a system mode counting PMC measuring hardware events specified in .Ar event-spec . -.It Fl t Ar pid -Attach all process mode PMCs allocated to the process with PID -.Ar pid . -The option is not allowed in conjunction with specifying a -command using -.Ar command . +.It Fl t Ar process-spec +Attach process mode PMCs to the processes named by argument +.Ar process-spec . +Argument +.Ar process-spec +may be a non-negative integer denoting a specific process id, or a +regular expression for selecting processes based on their command names. .It Fl v Increase verbosity. .It Fl w Ar secs @@ -273,6 +277,11 @@ and measure the number of data cache misses suffered by it and its children every 12 seconds on an AMD Athlon, use: .Dl "pmcstat -d -w 12 -p k7-dc-misses mozilla" .Pp +To measure processor instructions retired for all processes named +.Dq emacs +use: +.Dl "pmcstat -t '^emacs$' -p instructions" +.Pp To count instruction tlb-misses on CPUs 0 and 2 on a Intel Pentium Pro/Pentium III SMP system use: .Dl "pmcstat -c 0,2 -s p6-itlb-miss" |