[RFC PATCH v2 06/14] perf stat: Extend STD output linter to test metric-only checks

From: Ian Rogers

Date: Mon May 25 2026 - 19:20:40 EST


This patch extends tools/perf/tests/shell/stat+std_output.sh to run
the metric-only check under the --new print flag:

- check_metric_only

This guarantees that standard console metric-only outputs produced by
the decoupled printing callbacks are formally validated by the test linter.

Signed-off-by: Ian Rogers <irogers@xxxxxxxxxx>
Assisted-by: Antigravity:gemini-3.5-flash
---
tools/perf/tests/shell/stat+std_output.sh | 1 +
1 file changed, 1 insertion(+)

diff --git a/tools/perf/tests/shell/stat+std_output.sh b/tools/perf/tests/shell/stat+std_output.sh
index 0d38a1283967..69720b19b908 100755
--- a/tools/perf/tests/shell/stat+std_output.sh
+++ b/tools/perf/tests/shell/stat+std_output.sh
@@ -134,6 +134,7 @@ then
check_per_cache_instance "STD (New API)" "$perf_cmd"
check_per_cluster "STD (New API)" "$perf_cmd"
fi
+check_metric_only "STD (New API)" "$perf_cmd"

cleanup
exit 0
--
2.54.0.794.g4f17f83d09-goog