0001 perf-timechart(1)
0002 =================
0003
0004 NAME
0005 ----
0006 perf-timechart - Tool to visualize total system behavior during a workload
0007
0008 SYNOPSIS
0009 --------
0010 [verse]
0011 'perf timechart' [<timechart options>] {record} [<record options>]
0012
0013 DESCRIPTION
0014 -----------
0015 There are two variants of perf timechart:
0016
0017 'perf timechart record <command>' to record the system level events
0018 of an arbitrary workload. By default timechart records only scheduler
0019 and CPU events (task switches, running times, CPU power states, etc),
0020 but it's possible to record IO (disk, network) activity using -I argument.
0021
0022 'perf timechart' to turn a trace into a Scalable Vector Graphics file,
0023 that can be viewed with popular SVG viewers such as 'Inkscape'. Depending
0024 on the events in the perf.data file, timechart will contain scheduler/cpu
0025 events or IO events.
0026
0027 In IO mode, every bar has two charts: upper and lower.
0028 Upper bar shows incoming events (disk reads, ingress network packets).
0029 Lower bar shows outgoing events (disk writes, egress network packets).
0030 There are also poll bars which show how much time application spent
0031 in poll/epoll/select syscalls.
0032
0033 TIMECHART OPTIONS
0034 -----------------
0035 -o::
0036 --output=::
0037 Select the output file (default: output.svg)
0038 -i::
0039 --input=::
0040 Select the input file (default: perf.data unless stdin is a fifo)
0041 -w::
0042 --width=::
0043 Select the width of the SVG file (default: 1000)
0044 -P::
0045 --power-only::
0046 Only output the CPU power section of the diagram
0047 -T::
0048 --tasks-only::
0049 Don't output processor state transitions
0050 -p::
0051 --process::
0052 Select the processes to display, by name or PID
0053 -f::
0054 --force::
0055 Don't complain, do it.
0056 --symfs=<directory>::
0057 Look for files with symbols relative to this directory.
0058 -n::
0059 --proc-num::
0060 Print task info for at least given number of tasks.
0061 -t::
0062 --topology::
0063 Sort CPUs according to topology.
0064 --highlight=<duration_nsecs|task_name>::
0065 Highlight tasks (using different color) that run more than given
0066 duration or tasks with given name. If number is given it's interpreted
0067 as number of nanoseconds. If non-numeric string is given it's
0068 interpreted as task name.
0069 --io-skip-eagain::
0070 Don't draw EAGAIN IO events.
0071 --io-min-time=<nsecs>::
0072 Draw small events as if they lasted min-time. Useful when you need
0073 to see very small and fast IO. It's possible to specify ms or us
0074 suffix to specify time in milliseconds or microseconds.
0075 Default value is 1ms.
0076 --io-merge-dist=<nsecs>::
0077 Merge events that are merge-dist nanoseconds apart.
0078 Reduces number of figures on the SVG and makes it more render-friendly.
0079 It's possible to specify ms or us suffix to specify time in
0080 milliseconds or microseconds.
0081 Default value is 1us.
0082
0083 RECORD OPTIONS
0084 --------------
0085 -P::
0086 --power-only::
0087 Record only power-related events
0088 -T::
0089 --tasks-only::
0090 Record only tasks-related events
0091 -I::
0092 --io-only::
0093 Record only io-related events
0094 -g::
0095 --callchain::
0096 Do call-graph (stack chain/backtrace) recording
0097
0098 EXAMPLES
0099 --------
0100
0101 $ perf timechart record git pull
0102
0103 [ perf record: Woken up 13 times to write data ]
0104 [ perf record: Captured and wrote 4.253 MB perf.data (~185801 samples) ]
0105
0106 $ perf timechart
0107
0108 Written 10.2 seconds of trace to output.svg.
0109
0110 Record system-wide timechart:
0111
0112 $ perf timechart record
0113
0114 then generate timechart and highlight 'gcc' tasks:
0115
0116 $ perf timechart --highlight gcc
0117
0118 Record system-wide IO events:
0119
0120 $ perf timechart record -I
0121
0122 then generate timechart:
0123
0124 $ perf timechart
0125
0126 SEE ALSO
0127 --------
0128 linkperf:perf-record[1]