Lines Matching +full:system +full:- +full:wide
2 # perf stat --bpf-counters --for-each-cgroup test
3 # SPDX-License-Identifier: GPL-2.0
5 set -e
8 if [ "$1" = "-v" ]; then
12 # skip if --bpf-counters --for-each-cgroup is not supported
15 if ! perf stat -a --bpf-counters --for-each-cgroup / true > /dev/null 2>&1; then
17 echo "Skipping: --bpf-counters --for-each-cgroup not supported"
18 perf --no-pager stat -a --bpf-counters --for-each-cgroup / true || true
28 if [ -d /sys/fs/cgroup/system.slice ] && [ -d /sys/fs/cgroup/user.slice ]; then
29 test_cgroups="system.slice,user.slice"
34 find_cgroups_self_cgrp=$(grep perf_event /proc/self/cgroup | cut -d: -f3)
35 if [ -z ${find_cgroups_self_cgrp} ]; then
37 find_cgroups_self_cgrp=$(grep ^0: /proc/self/cgroup | cut -d: -f3)
40 if [ -z ${find_cgroups_self_cgrp} ]; then
47 # As cgroup events are cpu-wide, we cannot simply compare the result.
48 # Just check if it runs without failure and has non-zero results.
51 …eck_system_wide_counted_output=$(perf stat -a --bpf-counters --for-each-cgroup ${test_cgroups} -e …
52 if echo ${check_system_wide_counted_output} | grep -q -F "<not "; then
53 echo "Some system-wide events are not counted"
63 …pu_list_counted_output=$(perf stat -C 0,1 --bpf-counters --for-each-cgroup ${test_cgroups} -e cpu-…
64 if echo ${check_cpu_list_counted_output} | grep -q -F "<not "; then