| /tools/testing/selftests/ftrace/test.d/ftrace/ |
| A D | func_traceonoff_triggers.tc | 33 cnt=`cnt_trace` 34 if [ $cnt -ne 0 ]; then 46 cnt=`cnt_trace` 47 if [ $cnt -eq 0 ]; then 76 if [ $cnt -ne 1 ]; then 80 cnt=`cnt_trace` 103 cnt=`cnt_trace` 104 if [ $cnt -ne 0 ]; then 111 if [ $cnt -ne 0 ]; then 123 if [ $cnt -ne 1 ]; then [all …]
|
| A D | fgraph-multi-filter.tc | 70 cnt=`function_count $test` 71 if [ $cnt -gt $orig_cnt ]; then 81 cnt=`function_count $search $vsearch` 82 if [ $cnt -gt $orig_cnt ]; then 127 cnt=`function_count` 128 if [ $instance2_cnt -ne $cnt ]; then 139 cnt=`function_count` 140 if [ $instance1_2_cnt -ne $cnt ]; then 148 cnt=`function_count` 149 if [ $instance1_cnt -ne $cnt ]; then
|
| /tools/testing/selftests/ftrace/test.d/dynevent/ |
| A D | add_remove_fprobe.tc | 33 cnt=`cat enabled_functions | wc -l` 34 if [ $cnt -ne $((ocnt + 1)) ]; then 40 cnt=`cat enabled_functions | wc -l` 41 if [ $cnt -ne $((ocnt + 1)) ]; then 48 cnt=`cat enabled_functions | wc -l` 49 if [ $cnt -ne $((ocnt + 2)) ]; then 60 cnt=`cat enabled_functions | wc -l` 61 if [ $cnt -ne $((ocnt + 2)) ]; then 69 cnt=`cat enabled_functions | wc -l` 70 if [ $cnt -ne $ocnt ]; then [all …]
|
| /tools/testing/selftests/bpf/ |
| A D | jit_disasm_helpers.c | 29 __u32 cnt; member 66 int i, cnt; in disasm_insn() local 70 if (cnt > 0) in disasm_insn() 71 return cnt; in disasm_insn() 97 int i, cnt, err = 0; in disasm_one_func() local 118 if (cnt < 0) { in disasm_one_func() 119 err = cnt; in disasm_one_func() 122 pc += cnt; in disasm_one_func() 140 if (cnt < 0) { in disasm_one_func() 141 err = cnt; in disasm_one_func() [all …]
|
| /tools/testing/selftests/ftrace/test.d/event/ |
| A D | event-no-pid.tc | 79 cnt=`count_pid $mypid` 80 if [ $cnt -ne 0 ]; then 84 cnt=`count_no_pid $mypid` 85 if [ $cnt -eq 0 ]; then 106 cnt=`count_pid $mypid` 107 if [ $cnt -ne 0 ]; then 111 cnt=`count_pid $child` 112 if [ $cnt -ne 0 ]; then 116 cnt=`count_no_pid $mypid` 117 if [ $cnt -eq 0 ]; then
|
| /tools/testing/selftests/bpf/progs/ |
| A D | test_d_path.c | 26 __u32 cnt = cnt_stat; in BPF_PROG() local 34 if (cnt >= MAX_FILES) in BPF_PROG() 36 ret = bpf_d_path(path, paths_stat[cnt], MAX_PATH_LEN); in BPF_PROG() 38 rets_stat[cnt] = ret; in BPF_PROG() 47 __u32 cnt = cnt_close; in BPF_PROG() local 55 if (cnt >= MAX_FILES) in BPF_PROG() 58 paths_close[cnt], MAX_PATH_LEN); in BPF_PROG() 60 rets_close[cnt] = ret; in BPF_PROG()
|
| A D | netcnt_prog.c | 29 union net_cnt *cnt; in bpf_nextcnt() local 33 cnt = bpf_get_local_storage(&netcnt, 0); in bpf_nextcnt() 40 __sync_fetch_and_add(&cnt->packets, in bpf_nextcnt() 44 __sync_fetch_and_add(&cnt->bytes, in bpf_nextcnt() 55 if (cnt->bytes + percpu_cnt->bytes - percpu_cnt->prev_bytes < dt) in bpf_nextcnt() 62 percpu_cnt->prev_packets = cnt->packets; in bpf_nextcnt() 63 percpu_cnt->prev_bytes = cnt->bytes; in bpf_nextcnt()
|
| A D | get_func_args_test.c | 13 __u64 cnt = bpf_get_func_arg_cnt(ctx); in BPF_PROG() local 17 test1_result = cnt == 1; in BPF_PROG() 46 __u64 cnt = bpf_get_func_arg_cnt(ctx); in BPF_PROG() local 50 test2_result = cnt == 2; in BPF_PROG() 73 __u64 cnt = bpf_get_func_arg_cnt(ctx); in BPF_PROG() local 77 test3_result = cnt == 2; in BPF_PROG() 102 __u64 cnt = bpf_get_func_arg_cnt(ctx); in BPF_PROG() local 106 test4_result = cnt == 2; in BPF_PROG()
|
| A D | test_spin_lock.c | 9 volatile int cnt; member 23 volatile int cnt; member 71 if (val->cnt) in bpf_spin_lock_test() 72 val->cnt--; in bpf_spin_lock_test() 74 val->cnt++; in bpf_spin_lock_test() 75 if (val->cnt != 0 && val->cnt != 1) in bpf_spin_lock_test() 98 cls->cnt++; in bpf_spin_lock_test()
|
| A D | iters_num.c | 185 int cnt = 0, *v; in num_succ_elem_cnt() local 189 cnt++; in num_succ_elem_cnt() 193 res_succ_elem_cnt = cnt; in num_succ_elem_cnt() 205 int cnt = 0, *v, i; in num_overfetched_elem_cnt() local 211 cnt++; in num_overfetched_elem_cnt() 215 res_overfetched_elem_cnt = cnt; in num_overfetched_elem_cnt() 227 int cnt = 0, *v, i; in num_fail_elem_cnt() local 233 cnt++; in num_fail_elem_cnt() 237 res_fail_elem_cnt = 20 + cnt; in num_fail_elem_cnt()
|
| /tools/perf/arch/x86/util/ |
| A D | machine.c | 18 int cnt; member 28 if (mi->cnt >= mi->max_cnt) { in add_extra_kernel_map() 40 mi->maps[mi->cnt].start = start; in add_extra_kernel_map() 41 mi->maps[mi->cnt].end = end; in add_extra_kernel_map() 42 mi->maps[mi->cnt].pgoff = pgoff; in add_extra_kernel_map() 43 strlcpy(mi->maps[mi->cnt].name, name, KMAP_NAME_LEN); in add_extra_kernel_map() 45 mi->cnt += 1; in add_extra_kernel_map() 73 struct extra_kernel_map_info mi = { .cnt = 0, }; in machine__create_extra_kernel_maps() 90 for (i = 0; i < mi.cnt; i++) { in machine__create_extra_kernel_maps() 99 machine->trampolines_mapped = mi.cnt; in machine__create_extra_kernel_maps()
|
| /tools/perf/util/ |
| A D | help-unknown-cmd.c | 34 unsigned int i, nr = cmds->cnt + old->cnt; in add_cmd_list() 48 for (i = 0; i < old->cnt; i++) in add_cmd_list() 49 cmds->names[cmds->cnt++] = old->names[i]; in add_cmd_list() 51 old->cnt = 0; in add_cmd_list() 70 qsort(main_cmds->names, main_cmds->cnt, in help_unknown_cmd() 74 if (main_cmds->cnt) { in help_unknown_cmd() 76 for (i = 0; i < main_cmds->cnt; ++i) { in help_unknown_cmd() 84 qsort(main_cmds->names, main_cmds->cnt, in help_unknown_cmd() 89 while (n < main_cmds->cnt && best_similarity == main_cmds->names[n]->len) in help_unknown_cmd() 112 if (main_cmds->cnt && best_similarity < 6) { in help_unknown_cmd()
|
| A D | thread-stack.c | 90 size_t cnt; member 247 ts->cnt = 0; in thread_stack__push() 272 ts->cnt = i; in thread_stack__pop() 284 ts->cnt = i; in thread_stack__pop_trace_end() 292 if (!ts->cnt) in thread_stack__in_kernel() 344 ts->cnt = 0; in __thread_stack__flush() 356 ts->cnt = 0; in __thread_stack__flush() 820 if (!ts->cnt) in thread_stack__pop_cp() 939 if (ts->cnt) in thread_stack__no_call_return() 1004 if (!ts->cnt) in thread_stack__trace_begin() [all …]
|
| /tools/lib/subcmd/ |
| A D | help.c | 28 cmds->names[cmds->cnt++] = ent; in add_cmdname() 35 for (i = 0; i < cmds->cnt; ++i) in clean_cmdnames() 38 cmds->cnt = 0; in clean_cmdnames() 53 if (!cmds->cnt) in uniq() 68 cmds->cnt = j; in uniq() 79 while (ci < cmds->cnt && ei < excludes->cnt) { in exclude_cmds() 98 while (ci < cmds->cnt) { in exclude_cmds() 105 cmds->cnt = cj; in exclude_cmds() 152 if (n >= cmds->cnt) in pretty_print_string_list() 267 if (main_cmds->cnt) { in list_commands() [all …]
|
| /tools/testing/selftests/bpf/map_tests/ |
| A D | sk_storage_map.c | 163 int cnt; in insert_close_thread() member 280 int cnt; in update_thread() member 459 int cnt; in test_sk_storage_map_basic() member 486 CHECK(err || lookup_value.lock || lookup_value.cnt != value.cnt, in test_sk_storage_map_basic() 492 value.cnt += 1; in test_sk_storage_map_basic() 500 CHECK(err || lookup_value.lock || lookup_value.cnt != value.cnt, in test_sk_storage_map_basic() 506 value.cnt += 1; in test_sk_storage_map_basic() 513 CHECK(err || lookup_value.lock || lookup_value.cnt != value.cnt, in test_sk_storage_map_basic() 519 value.cnt += 1; in test_sk_storage_map_basic() 529 value.cnt -= 1; in test_sk_storage_map_basic() [all …]
|
| /tools/testing/selftests/bpf/prog_tests/ |
| A D | arena_list.c | 30 static void test_arena_list_add_del(int cnt) in test_arena_list_add_del() argument 34 int expected_sum = (u64)cnt * (cnt - 1) / 2; in test_arena_list_add_del() 41 skel->bss->cnt = cnt; in test_arena_list_add_del() 53 ASSERT_EQ(skel->arena->test_val, cnt + 1, "num of elems"); in test_arena_list_add_del()
|
| A D | ringbuf.c | 34 static void atomic_inc(int *cnt) in atomic_inc() argument 146 int err, cnt, rb_fd; in ringbuf_subtest() local 262 cnt = atomic_xchg(&sample_cnt, 0); in ringbuf_subtest() 263 CHECK(cnt != 2, "cnt", "exp %d samples, got %d\n", 2, cnt); in ringbuf_subtest() 269 cnt = atomic_xchg(&sample_cnt, 0); in ringbuf_subtest() 270 CHECK(cnt != 0, "cnt", "exp %d samples, got %d\n", 0, cnt); in ringbuf_subtest() 286 cnt = atomic_xchg(&sample_cnt, 0); in ringbuf_subtest() 287 CHECK(cnt != 2, "cnt", "exp %d samples, got %d\n", 2, cnt); in ringbuf_subtest() 317 CHECK(cnt != 0, "cnt", "exp %d samples, got %d\n", 0, cnt); in ringbuf_subtest() 334 CHECK(cnt != 0, "cnt", "exp %d samples, got %d\n", 0, cnt); in ringbuf_subtest() [all …]
|
| A D | kprobe_multi_test.c | 300 opts.cnt = 0; in test_attach_api_fails() 315 opts.cnt = INT_MAX; in test_attach_api_fails() 496 size_t cap = 0, cnt = 0; in get_syms() local 565 *cntp = cnt; in get_syms() 581 size_t cnt = 0; in get_addrs() local 615 if (cnt == max_cnt) { in get_addrs() 629 *cntp = cnt; in get_addrs() 671 size_t cnt = 0; in test_kprobe_multi_bench_attach() local 681 opts.cnt = cnt; in test_kprobe_multi_bench_attach() 696 size_t cnt = 0; in test_kprobe_multi_bench_attach_addr() local [all …]
|
| A D | arg_parsing.c | 8 set->cnt = 0; in init_test_filter_set() 16 for (i = 0; i < set->cnt; i++) { in free_test_filter_set() 34 if (!ASSERT_EQ(set.cnt, 1, "test filters count")) in test_parse_test_list() 44 if (!ASSERT_EQ(set.cnt, 2, "count of test filters")) in test_parse_test_list() 58 if (!ASSERT_EQ(set.cnt, 2, "count of test filters")) in test_parse_test_list() 75 if (!ASSERT_EQ(set.cnt, 3, "count of test filters")) in test_parse_test_list() 91 if (!ASSERT_EQ(set.cnt, 1, "count of test filters")) in test_parse_test_list() 103 if (!ASSERT_EQ(set.cnt, 1, "count of test filters")) in test_parse_test_list() 151 ASSERT_EQ(set.cnt, 4, "test count"); in test_parse_test_list_file()
|
| /tools/perf/util/bpf_skel/ |
| A D | bperf_cgroup.bpf.c | 87 int cnt; in get_cgroup_v1_idx() local 100 for (cnt = 0; i < MAX_LEVELS; i++) { in get_cgroup_v1_idx() 112 cgrps[cnt++] = *elem; in get_cgroup_v1_idx() 113 if (cnt == size) in get_cgroup_v1_idx() 117 return cnt; in get_cgroup_v1_idx() 124 int cnt; in get_cgroup_v2_idx() local 126 for (cnt = 0; i < MAX_LEVELS; i++) { in get_cgroup_v2_idx() 137 cgrps[cnt++] = *elem; in get_cgroup_v2_idx() 138 if (cnt == size) in get_cgroup_v2_idx() 142 return cnt; in get_cgroup_v2_idx()
|
| /tools/perf/tests/ |
| A D | dwarf-unwind.c | 58 unsigned long *cnt = (unsigned long *) arg; in unwind_entry() local 75 MAX_STACK - *cnt - 1 : *cnt; in unwind_entry() 77 if (*cnt >= MAX_STACK) { in unwind_entry() 88 (*cnt)++; in unwind_entry() 97 unsigned long cnt = 0; in test_dwarf_unwind__thread() local 106 err = unwind__get_entries(unwind_entry, &cnt, thread, in test_dwarf_unwind__thread() 110 else if (cnt != MAX_STACK) { in test_dwarf_unwind__thread() 112 cnt, MAX_STACK); in test_dwarf_unwind__thread()
|
| A D | subcmd-help.c | 33 TEST_ASSERT_VAL("invalid original size", cmds.cnt == 3); in test__uniq_cmdnames() 36 TEST_ASSERT_VAL("invalid final size", cmds.cnt == 2); in test__uniq_cmdnames() 67 TEST_ASSERT_VAL("invalid original size", cmds1.cnt == 10); in test__exclude_cmdnames() 68 TEST_ASSERT_VAL("invalid original size", cmds2.cnt == 3); in test__exclude_cmdnames() 73 TEST_ASSERT_VAL("invalid excluded size", cmds1.cnt == 7); in test__exclude_cmdnames() 74 TEST_ASSERT_VAL("invalid excluded size", cmds2.cnt == 3); in test__exclude_cmdnames()
|
| /tools/perf/tests/workloads/ |
| A D | brstack.c | 7 static volatile int cnt; variable 19 if ((cnt++) % 3) /* branch (cond) */ in brstack_bench() 33 if ((cnt++) > num_loops) in brstack()
|
| /tools/testing/selftests/ftrace/test.d/00basic/ |
| A D | trace_marker.tc | 36 cnt=$1 38 cnt=$((cnt-2)) 39 printf -- 'X%.0s' $(seq $cnt)
|
| /tools/testing/selftests/signal/ |
| A D | mangle_uc_sigmask.c | 72 static int cnt; variable 82 ++cnt; in handler_usr() 83 if (cnt > 1) in handler_usr() 99 ksft_test_result(cnt == 1, in handler_usr() 152 ksft_test_result(cnt == 2, "handler invoked only twice\n"); in main()
|