1LIBPFM(3) Linux Programmer's Manual LIBPFM(3)
2
3
4
6 libpfm_intel_bdw - support for Intel Broadwell core PMU
7
9 #include <perfmon/pfmlib.h>
10
11 PMU name: bdw
12 PMU desc: Intel Broadwell
13
14
16 The library supports the Intel Broadwell core PMU. It should be noted
17 that this PMU model only covers each core's PMU and not the socket
18 level PMU.
19
20 On Broadwell, the number of generic counters depends on the Hyper‐
21 threading (HT) mode. When HT is on, then only 4 generic counters are
22 available. When HT is off, then 8 generic counters are available. The
23 pfm_get_pmu_info() function returns the maximum number of generic coun‐
24 ters in num_cntrs.
25
26
28 The following modifiers are supported on Intel Broadwell processors:
29
30 u Measure at user level which includes privilege levels 1, 2, 3.
31 This corresponds to PFM_PLM3. This is a boolean modifier.
32
33 k Measure at kernel level which includes privilege level 0. This
34 corresponds to PFM_PLM0. This is a boolean modifier.
35
36 i Invert the meaning of the event. The counter will now count cy‐
37 cles in which the event is not occurring. This is a boolean mod‐
38 ifier
39
40 e Enable edge detection, i.e., count only when there is a state
41 transition from no occurrence of the event to at least one oc‐
42 currence. This modifier must be combined with a counter mask
43 modifier (m) with a value greater or equal to one. This is a
44 boolean modifier.
45
46 c Set the counter mask value. The mask acts as a threshold. The
47 counter will count the number of cycles in which the number of
48 occurrences of the event is greater or equal to the threshold.
49 This is an integer modifier with values in the range [0:255].
50
51 t Measure on both threads at the same time assuming hyper-thread‐
52 ing is enabled. This is a boolean modifier.
53
54 ldlat Pass a latency threshold to the MEM_TRANS_RETIRED:LOAD_LATENCY
55 event. This is an integer attribute that must be in the range
56 [1:65535]. It is required for this event. Note that the event
57 must be used with precise sampling (PEBS).
58
59 intx Monitor the event only when executing inside a transactional
60 memory region (in tx). Event does not count otherwise. This is a
61 boolean modifiers. Default value is 0.
62
63 intxcp Do not count occurrences of the event when they are inside an
64 aborted transactional memory region. This is a boolean modifier.
65 Default value is 0.
66
67
69 Intel Broadwell provides two offcore_response events. They are called
70 OFFCORE_RESPONSE_0 and OFFCORE_RESPONSE_1.
71
72 Those events need special treatment in the performance monitoring in‐
73 frastructure because each event uses an extra register to store some
74 settings. Thus, in case multiple offcore_response events are monitored
75 simultaneously, the kernel needs to manage the sharing of that extra
76 register.
77
78 The offcore_response events are exposed as a normal events by the li‐
79 brary. The extra settings are exposed as regular umasks. The library
80 takes care of encoding the events according to the underlying kernel
81 interface.
82
83 On Intel Broadwell, the umasks are divided into three categories: re‐
84 quest, supplier and snoop. The user must provide at least one umask for
85 each category. The categories are shown in the umask descriptions.
86
87 There is also the special response umask called ANY_RESPONSE. When this
88 umask is used then it overrides any supplier and snoop umasks. In other
89 words, users can specify either ANY_RESPONSE OR any combinations of
90 supplier + snoops.
91
92 In case no supplier or snoop is specified, the library defaults to us‐
93 ing ANY_RESPONSE.
94
95 For instance, the following are valid event selections:
96
97 OFFCORE_RESPONSE_0:DMND_DATA_RD:ANY_RESPONSE
98
99 OFFCORE_RESPONSE_0:ANY_REQUEST
100
101 OFFCORE_RESPONSE_0:ANY_RFO:LLC_HITM:SNOOP_ANY
102
103
104 But the following are illegal:
105
106
107 OFFCORE_RESPONSE_0:ANY_RFO:LLC_HITM:ANY_RESPONSE
108
109 OFFCORE_RESPONSE_0:ANY_RFO:LLC_HITM:SNOOP_ANY:ANY_RESPONSE
110
111
113 Stephane Eranian <eranian@gmail.com>
114
115
116
117 October, 2014 LIBPFM(3)