Arnaldo Carvalho de Melo | 514f1c6 | 2012-09-26 20:05:56 -0300 | [diff] [blame] | 1 | perf-trace(1) |
| 2 | ============= |
| 3 | |
| 4 | NAME |
| 5 | ---- |
| 6 | perf-trace - strace inspired tool |
| 7 | |
| 8 | SYNOPSIS |
| 9 | -------- |
| 10 | [verse] |
| 11 | 'perf trace' |
| 12 | |
| 13 | DESCRIPTION |
| 14 | ----------- |
| 15 | This command will show the events associated with the target, initially |
| 16 | syscalls, but other system events like pagefaults, task lifetime events, |
| 17 | scheduling events, etc. |
| 18 | |
| 19 | Initially this is a live mode only tool, but eventually will work with |
| 20 | perf.data files like the other tools, allowing a detached 'record' from |
| 21 | analysis phases. |
| 22 | |
| 23 | OPTIONS |
| 24 | ------- |
| 25 | |
David Ahern | ac9be8e | 2013-08-20 11:15:45 -0600 | [diff] [blame] | 26 | -a:: |
Arnaldo Carvalho de Melo | 514f1c6 | 2012-09-26 20:05:56 -0300 | [diff] [blame] | 27 | --all-cpus:: |
| 28 | System-wide collection from all CPUs. |
| 29 | |
Arnaldo Carvalho de Melo | 2ae3a31 | 2013-08-09 12:28:31 -0300 | [diff] [blame] | 30 | -e:: |
| 31 | --expr:: |
| 32 | List of events to show, currently only syscall names. |
Arnaldo Carvalho de Melo | b059efd | 2013-08-21 12:56:21 -0300 | [diff] [blame] | 33 | Prefixing with ! shows all syscalls but the ones specified. You may |
| 34 | need to escape it. |
Arnaldo Carvalho de Melo | 2ae3a31 | 2013-08-09 12:28:31 -0300 | [diff] [blame] | 35 | |
Arnaldo Carvalho de Melo | c24ff99 | 2013-08-19 12:01:10 -0300 | [diff] [blame] | 36 | -o:: |
| 37 | --output=:: |
| 38 | Output file name. |
| 39 | |
Arnaldo Carvalho de Melo | 514f1c6 | 2012-09-26 20:05:56 -0300 | [diff] [blame] | 40 | -p:: |
| 41 | --pid=:: |
| 42 | Record events on existing process ID (comma separated list). |
| 43 | |
David Ahern | ac9be8e | 2013-08-20 11:15:45 -0600 | [diff] [blame] | 44 | -t:: |
Arnaldo Carvalho de Melo | 514f1c6 | 2012-09-26 20:05:56 -0300 | [diff] [blame] | 45 | --tid=:: |
| 46 | Record events on existing thread ID (comma separated list). |
| 47 | |
David Ahern | ac9be8e | 2013-08-20 11:15:45 -0600 | [diff] [blame] | 48 | -u:: |
Arnaldo Carvalho de Melo | 514f1c6 | 2012-09-26 20:05:56 -0300 | [diff] [blame] | 49 | --uid=:: |
| 50 | Record events in threads owned by uid. Name or number. |
| 51 | |
Arnaldo Carvalho de Melo | 7c304ee0 | 2013-08-22 16:49:54 -0300 | [diff] [blame] | 52 | -v:: |
| 53 | --verbose=:: |
| 54 | Verbosity level. |
| 55 | |
David Ahern | ac9be8e | 2013-08-20 11:15:45 -0600 | [diff] [blame] | 56 | -i:: |
Arnaldo Carvalho de Melo | 514f1c6 | 2012-09-26 20:05:56 -0300 | [diff] [blame] | 57 | --no-inherit:: |
| 58 | Child tasks do not inherit counters. |
| 59 | |
David Ahern | ac9be8e | 2013-08-20 11:15:45 -0600 | [diff] [blame] | 60 | -m:: |
Arnaldo Carvalho de Melo | 514f1c6 | 2012-09-26 20:05:56 -0300 | [diff] [blame] | 61 | --mmap-pages=:: |
Jiri Olsa | 27050f5 | 2013-09-01 12:36:13 +0200 | [diff] [blame^] | 62 | Number of mmap data pages (must be a power of two) or size |
| 63 | specification with appended unit character - B/K/M/G. The |
| 64 | size is rounded up to have nearest pages power of two value. |
Arnaldo Carvalho de Melo | 514f1c6 | 2012-09-26 20:05:56 -0300 | [diff] [blame] | 65 | |
David Ahern | ac9be8e | 2013-08-20 11:15:45 -0600 | [diff] [blame] | 66 | -C:: |
Arnaldo Carvalho de Melo | 514f1c6 | 2012-09-26 20:05:56 -0300 | [diff] [blame] | 67 | --cpu:: |
| 68 | Collect samples only on the list of CPUs provided. Multiple CPUs can be provided as a |
| 69 | comma-separated list with no space: 0,1. Ranges of CPUs are specified with -: 0-2. |
| 70 | In per-thread mode with inheritance mode on (default), Events are captured only when |
| 71 | the thread executes on the designated CPUs. Default is to monitor all CPUs. |
| 72 | |
Arnaldo Carvalho de Melo | ae9ed03 | 2012-10-08 09:56:00 -0300 | [diff] [blame] | 73 | --duration: |
| 74 | Show only events that had a duration greater than N.M ms. |
| 75 | |
Arnaldo Carvalho de Melo | 1302d88 | 2012-10-17 17:13:12 -0300 | [diff] [blame] | 76 | --sched: |
| 77 | Accrue thread runtime and provide a summary at the end of the session. |
| 78 | |
David Ahern | 6810fc9 | 2013-08-28 22:29:52 -0600 | [diff] [blame] | 79 | -i |
| 80 | --input |
| 81 | Process events from a given perf data file. |
| 82 | |
David Ahern | 4bb0919 | 2013-09-04 12:37:43 -0600 | [diff] [blame] | 83 | -T |
| 84 | --time |
| 85 | Print full timestamp rather time relative to first sample. |
| 86 | |
Arnaldo Carvalho de Melo | 50c95cb | 2013-09-12 12:35:21 -0300 | [diff] [blame] | 87 | --comm:: |
| 88 | Show process COMM right beside its ID, on by default, disable with --no-comm. |
| 89 | |
Arnaldo Carvalho de Melo | 514f1c6 | 2012-09-26 20:05:56 -0300 | [diff] [blame] | 90 | SEE ALSO |
| 91 | -------- |
| 92 | linkperf:perf-record[1], linkperf:perf-script[1] |