Skip to content

Commit 951efb9

Browse files
captain5050acmel
authored andcommitted
perf test attr: Update no event/metric expectations
Previously hard coded events/metrics were used, update for the use of the TopdownL1 json metric group. Reported-by: Arnaldo Carvalho de Melo <acme@redhat.com> Fixes: 94b1a60 ("perf stat: Add TopdownL1 metric as a default if present") Reviewed-by: James Clark <james.clark@arm.com> Signed-off-by: Ian Rogers <irogers@google.com> Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Tested-by: Kan Liang <kan.liang@linux.intel.com> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Richter <tmricht@linux.ibm.com> Link: https://lore.kernel.org/r/20230517225707.2682235-1-irogers@google.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
1 parent 1b5f159 commit 951efb9

File tree

5 files changed

+249
-174
lines changed

5 files changed

+249
-174
lines changed

tools/perf/tests/attr/base-stat

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ pinned=0
1616
exclusive=0
1717
exclude_user=0
1818
exclude_kernel=0|1
19-
exclude_hv=0
19+
exclude_hv=0|1
2020
exclude_idle=0
2121
mmap=0
2222
comm=0

tools/perf/tests/attr/test-stat-default

Lines changed: 49 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@ fd=6
4040
type=0
4141
config=7
4242
optional=1
43-
4443
# PERF_TYPE_HARDWARE / PERF_COUNT_HW_STALLED_CYCLES_BACKEND
4544
[event7:base-stat]
4645
fd=7
@@ -89,79 +88,98 @@ enable_on_exec=0
8988
read_format=15
9089
optional=1
9190

92-
# PERF_TYPE_RAW / topdown-bad-spec (0x8100)
91+
# PERF_TYPE_RAW / topdown-fe-bound (0x8200)
9392
[event13:base-stat]
9493
fd=13
9594
group_fd=11
9695
type=4
97-
config=33024
96+
config=33280
9897
disabled=0
9998
enable_on_exec=0
10099
read_format=15
101100
optional=1
102101

103-
# PERF_TYPE_RAW / topdown-fe-bound (0x8200)
102+
# PERF_TYPE_RAW / topdown-be-bound (0x8300)
104103
[event14:base-stat]
105104
fd=14
106105
group_fd=11
107106
type=4
108-
config=33280
107+
config=33536
109108
disabled=0
110109
enable_on_exec=0
111110
read_format=15
112111
optional=1
113112

114-
# PERF_TYPE_RAW / topdown-be-bound (0x8300)
113+
# PERF_TYPE_RAW / topdown-bad-spec (0x8100)
115114
[event15:base-stat]
116115
fd=15
117116
group_fd=11
118117
type=4
119-
config=33536
118+
config=33024
120119
disabled=0
121120
enable_on_exec=0
122121
read_format=15
123122
optional=1
124123

125-
# PERF_TYPE_RAW / topdown-heavy-ops (0x8400)
124+
# PERF_TYPE_RAW / INT_MISC.UOP_DROPPING
126125
[event16:base-stat]
127126
fd=16
128-
group_fd=11
129127
type=4
130-
config=33792
131-
disabled=0
132-
enable_on_exec=0
133-
read_format=15
128+
config=4109
134129
optional=1
135130

136-
# PERF_TYPE_RAW / topdown-br-mispredict (0x8500)
131+
# PERF_TYPE_RAW / cpu/INT_MISC.RECOVERY_CYCLES,cmask=1,edge/
137132
[event17:base-stat]
138133
fd=17
139-
group_fd=11
140134
type=4
141-
config=34048
142-
disabled=0
143-
enable_on_exec=0
144-
read_format=15
135+
config=17039629
145136
optional=1
146137

147-
# PERF_TYPE_RAW / topdown-fetch-lat (0x8600)
138+
# PERF_TYPE_RAW / CPU_CLK_UNHALTED.THREAD
148139
[event18:base-stat]
149140
fd=18
150-
group_fd=11
151141
type=4
152-
config=34304
153-
disabled=0
154-
enable_on_exec=0
155-
read_format=15
142+
config=60
156143
optional=1
157144

158-
# PERF_TYPE_RAW / topdown-mem-bound (0x8700)
145+
# PERF_TYPE_RAW / INT_MISC.RECOVERY_CYCLES_ANY
159146
[event19:base-stat]
160147
fd=19
161-
group_fd=11
162148
type=4
163-
config=34560
164-
disabled=0
165-
enable_on_exec=0
166-
read_format=15
149+
config=2097421
150+
optional=1
151+
152+
# PERF_TYPE_RAW / CPU_CLK_UNHALTED.REF_XCLK
153+
[event20:base-stat]
154+
fd=20
155+
type=4
156+
config=316
157+
optional=1
158+
159+
# PERF_TYPE_RAW / IDQ_UOPS_NOT_DELIVERED.CORE
160+
[event21:base-stat]
161+
fd=21
162+
type=4
163+
config=412
164+
optional=1
165+
166+
# PERF_TYPE_RAW / CPU_CLK_UNHALTED.ONE_THREAD_ACTIVE
167+
[event22:base-stat]
168+
fd=22
169+
type=4
170+
config=572
171+
optional=1
172+
173+
# PERF_TYPE_RAW / UOPS_RETIRED.RETIRE_SLOTS
174+
[event23:base-stat]
175+
fd=23
176+
type=4
177+
config=706
178+
optional=1
179+
180+
# PERF_TYPE_RAW / UOPS_ISSUED.ANY
181+
[event24:base-stat]
182+
fd=24
183+
type=4
184+
config=270
167185
optional=1

tools/perf/tests/attr/test-stat-detailed-1

Lines changed: 57 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -90,89 +90,108 @@ enable_on_exec=0
9090
read_format=15
9191
optional=1
9292

93-
# PERF_TYPE_RAW / topdown-bad-spec (0x8100)
93+
# PERF_TYPE_RAW / topdown-fe-bound (0x8200)
9494
[event13:base-stat]
9595
fd=13
9696
group_fd=11
9797
type=4
98-
config=33024
98+
config=33280
9999
disabled=0
100100
enable_on_exec=0
101101
read_format=15
102102
optional=1
103103

104-
# PERF_TYPE_RAW / topdown-fe-bound (0x8200)
104+
# PERF_TYPE_RAW / topdown-be-bound (0x8300)
105105
[event14:base-stat]
106106
fd=14
107107
group_fd=11
108108
type=4
109-
config=33280
109+
config=33536
110110
disabled=0
111111
enable_on_exec=0
112112
read_format=15
113113
optional=1
114114

115-
# PERF_TYPE_RAW / topdown-be-bound (0x8300)
115+
# PERF_TYPE_RAW / topdown-bad-spec (0x8100)
116116
[event15:base-stat]
117117
fd=15
118118
group_fd=11
119119
type=4
120-
config=33536
120+
config=33024
121121
disabled=0
122122
enable_on_exec=0
123123
read_format=15
124124
optional=1
125125

126-
# PERF_TYPE_RAW / topdown-heavy-ops (0x8400)
126+
# PERF_TYPE_RAW / INT_MISC.UOP_DROPPING
127127
[event16:base-stat]
128128
fd=16
129-
group_fd=11
130129
type=4
131-
config=33792
132-
disabled=0
133-
enable_on_exec=0
134-
read_format=15
130+
config=4109
135131
optional=1
136132

137-
# PERF_TYPE_RAW / topdown-br-mispredict (0x8500)
133+
# PERF_TYPE_RAW / cpu/INT_MISC.RECOVERY_CYCLES,cmask=1,edge/
138134
[event17:base-stat]
139135
fd=17
140-
group_fd=11
141136
type=4
142-
config=34048
143-
disabled=0
144-
enable_on_exec=0
145-
read_format=15
137+
config=17039629
146138
optional=1
147139

148-
# PERF_TYPE_RAW / topdown-fetch-lat (0x8600)
140+
# PERF_TYPE_RAW / CPU_CLK_UNHALTED.THREAD
149141
[event18:base-stat]
150142
fd=18
151-
group_fd=11
152143
type=4
153-
config=34304
154-
disabled=0
155-
enable_on_exec=0
156-
read_format=15
144+
config=60
157145
optional=1
158146

159-
# PERF_TYPE_RAW / topdown-mem-bound (0x8700)
147+
# PERF_TYPE_RAW / INT_MISC.RECOVERY_CYCLES_ANY
160148
[event19:base-stat]
161149
fd=19
162-
group_fd=11
163150
type=4
164-
config=34560
165-
disabled=0
166-
enable_on_exec=0
167-
read_format=15
151+
config=2097421
152+
optional=1
153+
154+
# PERF_TYPE_RAW / CPU_CLK_UNHALTED.REF_XCLK
155+
[event20:base-stat]
156+
fd=20
157+
type=4
158+
config=316
159+
optional=1
160+
161+
# PERF_TYPE_RAW / IDQ_UOPS_NOT_DELIVERED.CORE
162+
[event21:base-stat]
163+
fd=21
164+
type=4
165+
config=412
166+
optional=1
167+
168+
# PERF_TYPE_RAW / CPU_CLK_UNHALTED.ONE_THREAD_ACTIVE
169+
[event22:base-stat]
170+
fd=22
171+
type=4
172+
config=572
173+
optional=1
174+
175+
# PERF_TYPE_RAW / UOPS_RETIRED.RETIRE_SLOTS
176+
[event23:base-stat]
177+
fd=23
178+
type=4
179+
config=706
180+
optional=1
181+
182+
# PERF_TYPE_RAW / UOPS_ISSUED.ANY
183+
[event24:base-stat]
184+
fd=24
185+
type=4
186+
config=270
168187
optional=1
169188

170189
# PERF_TYPE_HW_CACHE /
171190
# PERF_COUNT_HW_CACHE_L1D << 0 |
172191
# (PERF_COUNT_HW_CACHE_OP_READ << 8) |
173192
# (PERF_COUNT_HW_CACHE_RESULT_ACCESS << 16)
174-
[event20:base-stat]
175-
fd=20
193+
[event25:base-stat]
194+
fd=25
176195
type=3
177196
config=0
178197
optional=1
@@ -181,8 +200,8 @@ optional=1
181200
# PERF_COUNT_HW_CACHE_L1D << 0 |
182201
# (PERF_COUNT_HW_CACHE_OP_READ << 8) |
183202
# (PERF_COUNT_HW_CACHE_RESULT_MISS << 16)
184-
[event21:base-stat]
185-
fd=21
203+
[event26:base-stat]
204+
fd=26
186205
type=3
187206
config=65536
188207
optional=1
@@ -191,8 +210,8 @@ optional=1
191210
# PERF_COUNT_HW_CACHE_LL << 0 |
192211
# (PERF_COUNT_HW_CACHE_OP_READ << 8) |
193212
# (PERF_COUNT_HW_CACHE_RESULT_ACCESS << 16)
194-
[event22:base-stat]
195-
fd=22
213+
[event27:base-stat]
214+
fd=27
196215
type=3
197216
config=2
198217
optional=1
@@ -201,8 +220,8 @@ optional=1
201220
# PERF_COUNT_HW_CACHE_LL << 0 |
202221
# (PERF_COUNT_HW_CACHE_OP_READ << 8) |
203222
# (PERF_COUNT_HW_CACHE_RESULT_MISS << 16)
204-
[event23:base-stat]
205-
fd=23
223+
[event28:base-stat]
224+
fd=28
206225
type=3
207226
config=65538
208227
optional=1

0 commit comments

Comments
 (0)