summaryrefslogtreecommitdiff
path: root/tools/perf/tests/shell/lib/stat_output.sh
diff options
context:
space:
mode:
Diffstat (limited to 'tools/perf/tests/shell/lib/stat_output.sh')
-rw-r--r--tools/perf/tests/shell/lib/stat_output.sh8
1 files changed, 8 insertions, 0 deletions
diff --git a/tools/perf/tests/shell/lib/stat_output.sh b/tools/perf/tests/shell/lib/stat_output.sh
index 9a176ceae4a3..4d4aac547f01 100644
--- a/tools/perf/tests/shell/lib/stat_output.sh
+++ b/tools/perf/tests/shell/lib/stat_output.sh
@@ -148,6 +148,14 @@ check_per_socket()
echo "[Success]"
}
+check_metric_only()
+{
+ echo -n "Checking $1 output: metric only "
+ perf stat --metric-only $2 -e instructions,cycles true
+ commachecker --metric-only
+ echo "[Success]"
+}
+
# The perf stat options for per-socket, per-core, per-die
# and -A ( no_aggr mode ) uses the info fetched from this
# directory: "/sys/devices/system/cpu/cpu*/topology". For