aboutsummaryrefslogtreecommitdiff
path: root/Examples/rb_lines_example.txt
blob: 544b508f62828ac0a4b3dbd8df6df5564552443e (plain) (blame)
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
This simple script uses the line probe to count how many times a line was
executed in a Ruby program.  In this example you can see it running on the
Code/Ruby/func_slow.rb program.

# rb_lines.d
Tracing... Hit Ctrl-C to end.
^C
                             FILE:LINE        COUNT
                     func_slow.rb:3               1
                     func_slow.rb:4               1
                     func_slow.rb:5               1
                     func_slow.rb:6               1
                     func_slow.rb:12              1
                     func_slow.rb:13              1
                     func_slow.rb:14              1
                     func_slow.rb:15              1
                     func_slow.rb:19              1
                     func_slow.rb:22              1
                     func_slow.rb:23              1
                     func_slow.rb:24              1
                     func_slow.rb:25              1
                     func_slow.rb:29              1
                     func_slow.rb:32              1
                     func_slow.rb:26         100000
                     func_slow.rb:27         100000
                     func_slow.rb:16         200000
                     func_slow.rb:17         200000
                     func_slow.rb:7          300000
                     func_slow.rb:8          300000