/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 | 81 unsigned long idx; in find_first_bit() local 83 for (idx = 0; idx * BITS_PER_LONG < size; idx++) { in find_first_bit() 84 if (addr[idx]) in find_first_bit() 85 return min(idx * BITS_PER_LONG + __ffs(addr[idx]), size); in find_first_bit() 98 unsigned long idx; in find_first_zero_bit() local 100 for (idx = 0; idx * BITS_PER_LONG < size; idx++) { in find_first_zero_bit() 101 if (addr[idx] != ~0UL) in find_first_zero_bit() 102 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 | 18 LIBPERF_API int perf_cpu_map__cpu(const struct perf_cpu_map *cpus, int idx); 23 #define perf_cpu_map__for_each_cpu(cpu, idx, cpus) \ argument 24 for ((idx) = 0, (cpu) = perf_cpu_map__cpu(cpus, idx); \ 25 (idx) < perf_cpu_map__nr(cpus); \ 26 (idx)++, (cpu) = perf_cpu_map__cpu(cpus, idx))
|
/tools/perf/util/arm-spe-decoder/ |
D | arm-spe-decoder.c | 140 int idx; in arm_spe_read_record() local 150 idx = decoder->packet.index; in arm_spe_read_record() 160 ip = arm_spe_calc_ip(idx, payload); in arm_spe_read_record() 161 if (idx == SPE_ADDR_PKT_HDR_INDEX_INS) in arm_spe_read_record() 163 else if (idx == SPE_ADDR_PKT_HDR_INDEX_BRANCH) in arm_spe_read_record() 185 if ((idx == 2 || idx == 4 || idx == 8) && in arm_spe_read_record() 189 if ((idx == 2 || idx == 4 || idx == 8) && in arm_spe_read_record() 193 if ((idx == 2 || idx == 4 || idx == 8) && in arm_spe_read_record()
|
/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/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/kvm/lib/s390x/ |
D | processor.c | 57 int ri, idx; in virt_pg_map() local 80 idx = (gva >> (64 - 11 * ri)) & 0x7ffu; in virt_pg_map() 81 if (entry[idx] & REGION_ENTRY_INVALID) in virt_pg_map() 82 entry[idx] = virt_alloc_region(vm, ri, memslot); in virt_pg_map() 83 entry = addr_gpa2hva(vm, entry[idx] & REGION_ENTRY_ORIGIN); in virt_pg_map() 87 idx = (gva >> 12) & 0x0ffu; /* page index */ in virt_pg_map() 88 if (!(entry[idx] & PAGE_INVALID)) in virt_pg_map() 91 entry[idx] = gpa; in virt_pg_map() 96 int ri, idx; in addr_gva2gpa() local 104 idx = (gva >> (64 - 11 * ri)) & 0x7ffu; in addr_gva2gpa() [all …]
|
/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/lib/bpf/ |
D | xsk.h | 49 __u32 idx) in xsk_ring_prod__fill_addr() argument 53 return &addrs[idx & fill->mask]; in xsk_ring_prod__fill_addr() 57 xsk_ring_cons__comp_addr(const struct xsk_ring_cons *comp, __u32 idx) in xsk_ring_cons__comp_addr() argument 61 return &addrs[idx & comp->mask]; in xsk_ring_cons__comp_addr() 65 __u32 idx) in xsk_ring_prod__tx_desc() argument 69 return &descs[idx & tx->mask]; in xsk_ring_prod__tx_desc() 73 xsk_ring_cons__rx_desc(const struct xsk_ring_cons *rx, __u32 idx) in xsk_ring_cons__rx_desc() argument 77 return &descs[idx & rx->mask]; in xsk_ring_cons__rx_desc() 117 size_t nb, __u32 *idx) in xsk_ring_prod__reserve() argument 122 *idx = prod->cached_prod; in xsk_ring_prod__reserve() [all …]
|
/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/tests/ |
D | evsel-roundtrip-name.c | 13 int type, op, err = 0, ret = 0, i, idx; in perf_evsel__roundtrip_cache_name_test() local 35 idx = 0; in perf_evsel__roundtrip_cache_name_test() 46 if (evsel->idx != idx) in perf_evsel__roundtrip_cache_name_test() 49 ++idx; in perf_evsel__roundtrip_cache_name_test() 85 if (strcmp(evsel__name(evsel), names[evsel->idx])) { in __perf_evsel__name_array_test() 87 pr_debug("%s != %s\n", evsel__name(evsel), names[evsel->idx]); in __perf_evsel__name_array_test()
|
/tools/perf/util/ |
D | syscalltbl.c | 118 int syscalltbl__strglobmatch_next(struct syscalltbl *tbl, const char *syscall_glob, int *idx) in syscalltbl__strglobmatch_next() argument 123 for (i = *idx + 1; i < tbl->syscalls.nr_entries; ++i) { in syscalltbl__strglobmatch_next() 125 *idx = i; in syscalltbl__strglobmatch_next() 133 int syscalltbl__strglobmatch_first(struct syscalltbl *tbl, const char *syscall_glob, int *idx) in syscalltbl__strglobmatch_first() argument 135 *idx = -1; in syscalltbl__strglobmatch_first() 136 return syscalltbl__strglobmatch_next(tbl, syscall_glob, idx); in syscalltbl__strglobmatch_first() 167 const char *syscall_glob __maybe_unused, int *idx __maybe_unused) in syscalltbl__strglobmatch_next() 172 int syscalltbl__strglobmatch_first(struct syscalltbl *tbl, const char *syscall_glob, int *idx) in syscalltbl__strglobmatch_first() argument 174 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 | cpumap.h | 18 int cpu_map__get_socket(struct perf_cpu_map *map, int idx, void *data); 20 int cpu_map__get_die(struct perf_cpu_map *map, int idx, void *data); 22 int cpu_map__get_core(struct perf_cpu_map *map, int idx, void *data); 24 int cpu_map__get_node(struct perf_cpu_map *map, int idx, void *data); 64 int cpu_map__cpu(struct perf_cpu_map *cpus, int idx);
|
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->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/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 | 142 unsigned int idx) in find_section_by_index() argument 146 elf_hash_for_each_possible(elf->section_hash, sec, hash, idx) in find_section_by_index() 147 if (sec->idx == idx) in find_section_by_index() 153 static struct symbol *find_symbol_by_index(struct elf *elf, unsigned int idx) in find_symbol_by_index() argument 157 elf_hash_for_each_possible(elf->symbol_hash, sym, hash, idx) in find_symbol_by_index() 158 if (sym->idx == idx) in find_symbol_by_index() 299 sec->idx = elf_ndxscn(s); in read_sections() 328 elf_hash_add(elf->section_hash, &sec->hash, sec->idx); in read_sections() 364 elf_hash_add(elf->symbol_hash, &sym->hash, sym->idx); in elf_add_symbol() 407 sym->idx = i; in read_symbols() [all …]
|
/tools/testing/selftests/kvm/x86_64/ |
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/perf/trace/beauty/ |
D | x86_arch_prctl.sh | 10 local idx=$1 14 printf "#define x86_arch_prctl_codes_%d_offset %s\n" $idx $first_entry 15 printf "static const char *x86_arch_prctl_codes_%d[] = {\n" $idx
|
/tools/testing/selftests/vm/ |
D | transhuge-stress.c | 117 size_t idx = pfn >> (HPAGE_SHIFT - PAGE_SHIFT); in main() local 120 if (idx >= map_len) { in main() 121 map = realloc(map, idx + 1); in main() 124 memset(map + map_len, 0, idx + 1 - map_len); in main() 125 map_len = idx + 1; in main() 127 if (!map[idx]) in main() 129 map[idx] = 1; in main()
|
/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)
|