]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/blob - cddl/contrib/dtracetoolkit/Examples/php_flowinfo_example.txt
Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.
[FreeBSD/stable/10.git] / cddl / contrib / dtracetoolkit / Examples / php_flowinfo_example.txt
1 The following are examples of php_flowinfo.d.
2
3 This is a simple script to trace the flow of PHP functions.
4 Here it traces the example program, Code/Php/func_abc.php
5
6 # php_flowinfo.d 
7 C    PID/TID   DELTA(us)              FILE:LINE TYPE     -- FUNC
8 0  18422/1             9      func_abc.php:22   func     -> func_a
9 0  18422/1            35      func_abc.php:18   func       -> sleep
10 0  18422/1       1009146      func_abc.php:18   func       <- sleep
11 0  18422/1            35      func_abc.php:19   func       -> func_b
12 0  18422/1            24      func_abc.php:11   func         -> sleep
13 0  18422/1       1009803      func_abc.php:11   func         <- sleep
14 0  18422/1            34      func_abc.php:12   func         -> func_c
15 0  18422/1            24      func_abc.php:5    func           -> sleep
16 0  18422/1       1009953      func_abc.php:5    func           <- sleep
17 0  18422/1            28      func_abc.php:6    func         <- func_c
18 0  18422/1            11      func_abc.php:13   func       <- func_b
19 0  18422/1            10      func_abc.php:20   func     <- func_a
20 ^C
21
22 The third column is indented by 2 spaces to show when a new function begins. 
23 This shows which function is calling which - the output above begins by 
24 showing that func_a() began; slept, and returned from sleep; and then called 
25 func_b().
26
27 The DELTA(us) column shows time from that line to the previous line, and
28 so can be a bit tricky to read. For example, the second line of data output
29 (skipping the header) reads as "the time from func_a() beginning to
30 calling the sleep function beginning was 35 microseconds".
31
32 The LINE column shows the line in the file what was being executed. Refer
33 to the source program to see what this line refers to.
34
35 If the output looks shuffled, check the CPU "C" column - if it changes,
36 then the output is probably shuffled. See Notes/ALLsnoop_notes.txt for
37 details and suggested workarounds.
38
39 See Notes/ALLflow_notes.txt for important notes about reading flow outputs.
40