]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/blob - cddl/contrib/dtracetoolkit/Examples/js_flow_example.txt
MFC r368207,368607:
[FreeBSD/stable/10.git] / cddl / contrib / dtracetoolkit / Examples / js_flow_example.txt
1 The following are examples of js_flow.d.
2
3 This is a simple script to trace the flow of JavaScript functions.
4 Here it traces the example program, Code/JavaScript/func_clock.html
5
6 # js_flow.d 
7   C TIME(us)         FILE                   -- FUNC
8   0 3650471830941    func_clock.html        -> start
9   0 3650471831005    func_clock.html          -> getElementById
10   0 3650471831058    func_clock.html          <- getElementById
11   0 3650471831890    func_clock.html          -> func_a
12   0 3650471831906    func_clock.html            -> getElementById
13   0 3650471831929    func_clock.html            <- getElementById
14   0 3650471850084    func_clock.html            -> func_b
15   0 3650471850111    func_clock.html              -> getElementById
16   0 3650471850146    func_clock.html              <- getElementById
17   0 3650471886534    func_clock.html              -> func_c
18   0 3650471886573    func_clock.html                -> getElementById
19   0 3650471886624    func_clock.html                <- getElementById
20   0 3650471942212    func_clock.html              <- func_c
21   0 3650471942231    func_clock.html            <- func_b
22   0 3650471942242    func_clock.html          <- func_a
23   0 3650471942300    func_clock.html          -> setTimeout
24   0 3650471942392    func_clock.html          <- setTimeout
25   0 3650471942404    func_clock.html        <- start
26 ^C
27
28 The fourth column is indented by 2 spaces to show when a new function begins.
29 This shows which function is calling which - the output above shows that
30 func_a called func_b, which in turn called func_c.
31
32 The TIME(us) column shows time from boot in microseconds.
33
34 The FILE column shows the file that was being executed.
35
36 If the output looks strange, check the CPU "C" column - if it changes,
37 then the output is probably shuffled. See Notes/ALLsnoop_notes.txt for
38 details and suggested workarounds.
39
40 See Notes/ALLflow_notes.txt for important notes about reading flow outputs.
41