1 .\" Copyright (c) 2012 Davide Italiano <davide@FreeBSD.org>
2 .\" All rights reserved.
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\" notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\" notice, this list of conditions and the following disclaimer in the
11 .\" documentation and/or other materials provided with the distribution.
13 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHORS AND CONTRIBUTORS ``AS IS'' AND
14 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE
17 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
28 .Dt PMC.SANDYBRIDGEUC 3
32 .Nd uncore measurement events for
43 CPUs contain PMCs conforming to version 3 of the
45 performance measurement architecture.
46 These CPUs contain two classes of PMCs:
47 .Bl -tag -width "Li PMC_CLASS_UCP"
49 Fixed-function counters that count only one hardware event per counter.
51 Programmable counters that may be configured to count one of a defined
52 set of hardware events.
55 The number of PMCs available in each class and their widths need to be
56 determined at run time by calling
59 Intel Sandy Bridge PMCs are documented in
61 .%B "Intel(R) 64 and IA-32 Architectures Software Developers Manual"
62 .%T "Volume 3B: System Programming Guide, Part 2"
63 .%N "Order Number: 253669-039US"
65 .%Q "Intel Corporation"
67 .Ss SANDYBRIDGE UNCORE FIXED FUNCTION PMCS
68 These PMCs and their supported events are documented in
70 Not all CPUs in this family implement fixed-function counters.
71 .Ss SANDYBRIDGE UNCORE PROGRAMMABLE PMCS
72 The programmable PMCs support the following capabilities:
73 .Bl -column "PMC_CAP_INTERRUPT" "Support"
74 .It Em Capability Ta Em Support
75 .It PMC_CAP_CASCADE Ta \&No
76 .It PMC_CAP_EDGE Ta Yes
77 .It PMC_CAP_INTERRUPT Ta \&No
78 .It PMC_CAP_INVERT Ta Yes
79 .It PMC_CAP_READ Ta Yes
80 .It PMC_CAP_PRECISE Ta \&No
81 .It PMC_CAP_SYSTEM Ta \&No
82 .It PMC_CAP_TAGGING Ta \&No
83 .It PMC_CAP_THRESHOLD Ta Yes
84 .It PMC_CAP_USER Ta \&No
85 .It PMC_CAP_WRITE Ta Yes
88 Event specifiers for these PMCs support the following common
90 .Bl -tag -width indent
91 .It Li cmask= Ns Ar value
92 Configure the PMC to increment only if the number of configured
93 events measured in a cycle is greater than or equal to
96 Configure the PMC to count the number of de-asserted to asserted
97 transitions of the conditions expressed by the other qualifiers.
98 If specified, the counter will increment only once whenever a
99 condition becomes true, irrespective of the number of clocks during
100 which the condition remains true.
102 Invert the sense of comparison when the
104 qualifier is present, making the counter increment when the number of
105 events per cycle is less than the value specified by the
109 .Ss Event Specifiers (Programmable PMCs)
110 Sandy Bridge programmable PMCs support the following events:
111 .Bl -tag -width indent
112 .It Li CBO_XSNP_RESPONSE.RSPIHITI
113 .Pq Event 22H, Umask 01H
114 Snoop responses received from processor cores to requests initiated by this
116 Must combine with one of the umask values of 20H, 40H, 80H
117 .It Li CBO_XSNP_RESPONSE.RSPIHITFSE
118 .Pq Event 22H, Umask 02H
119 Must combine with one of the umask values of 20H, 40H, 80H
120 .It Li CBO_XSNP_RESPONSE.RSPSHITFSE
121 .Pq Event 22H, Umask 04H
122 Must combine with one of the umask values of 20H, 40H, 80H
123 .It Li CBO_XSNP_RESPONSE.RSPSFWDM
124 .Pq Event 22H, Umask 08H
125 .It Li CBO_XSNP_RESPONSE.RSPIFWDM
126 .Pq Event 22H, Umask 01H
127 .It Li CBO_XSNP_RESPONSE.AND_EXTERNAL
128 .Pq Event 22H, Umask 20H
129 Filter on cross-core snoops resulted in external snoop request.
130 Must combine with at least one of 01H, 02H, 04H, 08H, 10H
131 .It Li CBO_XSNP_RESPONSE.AND_XCORE
132 .Pq Event 22H, Umask 40H
133 Filter on cross-core snoops resulted in core request.
134 Must combine with at least one of 01H, 02H, 04H, 08H, 10H
135 .It Li CBO_XSNP_RESPONSE.AND_XCORE
136 .Pq Event 22H, Umask 80H
137 Filter on cross-core snoops resulted in LLC evictions.
138 Must combine with at least one of 01H, 02H, 04H, 08H, 10H
139 .It Li CBO_CACHE_LOOKUP.M
140 .Pq Event 34H, Umask 01H
141 LLC lookup request that access cache and found line in M-state.
142 Must combine with one of the umask values of 10H, 20H, 40H, 80H
143 .It Li CBO_CACHE_LOOKUP.E
144 .Pq Event 34H, Umask 02H
145 LLC lookup request that access cache and found line in E-state.
146 Must combine with one of the umask values of 10H, 20H, 40H, 80H
147 .It Li CBO_CACHE_LOOKUP.S
148 .Pq Event 34H, Umask 04H
149 LLC lookup request that access cache and found line in S-state.
150 Must combine with one of the umask values of 10H, 20H, 40H, 80H
151 .It Li CBO_CACHE_LOOKUP.I
152 .Pq Event 34H, Umask 08H
153 LLC lookup request that access cache and found line in I-state.
154 Must combine with one of the umask values of 10H, 20H, 40H, 80H
155 .It Li CBO_CACHE_LOOKUP.AND_READ
156 .Pq Event 34H, Umask 10H
157 Filter on processor core initiated cacheable read requests.
158 Must combine with at least one of 01H, 02H, 04H, 08H
159 .It Li CBO_CACHE_LOOKUP_AND_READ2
160 .Pq Event 34H, Umask 20H
161 Filter on processor core initiated cacheable write requests.
162 Must combine with at least one of 01H, 02H, 04H, 08H
163 .It Li CBO_CACHE_LOOKUP.AND_EXTSNP
164 .Pq Event 34H, Umask 40H
165 Filter on external snoop requests.
166 Must combine with at least one of 01H, 02H, 04H, 08H
167 .It Li CBO_CACHE_LOOKUP.AND_ANY
168 .Pq Event 34H, Umask 80H
169 Filter on any IRQ or IPQ initiated requests including uncacheable,
170 noncoherent requests.
171 Must combine with at least one of 01H, 02H, 04H, 08H
172 .It Li IMPH_CBO_TRK_OCCUPANCY.ALL
173 .Pq Event 80H, Umask 01H
174 Counts cycles weighted by the number of core-outgoing valid entries.
175 Valid entries are between allocation to the first of IDIO or DRSO messages.
176 Accounts for coherent and incoherent traffic.
178 .It Li IMPH_CBO_TRK_REQUEST.ALL
179 .Pq Event 81H, Umask 01H
180 Counts the number of core-outgoing entries.
181 Accounts for coherent and incoherent traffic.
182 .It Li IMPH_CBO_TRK_REQUEST.WRITES
183 .Pq Event 81H, Umask 20H
184 Counts the number of allocated write entries, include full, partial, and
186 .It Li IMPH_CBO_TRK_REQUEST.EVICTIONS
187 .Pq Event 81H, Umask 80H
188 Counts the number of evictions allocated.
189 .It Li IMPH_COH_TRK_OCCUPANCY.ALL
190 .Pq Event 83H, Umask 01H
191 Counts cycles weighted by the
192 number of core-outgoing valid entries in the coherent tracker queue.
194 .It Li IMPH_COH_TRK_REQUEST.ALL
195 .Pq Event 84H, Umask 01H
196 Counts the number of core-outgoing entries in the coherent tracker queue.
210 .Xr pmc.sandybridge 3 ,
211 .Xr pmc.sandybridgexeon 3 ,
216 .Xr pmc.westmereuc 3 ,
223 library first appeared in
229 library was written by
230 .An Joseph Koshy Aq Mt jkoshy@FreeBSD.org .
231 The support for the Sandy Bridge
232 microarchitecture was added by
233 .An Davide Italiano Aq Mt davide@FreeBSD.org .