Commit ce0a6d7
committed
perf pmu: Allow hardcoded terms to be applied to attributes
JIRA: https://issues.redhat.com/browse/RHEL-77935
upstream
========
commit c798f72
Author: Ian Rogers <irogers@google.com>
Date: Tue Oct 1 20:20:05 2024 -0700
description
===========
Hard coded terms like "config=10" are skipped by perf_pmu__config
assuming they were already applied to a perf_event_attr by parse
event's config_attr function. When doing a reverse number to name
lookup in perf_pmu__name_from_config, as the hardcoded terms aren't
applied the config value is incorrect leading to misses or false
matches. Fix this by adding a parameter to have perf_pmu__config apply
hardcoded terms too (not just in parse event's config_term_common).
Signed-off-by: Ian Rogers <irogers@google.com>
Acked-by: Namhyung Kim <namhyung@kernel.org>
Link: https://lore.kernel.org/r/20241002032016.333748-3-irogers@google.com
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Signed-off-by: Michael Petlan <mpetlan@redhat.com>1 parent ba4dcce commit ce0a6d7
File tree
5 files changed
+58
-12
lines changed- tools/perf
- arch/x86/util
- tests
- util
5 files changed
+58
-12
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
75 | 75 | | |
76 | 76 | | |
77 | 77 | | |
78 | | - | |
| 78 | + | |
| 79 | + | |
79 | 80 | | |
80 | 81 | | |
81 | 82 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
176 | 176 | | |
177 | 177 | | |
178 | 178 | | |
179 | | - | |
| 179 | + | |
| 180 | + | |
180 | 181 | | |
181 | 182 | | |
182 | 183 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1546 | 1546 | | |
1547 | 1547 | | |
1548 | 1548 | | |
1549 | | - | |
| 1549 | + | |
| 1550 | + | |
| 1551 | + | |
1550 | 1552 | | |
1551 | 1553 | | |
1552 | 1554 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1376 | 1376 | | |
1377 | 1377 | | |
1378 | 1378 | | |
1379 | | - | |
| 1379 | + | |
| 1380 | + | |
1380 | 1381 | | |
1381 | 1382 | | |
1382 | 1383 | | |
| |||
1390 | 1391 | | |
1391 | 1392 | | |
1392 | 1393 | | |
1393 | | - | |
1394 | | - | |
| 1394 | + | |
| 1395 | + | |
| 1396 | + | |
1395 | 1397 | | |
1396 | | - | |
| 1398 | + | |
| 1399 | + | |
| 1400 | + | |
| 1401 | + | |
| 1402 | + | |
| 1403 | + | |
| 1404 | + | |
| 1405 | + | |
| 1406 | + | |
| 1407 | + | |
| 1408 | + | |
| 1409 | + | |
| 1410 | + | |
| 1411 | + | |
| 1412 | + | |
| 1413 | + | |
| 1414 | + | |
| 1415 | + | |
| 1416 | + | |
| 1417 | + | |
| 1418 | + | |
| 1419 | + | |
| 1420 | + | |
| 1421 | + | |
| 1422 | + | |
| 1423 | + | |
| 1424 | + | |
| 1425 | + | |
| 1426 | + | |
| 1427 | + | |
| 1428 | + | |
| 1429 | + | |
| 1430 | + | |
| 1431 | + | |
1397 | 1432 | | |
| 1433 | + | |
1398 | 1434 | | |
1399 | 1435 | | |
1400 | 1436 | | |
| |||
1497 | 1533 | | |
1498 | 1534 | | |
1499 | 1535 | | |
1500 | | - | |
| 1536 | + | |
| 1537 | + | |
1501 | 1538 | | |
1502 | 1539 | | |
1503 | 1540 | | |
1504 | 1541 | | |
1505 | | - | |
| 1542 | + | |
1506 | 1543 | | |
1507 | 1544 | | |
1508 | 1545 | | |
| |||
1516 | 1553 | | |
1517 | 1554 | | |
1518 | 1555 | | |
| 1556 | + | |
1519 | 1557 | | |
1520 | 1558 | | |
1521 | 1559 | | |
| |||
1524 | 1562 | | |
1525 | 1563 | | |
1526 | 1564 | | |
1527 | | - | |
| 1565 | + | |
1528 | 1566 | | |
1529 | 1567 | | |
1530 | 1568 | | |
| |||
2293 | 2331 | | |
2294 | 2332 | | |
2295 | 2333 | | |
2296 | | - | |
| 2334 | + | |
| 2335 | + | |
| 2336 | + | |
2297 | 2337 | | |
2298 | 2338 | | |
2299 | 2339 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
206 | 206 | | |
207 | 207 | | |
208 | 208 | | |
| 209 | + | |
209 | 210 | | |
210 | 211 | | |
211 | 212 | | |
212 | 213 | | |
213 | | - | |
| 214 | + | |
| 215 | + | |
214 | 216 | | |
215 | 217 | | |
216 | 218 | | |
| |||
0 commit comments