Lines Matching +full:aux +full:- +full:bus

1 perf-record(1)
5 ----
6 perf-record - Run a command and record its profile into perf.data
9 --------
11 'perf record' [-e <EVENT> | --event=EVENT] [-a] <command>
12 'perf record' [-e <EVENT> | --event=EVENT] [-a] \-- <command> [<options>]
15 -----------
17 from it, into perf.data - without displaying anything.
23 -------
27 -e::
28 --event=::
31 - a symbolic event name (use 'perf list' to list all events)
33 - a raw PMU event in the form of rN where N is a hexadecimal value
36 /sys/bus/event_source/devices/cpu/format/*.
38 - a symbolic or raw PMU event followed by an optional colon
39 and a list of event modifiers, e.g., cpu-cycles:p. See the
40 linkperf:perf-list[1] man page for details on event modifiers.
42 - a symbolically formed PMU event like 'pmu/param1=0x3,param2/' where
44 /sys/bus/event_source/devices/<pmu>/format/*.
46 - a symbolically formed event like 'pmu/config=M,config1=N,config3=K/'
50 corresponding entries in /sys/bus/event_source/devices/<pmu>/format/*
52 /sys/bus/event_source/devices/<pmu>/format/*
57 - 'period': Set event sampling period
58 - 'freq': Set event sampling frequency
59 - 'time': Disable/enable time stamping. Acceptable values are 1 for
62 - 'call-graph': Disable/enable callgraph. Acceptable str are "fp" for
65 - 'stack-size': user stack size for dwarf mode
66 - 'name' : User defined event name. Single quotes (') may be used to
69 - 'aux-output': Generate AUX records instead of events. This requires
70 that an AUX area event is also provided.
71 - 'aux-sample-size': Set sample size for AUX area sampling. If the
72 '--aux-sample' option has been used, set aux-sample-size=0 to disable
73 AUX area sampling for the event.
75 See the linkperf:perf-list[1] man page for more parameters.
85 perf record -e some_event/@cfg1,@cfg2=config/ ...
92 - a hardware breakpoint event in the form of '\mem:addr[/len][:access]'
97 If you want to profile read-write accesses in 0x1000, just set
102 - a BPF source file (ending in .c) or a precompiled object file (ending
109 '--clang-opt' command line option, e.g.:
111 perf record --clang-opt "-DLINUX_VERSION_CODE=0x50000" \
112 -e tests/bpf-script-example.c
114 Note: '--clang-opt' must be placed before '--event/-e'.
116 - a group of events surrounded by a pair of brace ("{event1,event2,...}").
118 prevent the shell interpretation. You also need to use --group on
121 --filter=<filter>::
122 Event filter. This option should follow an event selector (-e) which
126 - tracepoint filters
128 In the case of tracepoints, multiple '--filter' options are combined
131 - address filters
134 address filters by specifying a non-zero value in
135 /sys/bus/event_source/devices/<pmu>/nr_addr_filters.
142 - 'filter': defines a region that will be traced.
143 - 'start': defines an address at which tracing will begin.
144 - 'stop': defines an address at which tracing will stop.
145 - 'tracestop': defines a region in which tracing will stop.
171 To see the filter that is passed, use the -v option.
179 --exclude-perf::
181 an event selector (-e) which selects tracepoint event(s). It adds a
183 '--filter' exists, the new filter expression will be combined with
186 -a::
187 --all-cpus::
188 System-wide collection from all CPUs (default if no target is specified).
190 -p::
191 --pid=::
194 -t::
195 --tid=::
198 --inherit.
200 -u::
201 --uid=::
204 -r::
205 --realtime=::
208 --no-buffering::
211 -c::
212 --count=::
215 -o::
216 --output=::
219 -i::
220 --no-inherit::
223 -F::
224 --freq=::
228 See --strict-freq.
230 --strict-freq::
233 -m::
234 --mmap-pages=::
236 specification with appended unit character - B/K/M/G. The
238 Also, by adding a comma, the number of mmap pages for AUX
241 --group::
242 Put all events in a single event group. This precedes the --event
243 option and remains only for backward compatibility. See --event.
245 -g::
246 Enables call-graph (stack chain/backtrace) recording for both
249 --call-graph::
250 Setup and enable call-graph (stack chain/backtrace) recording,
251 implies -g. Default is "fp" (for user space).
259 Valid options are "fp" (frame pointer), "dwarf" (DWARF's CFI -
264 --fomit-frame-pointer, using the "fp" method will produce bogus
276 "--call-graph dwarf,4096".
281 like "--call-graph fp,32".
283 -q::
284 --quiet::
287 -v::
288 --verbose::
291 -s::
292 --stat::
293 Record per-thread event counts. Use it with 'perf report -T' to see
296 -d::
297 --data::
300 --phys-data::
303 --data-page-size::
306 --code-page-size::
309 -T::
310 --timestamp::
311 Record the sample timestamps. Use it with 'perf report -D' to see the
314 -P::
315 --period::
318 --sample-cpu::
321 --sample-identifier::
326 -n::
327 --no-samples::
330 -R::
331 --raw-samples::
334 -C::
335 --cpu::
337 comma-separated list with no space: 0,1. Ranges of CPUs are specified with -: 0-2.
338 In per-thread mode with inheritance mode on (default), samples are captured only when
341 -B::
342 --no-buildid::
349 pathname. You can also set the "record.build-id" config variable to
352 -N::
353 --no-buildid-cache::
356 is sufficient. You can also set the "record.build-id" config variable to
357 'no-cache' to have the same effect.
359 -G name,...::
360 --cgroup name,...::
362 in per-cpu mode. The cgroup filesystem must be mounted. All threads belonging to
366 an empty cgroup (monitor all the time) using, e.g., -G foo,,bar. Cgroups must have
369 use '-e e1 -e e2 -G foo,foo' or just use '-e e1 -e e2 -G foo'.
372 command line can be used: 'perf stat -e cycles -G cgroup_name -a -e cycles'.
374 -b::
375 --branch-any::
377 This is a shortcut for --branch-filter any. See --branch-filter for more infos.
379 -j::
380 --branch-filter::
387 - any: any type of branches
388 - any_call: any function call or system call
389 - any_ret: any function return or system call return
390 - ind_call: any indirect branch
391 - call: direct calls, including far (to/from kernel) calls
392 - u: only when the branch target is at the user level
393 - k: only when the branch target is in the kernel
394 - hv: only when the target is at the hypervisor level
395 - in_tx: only when the target is in a hardware transaction
396 - no_tx: only when the target is not in a hardware transaction
397 - abort_tx: only when the target is a hardware transaction abort
398 - cond: conditional branches
399 - save_type: save branch type during sampling in case binary is not available later
400 For the platforms with Intel Arch LBR support (12th-Gen+ client or
401 4th-Gen Xeon+ server), the save branch type is unconditionally enabled
403 - priv: save privilege state during sampling in case binary is not available later
411 The various filters must be specified as a comma separated list: --branch-filter any_ret,u,k
414 -W::
415 --weight::
420 --namespaces::
423 --all-cgroups::
426 --transaction::
429 --per-thread::
430 Use per-thread mmaps. By default per-cpu mmaps are created. This option
431 overrides that and uses per-thread mmaps. A side-effect of that is that
432 inheritance is automatically disabled. --per-thread is ignored with a warning
433 if combined with -a or -C options.
435 -D::
436 --delay=::
437 After starting the program, wait msecs before measuring (-1: start with events
439 -D 10-20,30-40 means wait 10 msecs, enable for 10 msecs, wait 10 msecs, enable
443 -I::
444 --intr-regs::
449 --intr-regs=\?. To name registers, pass a comma separated list such as
450 --intr-regs=ax,bx. The list of register is architecture dependent.
452 --user-regs::
453 Similar to -I, but capture user registers at sample time. To list the available
454 user registers use --user-regs=\?.
456 --running-time::
459 -k::
460 --clockid::
466 -S::
467 --snapshot::
468 Select AUX area tracing Snapshot Mode. This option is valid only with an
469 AUX area tracing event. Optionally, certain snapshot capturing parameters
478 --aux-sample[=OPTIONS]::
479 Select AUX area sampling. At least one of the events selected by the -e option
480 must be an AUX area event. Samples on other events will be created containing
481 data from the AUX area. Optionally sample size may be specified, otherwise it
484 --proc-map-timeout::
485 When processing pre-existing threads /proc/XXX/mmap, it may take a long time,
489 --switch-events::
493 by the option --no-switch-events.
495 --clang-path=PATH::
499 --clang-opt=OPTIONS::
503 --vmlinux=PATH::
507 --buildid-all::
508 Record build-id of all DSOs regardless whether it's actually hit or not.
510 --buildid-mmap::
511 Record build ids in mmap2 events, disables build id cache (implies --no-buildid).
513 --aio[=n]::
518 --affinity=mode::
520 node - thread affinity mask is set to NUMA node cpu mask of the processed mmap buffer
521 cpu - thread affinity mask is set to cpu of the processed mmap buffer
523 --mmap-flush=number::
532 possibly compressed (-z) and written to the output, perf.data or pipe.
542 -z::
543 --compression-level[=n]::
544 Produce compressed trace using specified level n (default: 1 - fastest compression,
545 22 - smallest trace)
547 --all-kernel::
550 --all-user::
553 --kernel-callchains::
557 --user-callchains::
561 Don't use both --kernel-callchains and --user-callchains at the same time or no
564 --timestamp-filename
567 --timestamp-boundary::
570 --switch-output[=mode]::
573 "signal" - when receiving a SIGUSR2 (default value) or
574 <size> - when reaching the size threshold, size is expected to
575 be a number with appended unit character - B/K/M/G
576 <time> - when reaching the time threshold, size is expected to
577 be a number with appended unit character - s/m/h/d
580 on your configuration - the number and size of your ring
581 buffers (-m). It is generally more precise for higher sizes
588 Implies --timestamp-filename, --no-buildid and --no-buildid-cache.
592 --switch-output --no-no-buildid --no-no-buildid-cache
594 --switch-output-event::
595 Events that will cause the switch of the perf.data file, auto-selecting
596 --switch-output=signal, the results are similar as internally the side band
599 Uses the same syntax as --event, it will just not be recorded, serving only to
600 switch the perf.data file as soon as the --switch-output event is processed by
607 --switch-max-files=N::
609 When rotating perf.data with --switch-output, only keep N files.
611 --dry-run::
612 Parse options then exit. --dry-run can be used to detect errors in cmdline
615 'perf record --dry-run -e' can act as a BPF script compiler if llvm.dump-obj
618 --synth=TYPE::
621 task status for pre-existing threads.
624 choice in this option. For example, --synth=no would have MMAP events for
628 'task' - synthesize FORK and COMM events for each task
629 'mmap' - synthesize MMAP events for each process (implies 'task')
630 'cgroup' - synthesize CGROUP events for each cgroup
631 'all' - synthesize all events (default)
632 'no' - do not synthesize any of the above events
634 --tail-synthesize::
635 Instead of collecting non-sample events (for example, fork, comm, mmap) at
637 The collected non-sample events reflects the status of the system when
640 --overwrite::
646 When '--overwrite' and '--switch-output' are used perf records and drops
652 config terms. For example: 'cycles/overwrite/' and 'instructions/no-overwrite/'.
654 Implies --tail-synthesize.
656 --kcore::
659 --max-size=<size>::
661 appended unit character - B/K/M/G
663 --num-thread-synthesize::
668 --pfm-events events::
670 including support for event filters. For example '--pfm-events
673 events cannot be mixed together. The latter must be used with the -e
674 option. The -e option and this one can be mixed and matched. Events
678 --control=fifo:ctl-fifo[,ack-fifo]::
679 --control=fd:ctl-fd[,ack-fd]::
680 ctl-fifo / ack-fifo are opened and used as ctl-fd / ack-fd as follows.
681 Listen on ctl-fd descriptor for command to control measurement.
688 'snapshot' : AUX area tracing snapshot).
692 'evlist [-v|-g|-F] : display all events
693 -F Show just the sample frequency used for each event.
694 -v Show all fields.
695 -g Show event group information.
697 Measurements can be started with events disabled using --delay=-1 option. Optionally
698 send control command completion ('ack\n') to ack-fd descriptor to synchronize with the
707 test -p ${ctl_fifo} && unlink ${ctl_fifo}
712 test -p ${ctl_ack_fifo} && unlink ${ctl_ack_fifo}
716 perf record -D -1 -e cpu-cycles -a \
717 --control fd:${ctl_fd},${ctl_fd_ack} \
718 -- sleep 30 &
721 sleep 5 && echo 'enable' >&${ctl_fd} && read -u ${ctl_fd_ack} e1 && echo "enabled(${e1})"
722 sleep 10 && echo 'disable' >&${ctl_fd} && read -u ${ctl_fd_ack} d1 && echo "disabled(${d1})"
724 exec {ctl_fd_ack}>&-
727 exec {ctl_fd}>&-
730 wait -n ${perf_pid}
733 --threads=<spec>::
747 0,2-4/2-4:1,5-7/5-7
750 the first thread monitors CPUs 0 and 2-4 with the affinity mask 2-4,
751 the second monitors CPUs 1 and 5-7 with the affinity mask 5-7.
756 cpu - create new data streaming thread for every monitored cpu
757 core - create new thread to monitor CPUs grouped by a core
758 package - create new thread to monitor CPUs grouped by a package
759 numa - create new threed to monitor CPUs grouped by a NUMA domain
762 order not to spawn multiple per-cpu streaming threads but still avoid LOST
765 filtered through the mask provided by -C option.
767 --debuginfod[=URLs]::
776 --off-cpu::
777 Enable off-cpu profiling with BPF. The BPF program will collect
779 as sample data of a software event named "offcpu-time". The
786 include::intel-hybrid.txt[]
789 --------
790 linkperf:perf-stat[1], linkperf:perf-list[1], linkperf:perf-intel-pt[1]