Browse Source

Plan 9 from Bell Labs 2007-04-02

David du Colombier 17 years ago
parent
commit
e3c9b62358
4 changed files with 16 additions and 6 deletions
  1. 1 1
      dist/replica/_plan9.db
  2. 1 1
      dist/replica/plan9.db
  3. 1 0
      dist/replica/plan9.log
  4. 13 4
      sys/man/1/prof

+ 1 - 1
dist/replica/_plan9.db

@@ -7372,7 +7372,7 @@ sys/man/1/pipefile - 664 sys sys 984709628 1861
 sys/man/1/plot - 664 sys sys 944959673 1196
 sys/man/1/plumb - 664 sys sys 957920007 1297
 sys/man/1/pr - 664 sys sys 1158202686 1819
-sys/man/1/prof - 664 sys sys 1067718952 3561
+sys/man/1/prof - 664 sys sys 1175407194 3594
 sys/man/1/proof - 664 sys sys 1113743329 2300
 sys/man/1/ps - 664 sys sys 1144686669 1722
 sys/man/1/ps2pdf - 664 sys sys 1032632098 1359

+ 1 - 1
dist/replica/plan9.db

@@ -7372,7 +7372,7 @@ sys/man/1/pipefile - 664 sys sys 984709628 1861
 sys/man/1/plot - 664 sys sys 944959673 1196
 sys/man/1/plumb - 664 sys sys 957920007 1297
 sys/man/1/pr - 664 sys sys 1158202686 1819
-sys/man/1/prof - 664 sys sys 1067718952 3561
+sys/man/1/prof - 664 sys sys 1175407194 3594
 sys/man/1/proof - 664 sys sys 1113743329 2300
 sys/man/1/ps - 664 sys sys 1144686669 1722
 sys/man/1/ps2pdf - 664 sys sys 1032632098 1359

+ 1 - 0
dist/replica/plan9.log

@@ -48108,3 +48108,4 @@
 1175324417 0 c sys/src/9/pc/etherga620.c - 664 sys sys 1175322931 29912
 1175324417 1 c sys/src/cmd/upas/fs/fs.c - 664 sys sys 1175322795 26929
 1175324417 2 c sys/src/cmd/upas/fs/plan9.c - 664 sys sys 1175322803 7498
+1175407297 0 c sys/man/1/prof - 664 sys sys 1175407194 3594

+ 13 - 4
sys/man/1/prof

@@ -50,9 +50,11 @@ prints the dynamic call graph of the target program,
 annotating the calls with the time spent in each routine
 and those it calls, recursively.  The output is indented
 two spaces for each call, and is formatted as
+.IP
 .EX
-	symbol:time/ncall
+symbol:time/ncall
 .EE
+.LP
 where
 .I symbol
 is the entry point of the call,
@@ -87,9 +89,11 @@ producing a file called
 .B prof.\f2pid\fP.
 If a process forks, only the parent will continue to be profiled.  Forked children
 can cause themselves to be profile by calling
+.IP
 .EX
-    prof(fn, arg, entries, what)
+prof(fn, arg, entries, what)
 .EE
+.LP
 which causes the function \f2fn\fP(\f2arg\fP) to be profiled.  When \f2fn\fP
 returns 
 .B prof.\f2pid\fP
@@ -120,13 +124,17 @@ It must be run while the program is still active, since the data is stored with
 To enable
 .I tprof
 profiling for a given process,
+.IP
 .EX
-    echo profile > /proc/\f2pid\f1/ctl
+echo profile > /proc/\f2pid\f1/ctl
 .EE
+.LP
 and then, after the program has run for a while, execute
+.IP
 .EX
-    tprof \f2pid\f1
+tprof \f2pid\f1
 .EE
+.LP
 Since the data collected for
 .I tprof
 is based on interrupt-time sampling of the program counter,
@@ -155,4 +163,5 @@ has no options and cannot present dynamic data.
 .B /sys/src/cmd/kprof.c
 .SH SEE ALSO
 .IR 2l (1),
+.IR exec (2),
 .IR kprof (3)