1PERF-LIST(1) perf Manual PERF-LIST(1)
2
3
4
6 perf-list - List all symbolic event types
7
9 perf list [hw|sw|cache|tracepoint|pmu|event_glob]
10
12 This command displays the symbolic event types which can be selected in
13 the various perf commands with the -e option.
14
16 Events can optionally have a modifier by appending a colon and one or
17 more modifiers. Modifiers allow the user to restrict the events to be
18 counted. The following modifiers exist:
19
20 u - user-space counting
21 k - kernel counting
22 h - hypervisor counting
23 I - non idle counting
24 G - guest counting (in KVM guests)
25 H - host counting (not in KVM guests)
26 p - precise level
27 S - read sample value (PERF_SAMPLE_READ)
28 D - pin the event to the PMU
29
30 The p modifier can be used for specifying how precise the instruction
31 address should be. The p modifier can be specified multiple times:
32
33 0 - SAMPLE_IP can have arbitrary skid
34 1 - SAMPLE_IP must have constant skid
35 2 - SAMPLE_IP requested to have 0 skid
36 3 - SAMPLE_IP must have 0 skid
37
38 For Intel systems precise event sampling is implemented with PEBS which
39 supports up to precise-level 2.
40
41 On AMD systems it is implemented using IBS (up to precise-level 2). The
42 precise modifier works with event types 0x76 (cpu-cycles, CPU clocks
43 not halted) and 0xC1 (micro-ops retired). Both events map to IBS
44 execution sampling (IBS op) with the IBS Op Counter Control bit
45 (IbsOpCntCtl) set respectively (see AMD64 Architecture Programmer’s
46 Manual Volume 2: System Programming, 13.3 Instruction-Based Sampling).
47 Examples to use IBS:
48
49 perf record -a -e cpu-cycles:p ... # use ibs op counting cycles
50 perf record -a -e r076:p ... # same as -e cpu-cycles:p
51 perf record -a -e r0C1:p ... # use ibs op counting micro-ops
52
54 Even when an event is not available in a symbolic form within perf
55 right now, it can be encoded in a per processor specific way.
56
57 For instance For x86 CPUs NNN represents the raw register encoding with
58 the layout of IA32_PERFEVTSELx MSRs (see [Intel® 64 and IA-32
59 Architectures Software Developer’s Manual Volume 3B: System Programming
60 Guide] Figure 30-1 Layout of IA32_PERFEVTSELx MSRs) or AMD’s
61 PerfEvtSeln (see [AMD64 Architecture Programmer’s Manual Volume 2:
62 System Programming], Page 344, Figure 13-7 Performance Event-Select
63 Register (PerfEvtSeln)).
64
65 Note: Only the following bit fields can be set in x86 counter
66 registers: event, umask, edge, inv, cmask. Esp. guest/host only and
67 OS/user mode flags must be setup using EVENT MODIFIERS.
68
69 Example:
70
71 If the Intel docs for a QM720 Core i7 describe an event as:
72
73 Event Umask Event Mask
74 Num. Value Mnemonic Description Comment
75
76 A8H 01H LSD.UOPS Counts the number of micro-ops Use cmask=1 and
77 delivered by loop stream detector invert to count
78 cycles
79
80 raw encoding of 0x1A8 can be used:
81
82 perf stat -e r1a8 -a sleep 1
83 perf record -e r1a8 ...
84
85 You should refer to the processor specific documentation for getting
86 these details. Some of them are referenced in the SEE ALSO section
87 below.
88
90 Some pmu events listed by perf-list will be displayed with ? in them.
91 For example:
92
93 hv_gpci/dtbp_ptitc,phys_processor_idx=?/
94
95 This means that when provided as an event, a value for ? must also be
96 supplied. For example:
97
98 perf stat -C 0 -e ´hv_gpci/dtbp_ptitc,phys_processor_idx=0x2/´ ...
99
101 Without options all known events will be listed.
102
103 To limit the list use:
104
105 1. hw or hardware to list hardware events such as cache-misses, etc.
106
107 2. sw or software to list software events such as context switches,
108 etc.
109
110 3. cache or hwcache to list hardware cache events such as
111 L1-dcache-loads, etc.
112
113 4. tracepoint to list all tracepoint events, alternatively use
114 subsys_glob:event_glob to filter by tracepoint subsystems such as
115 sched, block, etc.
116
117 5. pmu to print the kernel supplied PMU events.
118
119 6. If none of the above is matched, it will apply the supplied glob to
120 all events, printing the ones that match.
121
122 One or more types can be used at the same time, listing the events for
123 the types specified.
124
125 Support raw format:
126
127 1. --raw-dump, shows the raw-dump of all the events.
128
129 2. --raw-dump [hw|sw|cache|tracepoint|pmu|event_glob], shows the
130 raw-dump of a certain kind of events.
131
133 perf-stat(1), perf-top(1), perf-record(1), Intel® 64 and IA-32
134 Architectures Software Developer’s Manual Volume 3B: System Programming
135 Guide[1], AMD64 Architecture Programmer’s Manual Volume 2: System
136 Programming[2]
137
139 1. Intel® 64 and IA-32 Architectures Software Developer’s Manual
140 Volume 3B: System Programming Guide
141 http://www.intel.com/Assets/PDF/manual/253669.pdf
142
143 2. AMD64 Architecture Programmer’s Manual Volume 2: System Programming
144 http://support.amd.com/us/Processor_TechDocs/24593_APM_v2.pdf
145
146
147
148perf 06/18/2019 PERF-LIST(1)