Masami Hiramatsu | 595c364 | 2009-10-16 20:08:27 -0400 | [diff] [blame] | 1 | perf-probe(1) |
| 2 | ============= |
| 3 | |
| 4 | NAME |
| 5 | ---- |
| 6 | perf-probe - Define new dynamic tracepoints |
| 7 | |
| 8 | SYNOPSIS |
| 9 | -------- |
| 10 | [verse] |
Masami Hiramatsu | c937fe2 | 2009-12-08 17:03:30 -0500 | [diff] [blame] | 11 | 'perf probe' [options] --add='PROBE' [...] |
Masami Hiramatsu | c43f9d1 | 2009-11-03 19:12:13 -0500 | [diff] [blame] | 12 | or |
Masami Hiramatsu | c937fe2 | 2009-12-08 17:03:30 -0500 | [diff] [blame] | 13 | 'perf probe' [options] PROBE |
| 14 | or |
| 15 | 'perf probe' [options] --del='[GROUP:]EVENT' [...] |
| 16 | or |
| 17 | 'perf probe' --list |
Masami Hiramatsu | 595c364 | 2009-10-16 20:08:27 -0400 | [diff] [blame] | 18 | |
| 19 | DESCRIPTION |
| 20 | ----------- |
| 21 | This command defines dynamic tracepoint events, by symbol and registers |
| 22 | without debuginfo, or by C expressions (C line numbers, C function names, |
| 23 | and C local variables) with debuginfo. |
| 24 | |
| 25 | |
| 26 | OPTIONS |
| 27 | ------- |
| 28 | -k:: |
Masami Hiramatsu | c43f9d1 | 2009-11-03 19:12:13 -0500 | [diff] [blame] | 29 | --vmlinux=PATH:: |
Masami Hiramatsu | 595c364 | 2009-10-16 20:08:27 -0400 | [diff] [blame] | 30 | Specify vmlinux path which has debuginfo (Dwarf binary). |
| 31 | |
| 32 | -v:: |
| 33 | --verbose:: |
| 34 | Be more verbose (show parsed arguments, etc). |
| 35 | |
Masami Hiramatsu | c43f9d1 | 2009-11-03 19:12:13 -0500 | [diff] [blame] | 36 | -a:: |
Masami Hiramatsu | c937fe2 | 2009-12-08 17:03:30 -0500 | [diff] [blame] | 37 | --add=:: |
| 38 | Define a probe event (see PROBE SYNTAX for detail). |
| 39 | |
| 40 | -d:: |
| 41 | --del=:: |
| 42 | Delete a probe event. |
| 43 | |
| 44 | -l:: |
| 45 | --list:: |
| 46 | List up current probe events. |
Masami Hiramatsu | 595c364 | 2009-10-16 20:08:27 -0400 | [diff] [blame] | 47 | |
| 48 | PROBE SYNTAX |
| 49 | ------------ |
| 50 | Probe points are defined by following syntax. |
| 51 | |
Masami Hiramatsu | af663d7 | 2009-12-15 10:32:18 -0500 | [diff] [blame^] | 52 | "[EVENT=]FUNC[+OFFS|:RLN|%return][@SRC]|SRC:ALN [ARG ...]" |
Masami Hiramatsu | 595c364 | 2009-10-16 20:08:27 -0400 | [diff] [blame] | 53 | |
Masami Hiramatsu | af663d7 | 2009-12-15 10:32:18 -0500 | [diff] [blame^] | 54 | 'EVENT' specifies the name of new event, if omitted, it will be set the name of the probed function. Currently, event group name is set as 'probe'. |
Masami Hiramatsu | c43f9d1 | 2009-11-03 19:12:13 -0500 | [diff] [blame] | 55 | 'FUNC' specifies a probed function name, and it may have one of the following options; '+OFFS' is the offset from function entry address in bytes, 'RLN' is the relative-line number from function entry line, and '%return' means that it probes function return. In addition, 'SRC' specifies a source file which has that function. |
| 56 | It is also possible to specify a probe point by the source line number by using 'SRC:ALN' syntax, where 'SRC' is the source file path and 'ALN' is the line number. |
Masami Hiramatsu | 595c364 | 2009-10-16 20:08:27 -0400 | [diff] [blame] | 57 | 'ARG' specifies the arguments of this probe point. You can use the name of local variable, or kprobe-tracer argument format (e.g. $retval, %ax, etc). |
| 58 | |
| 59 | SEE ALSO |
| 60 | -------- |
| 61 | linkperf:perf-trace[1], linkperf:perf-record[1] |