diff --git a/tools/perf/tests/shell/stat_bpf_counters.sh b/tools/perf/tests/shell/stat_bpf_counters.sh index 85eb689fe202..6b156dd85469 100755 --- a/tools/perf/tests/shell/stat_bpf_counters.sh +++ b/tools/perf/tests/shell/stat_bpf_counters.sh @@ -31,7 +31,15 @@ if ! perf stat --bpf-counters true > /dev/null 2>&1; then fi base_cycles=$(perf stat --no-big-num -e cycles -- perf bench sched messaging -g 1 -l 100 -t 2>&1 | awk '/cycles/ {print $1}') +if [ "$base_cycles" == "&1 | awk '/cycles/ {print $1}') +if [ "$bpf_cycles" == "