~ubuntu-branches/ubuntu/precise/linux-ti-omap4/precise

« back to all changes in this revision

Viewing changes to tools/perf/Documentation/perf-probe.txt

  • Committer: Bazaar Package Importer
  • Author(s): Paolo Pisati
  • Date: 2011-06-29 15:23:51 UTC
  • mfrom: (26.1.1 natty-proposed)
  • Revision ID: james.westby@ubuntu.com-20110629152351-xs96tm303d95rpbk
Tags: 3.0.0-1200.2
* Rebased against 3.0.0-6.7
* BSP from TI based on 3.0.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
16
16
or
17
17
'perf probe' --list
18
18
or
19
 
'perf probe' [options] --line='FUNC[:RLN[+NUM|:RLN2]]|SRC:ALN[+NUM|:ALN2]'
 
19
'perf probe' [options] --line='LINE'
20
20
or
21
21
'perf probe' [options] --vars='PROBEPOINT'
22
22
 
73
73
        (Only for --vars) Show external defined variables in addition to local
74
74
        variables.
75
75
 
 
76
-F::
 
77
--funcs::
 
78
        Show available functions in given module or kernel.
 
79
 
 
80
--filter=FILTER::
 
81
        (Only for --vars and --funcs) Set filter. FILTER is a combination of glob
 
82
        pattern, see FILTER PATTERN for detail.
 
83
        Default FILTER is "!__k???tab_* & !__crc_*" for --vars, and "!_*"
 
84
        for --funcs.
 
85
        If several filters are specified, only the last filter is used.
 
86
 
76
87
-f::
77
88
--force::
78
89
        Forcibly add events with existing name.
117
128
-----------
118
129
Line range is described by following syntax.
119
130
 
120
 
 "FUNC[:RLN[+NUM|-RLN2]]|SRC[:ALN[+NUM|-ALN2]]"
 
131
 "FUNC[@SRC][:RLN[+NUM|-RLN2]]|SRC[:ALN[+NUM|-ALN2]]"
121
132
 
122
133
FUNC specifies the function name of showing lines. 'RLN' is the start line
123
134
number from function entry line, and 'RLN2' is the end line number. As same as
124
135
probe syntax, 'SRC' means the source file path, 'ALN' is start line number,
125
136
and 'ALN2' is end line number in the file. It is also possible to specify how
126
 
many lines to show by using 'NUM'.
 
137
many lines to show by using 'NUM'. Moreover, 'FUNC@SRC' combination is good
 
138
for searching a specific function when several functions share same name.
127
139
So, "source.c:100-120" shows lines between 100th to l20th in source.c file. And "func:10+20" shows 20 lines from 10th line of func function.
128
140
 
129
141
LAZY MATCHING
135
147
 
136
148
This provides some sort of flexibility and robustness to probe point definitions against minor code changes. For example, actual 10th line of schedule() can be moved easily by modifying schedule(), but the same line matching 'rq=cpu_rq*' may still exist in the function.)
137
149
 
 
150
FILTER PATTERN
 
151
--------------
 
152
 The filter pattern is a glob matching pattern(s) to filter variables.
 
153
 In addition, you can use "!" for specifying filter-out rule. You also can give several rules combined with "&" or "|", and fold those rules as one rule by using "(" ")".
 
154
 
 
155
e.g.
 
156
 With --filter "foo* | bar*", perf probe -V shows variables which start with "foo" or "bar".
 
157
 With --filter "!foo* & *bar", perf probe -V shows variables which don't start with "foo" and end with "bar", like "fizzbar". But "foobar" is filtered out.
138
158
 
139
159
EXAMPLES
140
160
--------