/tools/perf/scripts/perl/Perf-Trace-Util/lib/Perf/Trace/ |
D | Core.pm | 39 foreach my $idx (sort {$a <=> $b} keys %trace_flags) { 40 if (!$value && !$idx) { 45 if ($idx && ($value & $idx) == $idx) { 49 $string .= "$trace_flags{$idx}"; 51 $value &= ~$idx; 69 foreach my $idx (sort {$a <=> $b} keys %{$flag_fields{$event_name}{$field_name}{"values"}}) { 70 if (!$value && !$idx) { 71 $string .= "$flag_fields{$event_name}{$field_name}{'values'}{$idx}"; 74 if ($idx && ($value & $idx) == $idx) { 78 $string .= "$flag_fields{$event_name}{$field_name}{'values'}{$idx}"; [all …]
|
/tools/testing/selftests/kvm/lib/ |
D | sparsebit.c | 172 sparsebit_idx_t idx; /* index of least-significant bit in mask */ member 287 root->idx = subtree->idx; in node_copy_subtree() 310 static struct node *node_find(struct sparsebit *s, sparsebit_idx_t idx) in node_find() argument 316 nodep = nodep->idx > idx ? nodep->left : nodep->right) { in node_find() 317 if (idx >= nodep->idx && in node_find() 318 idx <= nodep->idx + MASK_BITS + nodep->num_after - 1) in node_find() 333 static struct node *node_add(struct sparsebit *s, sparsebit_idx_t idx) in node_add() argument 344 nodep->idx = idx & -MASK_BITS; in node_add() 358 if (idx < parentp->idx) { in node_add() 366 assert(idx > parentp->idx + MASK_BITS + parentp->num_after - 1); in node_add() [all …]
|
/tools/perf/scripts/python/Perf-Trace-Util/lib/Perf/Trace/ |
D | Core.py | 35 for idx in sorted(flag_fields[event_name][field_name]['values']): 36 if not value and not idx: 37 string += flag_fields[event_name][field_name]['values'][idx] 39 if idx and (value & idx) == idx: 42 string += flag_fields[event_name][field_name]['values'][idx] 44 value &= ~idx 52 for idx in sorted(symbolic_fields[event_name][field_name]['values']): 53 if not value and not idx: 54 string = symbolic_fields[event_name][field_name]['values'][idx] 56 if (value == idx): [all …]
|
/tools/lib/ |
D | find_bit.c | 88 unsigned long idx; in _find_first_bit() local 90 for (idx = 0; idx * BITS_PER_LONG < size; idx++) { in _find_first_bit() 91 if (addr[idx]) in _find_first_bit() 92 return min(idx * BITS_PER_LONG + __ffs(addr[idx]), size); in _find_first_bit() 105 unsigned long idx; in _find_first_zero_bit() local 107 for (idx = 0; idx * BITS_PER_LONG < size; idx++) { in _find_first_zero_bit() 108 if (addr[idx] != ~0UL) in _find_first_zero_bit() 109 return min(idx * BITS_PER_LONG + ffz(addr[idx]), size); in _find_first_zero_bit()
|
/tools/testing/radix-tree/ |
D | main.c | 17 long idx; in __gang_check() local 22 for (idx = -down; idx < up; idx++) in __gang_check() 23 item_insert(&tree, middle + idx); in __gang_check() 26 for (idx = -down; idx < up; idx++) in __gang_check() 27 item_check_present(&tree, middle + idx); in __gang_check() 126 …ix_tree_root *tree, unsigned long start, unsigned long end, unsigned long *idx, int count, int fro… in check_copied_tags() argument 133 if (idx[i] < start || idx[i] > end) { in check_copied_tags() 134 if (item_tag_get(tree, idx[i], totag)) { in check_copied_tags() 136 end, idx[i], item_tag_get(tree, idx[i], in check_copied_tags() 138 item_tag_get(tree, idx[i], totag)); in check_copied_tags() [all …]
|
/tools/lib/perf/include/perf/ |
D | cpumap.h | 19 LIBPERF_API int perf_cpu_map__cpu(const struct perf_cpu_map *cpus, int idx); 24 #define perf_cpu_map__for_each_cpu(cpu, idx, cpus) \ argument 25 for ((idx) = 0, (cpu) = perf_cpu_map__cpu(cpus, idx); \ 26 (idx) < perf_cpu_map__nr(cpus); \ 27 (idx)++, (cpu) = perf_cpu_map__cpu(cpus, idx))
|
/tools/testing/selftests/rcutorture/formal/srcu-cbmc/src/ |
D | simple_sync_srcu.c | 25 bool try_check_zero(struct srcu_struct *sp, int idx, int trycount); 31 int idx; in synchronize_srcu() local 42 idx = 1 ^ (sp->completed & 1); in synchronize_srcu() 46 assume(try_check_zero(sp, idx, trycount)); in synchronize_srcu() 50 assume(try_check_zero(sp, idx^1, trycount)); in synchronize_srcu()
|
/tools/perf/arch/x86/util/ |
D | iostat.c | 55 static const char *iostat_metric_by_idx(int idx) in iostat_metric_by_idx() argument 57 return *(iostat_metrics + idx % iostat_metrics_count()); in iostat_metric_by_idx() 65 int idx; member 99 int idx; in iio_root_ports_list_free() local 102 for (idx = 0; idx < list->nr_entries; idx++) in iio_root_ports_list_free() 103 free(list->rps[idx]); in iio_root_ports_list_free() 112 int idx; in iio_root_port_find_by_notation() local 116 for (idx = 0; idx < list->nr_entries; idx++) { in iio_root_port_find_by_notation() 117 rp = list->rps[idx]; in iio_root_port_find_by_notation() 131 rp->idx = list->nr_entries++; in iio_root_ports_list_insert() [all …]
|
/tools/testing/selftests/kvm/lib/s390x/ |
D | processor.c | 52 int ri, idx; in virt_pg_map() local 75 idx = (gva >> (64 - 11 * ri)) & 0x7ffu; in virt_pg_map() 76 if (entry[idx] & REGION_ENTRY_INVALID) in virt_pg_map() 77 entry[idx] = virt_alloc_region(vm, ri); in virt_pg_map() 78 entry = addr_gpa2hva(vm, entry[idx] & REGION_ENTRY_ORIGIN); in virt_pg_map() 82 idx = (gva >> 12) & 0x0ffu; /* page index */ in virt_pg_map() 83 if (!(entry[idx] & PAGE_INVALID)) in virt_pg_map() 86 entry[idx] = gpa; in virt_pg_map() 91 int ri, idx; in addr_gva2gpa() local 99 idx = (gva >> (64 - 11 * ri)) & 0x7ffu; in addr_gva2gpa() [all …]
|
/tools/testing/selftests/kvm/x86_64/ |
D | hyperv_features.c | 22 static u64 do_rdmsr(u32 idx) in do_rdmsr() argument 29 : "c"(idx)); in do_rdmsr() 37 static void do_wrmsr(u32 idx, u64 val) in do_wrmsr() argument 46 : : "a"(lo), "c"(idx), "d"(hi)); in do_wrmsr() 91 uint32_t idx; member 107 while (msr->idx) { in guest_msr() 110 do_rdmsr(msr->idx); in guest_msr() 112 do_wrmsr(msr->idx, msr->write_val); in guest_msr() 193 msr->idx = HV_X64_MSR_GUEST_OS_ID; in guest_test_msrs_access() 198 msr->idx = HV_X64_MSR_HYPERCALL; in guest_test_msrs_access() [all …]
|
D | kvm_pv_test.c | 18 static u64 do_rdmsr(u32 idx) in do_rdmsr() argument 25 : "c"(idx)); in do_rdmsr() 33 static void do_wrmsr(u32 idx, u64 val) in do_wrmsr() argument 42 : : "a"(lo), "c"(idx), "d"(hi)); in do_wrmsr() 65 uint32_t idx; member 69 #define TEST_MSR(msr) { .idx = msr, .name = #msr } 93 do_rdmsr(msr->idx); in test_msr() 97 do_wrmsr(msr->idx, 0); in test_msr() 158 pr_info("testing msr: %s (%#x)\n", msr->name, msr->idx); in pr_msr()
|
/tools/vm/ |
D | slabinfo-gnuplot.sh | 219 local idx=0 225 files[$idx]=$p 226 idx=$idx+1 229 t_files[$idx]=$p 230 idx=$idx+1 233 files[$idx]=$p 234 idx=$idx+1
|
/tools/testing/selftests/rcutorture/formal/srcu-cbmc/tests/store_buffering/ |
D | test.c | 14 int idx; in rcu_reader() local 17 idx = srcu_read_lock(&ss); in rcu_reader() 23 srcu_read_unlock(&ss, idx); in rcu_reader() 24 idx = srcu_read_lock(&ss); in rcu_reader() 29 srcu_read_unlock(&ss, idx); in rcu_reader()
|
/tools/testing/selftests/bpf/progs/ |
D | tailcall5.c | 28 int idx = 0; in entry() local 31 idx = 1; in entry() 33 idx = 2; in entry() 35 bpf_tail_call(skb, &jmp_table, idx); in entry()
|
/tools/testing/selftests/kvm/include/ |
D | sparsebit.h | 35 bool sparsebit_is_set(struct sparsebit *sbit, sparsebit_idx_t idx); 37 sparsebit_idx_t idx, sparsebit_num_t num); 38 bool sparsebit_is_clear(struct sparsebit *sbit, sparsebit_idx_t idx); 40 sparsebit_idx_t idx, sparsebit_num_t num); 55 void sparsebit_set(struct sparsebit *sbitp, sparsebit_idx_t idx); 60 void sparsebit_clear(struct sparsebit *sbitp, sparsebit_idx_t idx);
|
/tools/perf/util/ |
D | syscalltbl.c | 122 int syscalltbl__strglobmatch_next(struct syscalltbl *tbl, const char *syscall_glob, int *idx) in syscalltbl__strglobmatch_next() argument 127 for (i = *idx + 1; i < tbl->syscalls.nr_entries; ++i) { in syscalltbl__strglobmatch_next() 129 *idx = i; in syscalltbl__strglobmatch_next() 137 int syscalltbl__strglobmatch_first(struct syscalltbl *tbl, const char *syscall_glob, int *idx) in syscalltbl__strglobmatch_first() argument 139 *idx = -1; in syscalltbl__strglobmatch_first() 140 return syscalltbl__strglobmatch_next(tbl, syscall_glob, idx); in syscalltbl__strglobmatch_first() 171 const char *syscall_glob __maybe_unused, int *idx __maybe_unused) in syscalltbl__strglobmatch_next() 176 int syscalltbl__strglobmatch_first(struct syscalltbl *tbl, const char *syscall_glob, int *idx) in syscalltbl__strglobmatch_first() argument 178 return syscalltbl__strglobmatch_next(tbl, syscall_glob, idx); in syscalltbl__strglobmatch_first()
|
D | mmap.c | 65 int idx __maybe_unused, in auxtrace_mmap_params__set_idx() 77 static int perf_mmap__aio_alloc(struct mmap *map, int idx) in perf_mmap__aio_alloc() argument 79 map->aio.data[idx] = mmap(NULL, mmap__mmap_len(map), PROT_READ|PROT_WRITE, in perf_mmap__aio_alloc() 81 if (map->aio.data[idx] == MAP_FAILED) { in perf_mmap__aio_alloc() 82 map->aio.data[idx] = NULL; in perf_mmap__aio_alloc() 89 static void perf_mmap__aio_free(struct mmap *map, int idx) in perf_mmap__aio_free() argument 91 if (map->aio.data[idx]) { in perf_mmap__aio_free() 92 munmap(map->aio.data[idx], mmap__mmap_len(map)); in perf_mmap__aio_free() 93 map->aio.data[idx] = NULL; in perf_mmap__aio_free() 97 static int perf_mmap__aio_bind(struct mmap *map, int idx, int cpu, int affinity) in perf_mmap__aio_bind() argument [all …]
|
D | parse-events-hybrid.c | 39 static int create_event_hybrid(__u32 config_type, int *idx, in create_event_hybrid() argument 50 evsel = parse_events__add_event_hybrid(list, idx, attr, name, in create_event_hybrid() 86 &parse_state->idx, list, attr, name, in add_hw_hybrid() 96 static int create_raw_event_hybrid(int *idx, struct list_head *list, in create_raw_event_hybrid() argument 104 evsel = parse_events__add_event_hybrid(list, idx, attr, name, in create_raw_event_hybrid() 128 ret = create_raw_event_hybrid(&parse_state->idx, list, attr, in add_raw_hybrid() 161 int parse_events__add_cache_hybrid(struct list_head *list, int *idx, in parse_events__add_cache_hybrid() argument 182 ret = create_event_hybrid(PERF_TYPE_HW_CACHE, idx, list, in parse_events__add_cache_hybrid()
|
D | bpf_counter_cgroup.c | 127 __u32 idx = evsel->core.idx * total_cpus + in bperf_load_program() local 130 err = bpf_map_update_elem(map_fd, &idx, &fd, in bperf_load_program() 224 if (evsel->core.idx) in bperf_cgrp__enable() 235 if (evsel->core.idx) in bperf_cgrp__disable() 252 __u32 idx; in bperf_cgrp__read() local 254 if (evsel->core.idx) in bperf_cgrp__read() 266 idx = evsel->core.idx; in bperf_cgrp__read() 267 err = bpf_map_lookup_elem(reading_map_fd, &idx, values); in bperf_cgrp__read() 270 idx, evsel__name(evsel), evsel->cgrp->name); in bperf_cgrp__read() 291 if (evsel->core.idx) in bperf_cgrp__destroy()
|
D | stream.c | 73 int i, idx = 0; in evsel_streams__set_hot_cnode() local 91 idx = i; in evsel_streams__set_hot_cnode() 96 es->streams[idx].cnode = cnode; in evsel_streams__set_hot_cnode() 142 es[i].evsel_idx = pos->core.idx; in evlist__init_callchain_streams() 221 static void print_callchain_pair(struct stream *base_stream, int idx, in print_callchain_pair() argument 232 printf("\nhot chain pair %d:\n", idx); in print_callchain_pair() 267 static void print_stream_callchain(struct stream *stream, int idx, in print_stream_callchain() argument 275 printf("\nhot chain %d:\n", idx); in print_stream_callchain() 306 int i, idx = 0; in callchain_streams_report() local 312 print_callchain_pair(base_stream, ++idx, in callchain_streams_report() [all …]
|
/tools/perf/tests/ |
D | evsel-roundtrip-name.c | 15 int type, op, err = 0, ret = 0, i, idx; in perf_evsel__roundtrip_cache_name_test() local 37 idx = 0; in perf_evsel__roundtrip_cache_name_test() 48 if (evsel->core.idx != idx) in perf_evsel__roundtrip_cache_name_test() 51 ++idx; in perf_evsel__roundtrip_cache_name_test() 88 if (strcmp(evsel__name(evsel), names[evsel->core.idx / distance])) { in __perf_evsel__name_array_test() 90 pr_debug("%s != %s\n", evsel__name(evsel), names[evsel->core.idx / distance]); in __perf_evsel__name_array_test()
|
/tools/bpf/bpftool/ |
D | map_perf_ring.c | 62 int idx; member 75 int idx = ctx->all_cpus ? cpu : ctx->idx; in print_bpf_output() local 84 jsonw_uint(json_wtr, idx); in print_bpf_output() 104 cpu, idx); in print_bpf_output() 132 .idx = -1, in do_event_pipe() 169 ctx.idx = strtoul(*argv, &endptr, 0); in do_event_pipe() 185 if (ctx.idx == -1 || ctx.cpu == -1) { in do_event_pipe() 191 ctx.idx = 0; in do_event_pipe() 199 opts.map_keys = &ctx.idx; in do_event_pipe()
|
/tools/objtool/ |
D | elf.c | 99 unsigned int idx) in find_section_by_index() argument 103 elf_hash_for_each_possible(section, sec, hash, idx) { in find_section_by_index() 104 if (sec->idx == idx) in find_section_by_index() 111 static struct symbol *find_symbol_by_index(struct elf *elf, unsigned int idx) in find_symbol_by_index() argument 115 elf_hash_for_each_possible(symbol, sym, hash, idx) { in find_symbol_by_index() 116 if (sym->idx == idx) in find_symbol_by_index() 263 sec->idx = elf_ndxscn(s); in read_sections() 294 elf_hash_add(section, &sec->hash, sec->idx); in read_sections() 332 elf_hash_add(symbol, &sym->hash, sym->idx); in elf_add_symbol() 381 sym->idx = i; in read_symbols() [all …]
|
/tools/lib/bpf/ |
D | xsk.h | 115 __u32 idx) in xsk_ring_prod__fill_addr() argument 119 return &addrs[idx & fill->mask]; in xsk_ring_prod__fill_addr() 123 xsk_ring_cons__comp_addr(const struct xsk_ring_cons *comp, __u32 idx) in xsk_ring_cons__comp_addr() argument 127 return &addrs[idx & comp->mask]; in xsk_ring_cons__comp_addr() 131 __u32 idx) in xsk_ring_prod__tx_desc() argument 135 return &descs[idx & tx->mask]; in xsk_ring_prod__tx_desc() 139 xsk_ring_cons__rx_desc(const struct xsk_ring_cons *rx, __u32 idx) in xsk_ring_cons__rx_desc() argument 143 return &descs[idx & rx->mask]; in xsk_ring_cons__rx_desc() 183 static inline __u32 xsk_ring_prod__reserve(struct xsk_ring_prod *prod, __u32 nb, __u32 *idx) in xsk_ring_prod__reserve() argument 188 *idx = prod->cached_prod; in xsk_ring_prod__reserve() [all …]
|
/tools/arch/x86/tools/ |
D | gen-insn-attr-x86.awk | 264 idx = "0x" substr($1, 1, index($1,":") - 1) 265 if (idx in table) 266 semantic_error("Redefine " idx " in " tname) 279 table[idx] = "INAT_MAKE_ESCAPE(" escape[ref] ")" 343 lptable1[idx] = add_flags(lptable1[idx],flags) 347 lptable2[idx] = add_flags(lptable2[idx],flags) 351 lptable3[idx] = add_flags(lptable3[idx],flags) 355 table[idx] = add_flags(table[idx],flags) 359 table[idx] = add_flags(table[idx],variant)
|