summaryrefslogtreecommitdiffstats
path: root/cddl/contrib/dtracetoolkit/Examples/tcl_cpudist_example.txt
blob: 09126f603abcd03724a584314a4b4ee2976a224e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
The following are examples of tcl_cpudist.d.

This script traces the on-CPU time of Tcl commands and procedures and
prints a report containing distribution plots per subroutine. Here it
traces the example program, Code/Tcl/func_slow.tcl.

# tcl_cpudist.d
Tracing... Hit Ctrl-C to end.
^C

Top 10 exclusive on-CPU times (us),
   PID=16043, cmd, info 
           value  ------------- Distribution ------------- count    
               0 |                                         0        
               1 |@@@@                                     1        
               2 |@@@@@@@@@@@@@@@                          4        
               4 |@@@@                                     1        
               8 |@@@@                                     1        
              16 |@@@@@@@@@@@                              3        
              32 |@@@@                                     1        
              64 |                                         0        

   PID=16043, cmd, namespace 
           value  ------------- Distribution ------------- count    
               0 |                                         0        
               1 |@@@@@@@@@@@@@                            1        
               2 |@@@@@@@@@@@@@                            1        
               4 |                                         0        
               8 |                                         0        
              16 |                                         0        
              32 |                                         0        
              64 |                                         0        
             128 |@@@@@@@@@@@@@                            1        
             256 |                                         0        

   PID=16043, cmd, puts 
           value  ------------- Distribution ------------- count    
              16 |                                         0        
              32 |@@@@@@@@@@@@@@@@@@@@@@@@@@@              2        
              64 |                                         0        
             128 |@@@@@@@@@@@@@                            1        
             256 |                                         0        

   PID=16043, cmd, if 
           value  ------------- Distribution ------------- count    
               4 |                                         0        
               8 |@@@@@@@@@@                               2        
              16 |@@@@@@@@@@@@@@@@@@@@                     4        
              32 |@@@@@                                    1        
              64 |                                         0        
             128 |@@@@@                                    1        
             256 |                                         0        

   PID=16043, cmd, tclInit 
           value  ------------- Distribution ------------- count    
             128 |                                         0        
             256 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1        
             512 |                                         0        

   PID=16043, cmd, file 
           value  ------------- Distribution ------------- count    
               2 |                                         0        
               4 |@@@@@@@@@@@@@                            4        
               8 |@@@@@@@@@@@@@                            4        
              16 |                                         0        
              32 |@@@                                      1        
              64 |@@@@@@@@@@                               3        
             128 |                                         0        

   PID=16043, cmd, source 
           value  ------------- Distribution ------------- count    
             256 |                                         0        
             512 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1        
            1024 |                                         0        

   PID=16043, proc, func_a 
           value  ------------- Distribution ------------- count    
          262144 |                                         0        
          524288 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1        
         1048576 |                                         0        

   PID=16043, proc, func_b 
           value  ------------- Distribution ------------- count    
          524288 |                                         0        
         1048576 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1        
         2097152 |                                         0        

   PID=16043, proc, func_c 
           value  ------------- Distribution ------------- count    
          524288 |                                         0        
         1048576 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1        
         2097152 |                                         0        


Top 10 inclusive on-CPU times (us),
   PID=16043, cmd, source 
           value  ------------- Distribution ------------- count    
             512 |                                         0        
            1024 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1        
            2048 |                                         0        

   PID=16043, cmd, uplevel 
           value  ------------- Distribution ------------- count    
             512 |                                         0        
            1024 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1        
            2048 |                                         0        

   PID=16043, proc, tclInit 
           value  ------------- Distribution ------------- count    
             512 |                                         0        
            1024 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1        
            2048 |                                         0        

   PID=16043, cmd, tclInit 
           value  ------------- Distribution ------------- count    
            1024 |                                         0        
            2048 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1        
            4096 |                                         0        

   PID=16043, cmd, func_c 
           value  ------------- Distribution ------------- count    
          524288 |                                         0        
         1048576 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1        
         2097152 |                                         0        

   PID=16043, proc, func_c 
           value  ------------- Distribution ------------- count    
          524288 |                                         0        
         1048576 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1        
         2097152 |                                         0        

   PID=16043, cmd, func_a 
           value  ------------- Distribution ------------- count    
         1048576 |                                         0        
         2097152 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1        
         4194304 |                                         0        

   PID=16043, cmd, func_b 
           value  ------------- Distribution ------------- count    
         1048576 |                                         0        
         2097152 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1        
         4194304 |                                         0        

   PID=16043, proc, func_a 
           value  ------------- Distribution ------------- count    
         1048576 |                                         0        
         2097152 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1        
         4194304 |                                         0        

   PID=16043, proc, func_b 
           value  ------------- Distribution ------------- count    
         1048576 |                                         0        
         2097152 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 1        
         4194304 |                                         0        

These on-CPU times are the time the thread spent running on a CPU, from when
the subroutine began to when it completed. This does not include time
spent off-CPU time such as sleeping for I/O or waiting for scheduling.

On-CPU times are useful for showing who is causing the CPUs to be busy.
See Notes/ALLoncpu_notes.txt for more details. Also see
Notes/ALLexclusive_notes.txt and Notes/ALLinclusive_notes.txt for a
detailed explanation of exclusive vs inclusive subroutine time.

OpenPOWER on IntegriCloud