]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
perf test metrics: Update all metrics for possibly failing default metrics
authorIan Rogers <irogers@google.com>
Tue, 11 Nov 2025 21:22:02 +0000 (13:22 -0800)
committerNamhyung Kim <namhyung@kernel.org>
Wed, 12 Nov 2025 00:48:35 +0000 (16:48 -0800)
Default metrics may use unsupported events and be ignored. These
metrics shouldn't cause metric testing to fail.

Signed-off-by: Ian Rogers <irogers@google.com>
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
tools/perf/tests/shell/stat_all_metrics.sh

index 6fa585a1e34c9ff2e242e20a839c03233e6e0f74..a7edf01b39433668b5b80fa2accb7067f66b9320 100755 (executable)
@@ -25,8 +25,13 @@ for m in $(perf list --raw-dump metrics); do
     # No error result and metric shown.
     continue
   fi
-  if [[ "$result" =~ "Cannot resolve IDs for" ]]
+  if [[ "$result" =~ "Cannot resolve IDs for" || "$result" =~ "No supported events found" ]]
   then
+    if [[ "$m" == @(l1_prefetch_miss_rate|stalled_cycles_per_instruction) ]]
+    then
+      # Default metrics that may use unsupported events.
+      continue
+    fi
     echo "Metric contains missing events"
     echo $result
     err=1 # Fail