| /linux/tools/perf/util/ |
| H A D | counts.c | 12 struct perf_counts *counts = zalloc(sizeof(*counts)); in perf_counts__new() local 14 if (counts) { in perf_counts__new() 19 free(counts); in perf_counts__new() 23 counts->values = values; in perf_counts__new() 27 xyarray__delete(counts->values); in perf_counts__new() 28 free(counts); in perf_counts__new() 32 counts->loaded = values; in perf_counts__new() 35 return counts; in perf_counts__new() 38 void perf_counts__delete(struct perf_counts *counts) in perf_counts__delete() argument 40 if (counts) { in perf_counts__delete() [all …]
|
| H A D | counts.h | 20 perf_counts(struct perf_counts *counts, int cpu_map_idx, int thread) in perf_counts() argument 22 return xyarray__entry(counts->values, cpu_map_idx, thread); in perf_counts() 26 perf_counts__is_loaded(struct perf_counts *counts, int cpu_map_idx, int thread) in perf_counts__is_loaded() argument 28 return *((bool *) xyarray__entry(counts->loaded, cpu_map_idx, thread)); in perf_counts__is_loaded() 32 perf_counts__set_loaded(struct perf_counts *counts, int cpu_map_idx, int thread, bool loaded) in perf_counts__set_loaded() argument 34 *((bool *) xyarray__entry(counts->loaded, cpu_map_idx, thread)) = loaded; in perf_counts__set_loaded() 38 void perf_counts__delete(struct perf_counts *counts); 39 void perf_counts__reset(struct perf_counts *counts);
|
| H A D | stat.c | 12 #include "counts.h" 162 struct perf_counts *counts; in evsel__alloc_prev_raw_counts() 164 counts = perf_counts__new(cpu_map_nr, nthreads); in evsel__alloc_prev_raw_counts() 165 if (counts) in evsel__alloc_prev_raw_counts() 166 evsel->prev_raw_counts = counts; 168 return counts ? 0 : -ENOMEM; in evsel__free_prev_raw_counts() 259 *perf_counts(evsel->counts, idx, thread) = in evlist__copy_prev_raw_counts() 278 * For GLOBAL aggregation mode, it updates the counts for each run in evlist__copy_res_stats() 281 *ps->aggr[0].counts.values = avg_stats(&ps->res_stats); in evlist__copy_res_stats() 377 if (evsel->err || evsel->counts in evsel__count_has_error() 158 struct perf_counts *counts; evsel__alloc_prev_raw_counts() local 580 struct perf_counts_values counts = { 0, }; evsel__update_percore_stats() local [all...] |
| H A D | bpf_counter.c | 21 #include "counts.h" 294 struct perf_counts_values *counts; in bpf_program_profiler__read() local 304 counts = perf_counts(evsel->counts, idx, 0); in bpf_program_profiler__read() 305 counts->val = 0; in bpf_program_profiler__read() 306 counts->ena = 0; in bpf_program_profiler__read() 307 counts->run = 0; in bpf_program_profiler__read() 327 counts = perf_counts(evsel->counts, i, 0); in bpf_program_profiler__read() 328 counts in bpf_program_profiler__read() 696 struct perf_counts_values *counts; bperf__read() local [all...] |
| H A D | branch.c | 27 st->counts[flags->type]++; in branch_type_count() 118 total += st->counts[i]; in branch_type_stat_display() 152 if (st->counts[i] > 0) in branch_type_stat_display() 156 (double)st->counts[i] / (double)total); in branch_type_stat_display() 180 total += st->counts[i]; in branch_type_str() 198 if (st->counts[i] > 0) in branch_type_str()
|
| H A D | bpf_counter_cgroup.c | 22 #include "counts.h" 293 struct perf_counts_values *counts; in bperf_cgrp__read() 321 counts = perf_counts(evsel->counts, i, 0); in bperf_cgrp__destroy() 322 counts->val = values[cpu.cpu].counter; 323 counts->ena = values[cpu.cpu].enabled; 324 counts->run = values[cpu.cpu].running; 272 struct perf_counts_values *counts; bperf_cgrp__read() local
|
| /linux/tools/lib/perf/tests/ |
| H A D | test-evsel.c | 40 struct perf_counts_values counts = { .val = 0 }; in test_stat_cpu() local 42 perf_evsel__read(evsel, idx, 0, &counts); in test_stat_cpu() 43 __T("failed to read value for evsel", counts.val != 0); in test_stat_cpu() 55 struct perf_counts_values counts = { .val = 0 }; in test_stat_thread() local 75 perf_evsel__read(evsel, 0, 0, &counts); in test_stat_thread() 76 __T("failed to read value for evsel", counts.val != 0); in test_stat_thread() 87 struct perf_counts_values counts = { .val = 0 }; in test_stat_thread_enable() local 108 perf_evsel__read(evsel, 0, 0, &counts); in test_stat_thread_enable() 109 __T("failed to read value for evsel", counts.val == 0); in test_stat_thread_enable() 114 perf_evsel__read(evsel, 0, 0, &counts); in test_stat_thread_enable() [all …]
|
| H A D | test-evlist.c | 78 struct perf_counts_values counts = { .val = 0 }; in test_stat_cpu() local 80 perf_evsel__read(evsel, idx, 0, &counts); in test_stat_cpu() 81 __T("failed to read value for evsel", counts.val != 0); in test_stat_cpu() 94 struct perf_counts_values counts = { .val = 0 }; in test_stat_thread() local 136 perf_evsel__read(evsel, 0, 0, &counts); in test_stat_thread() 137 __T("failed to read value for evsel", counts.val != 0); in test_stat_thread() 149 struct perf_counts_values counts = { .val = 0 }; in test_stat_thread_enable() local 193 perf_evsel__read(evsel, 0, 0, &counts); in test_stat_thread_enable() 194 __T("failed to read value for evsel", counts.val == 0); in test_stat_thread_enable() 200 perf_evsel__read(evsel, 0, 0, &counts); in test_stat_thread_enable() [all …]
|
| /linux/tools/testing/selftests/bpf/prog_tests/ |
| H A D | sock_iter_batch.c | 25 static int insert(__u64 cookie, struct sock_count counts[], int counts_len) in insert() argument 31 if (!counts[i].cookie) { in insert() 33 } else if (counts[i].cookie == cookie) { in insert() 41 counts[insert].cookie = cookie; in insert() 42 counts[insert].count++; in insert() 44 return counts[insert].count; in insert() 47 static int read_n(int iter_fd, int n, struct sock_count counts[], in read_n() argument 58 ASSERT_GE(insert(out.cookie, counts, counts_len), 0, "insert"); in read_n() 77 static bool was_seen(int fd, struct sock_count counts[], int counts_len) in was_seen() argument 83 if (cookie == counts[i].cookie) in was_seen() [all …]
|
| /linux/Documentation/admin-guide/perf/ |
| H A D | fujitsu_uncore_pmu.rst | 32 This event counts MAC cycles at MAC frequency. 34 This event counts the number of read requests to MAC. 36 This event counts the number of read requests including retry to MAC. 38 This event counts the number of responses to read requests to MAC. 40 This event counts the number of read requests including retry with PFTGT 43 This event counts the number of read requests including retry without PFTGT 46 This event counts the number of responses to read requests which hit the 49 This event counts the number of responses to read requests which miss the 52 This event counts outstanding read requests issued by DDR memory controller 55 This event counts the number of write requests to MAC (including zero write, [all …]
|
| /linux/arch/powerpc/platforms/pseries/ |
| H A D | msi.c | 230 struct msi_counts *counts = data; in count_non_bridge_devices() local 240 counts->num_devices++; in count_non_bridge_devices() 247 struct msi_counts *counts = data; in count_spare_msis() local 251 if (dn == counts->requestor) in count_spare_msis() 252 req = counts->request; in count_spare_msis() 266 if (req < counts->quota) in count_spare_msis() 267 counts->spare += counts->quota - req; in count_spare_msis() 268 else if (req > counts->quota) in count_spare_msis() 269 counts->over_quota++; in count_spare_msis() 277 struct msi_counts counts; in msi_quota_for_device() local [all …]
|
| /linux/samples/bpf/ |
| H A D | sampleip_user.c | 82 struct ipcount counts[MAX_IPS]; variable 102 counts[i].ip = next_key; in print_ip_map() 103 counts[i++].count = value; in print_ip_map() 109 qsort(counts, max, sizeof(struct ipcount), count_cmp); in print_ip_map() 111 if (counts[i].ip > _text_addr) { in print_ip_map() 112 sym = ksym_search(counts[i].ip); in print_ip_map() 118 printf("0x%-17llx %-32s %u\n", counts[i].ip, sym->name, in print_ip_map() 119 counts[i].count); in print_ip_map() 121 printf("0x%-17llx %-32s %u\n", counts[i].ip, "(user)", in print_ip_map() 122 counts[i].count); in print_ip_map()
|
| H A D | offwaketime.bpf.c | 32 } counts SEC(".maps"); 94 val = bpf_map_lookup_elem(&counts, &key); in update_counts() 96 bpf_map_update_elem(&counts, &key, &zero, BPF_NOEXIST); in update_counts() 97 val = bpf_map_lookup_elem(&counts, &key); in update_counts()
|
| /linux/drivers/media/v4l2-core/ |
| H A D | v4l2-vp9.c | 1674 const struct v4l2_vp9_frame_symbol_counts *counts, in _adapt_coeff() argument 1683 *counts->eob[i][j][k][l][m][1], in _adapt_coeff() 1684 *counts->eob[i][j][k][l][m][0] - *counts->eob[i][j][k][l][m][1], in _adapt_coeff() 1687 adapt_probs_variant_a_coef(p, *counts->coeff[i][j][k][l][m], uf); in _adapt_coeff() 1694 const struct v4l2_vp9_frame_symbol_counts *counts, in _adapt_coef_probs() argument 1702 _adapt_coeff(i, j, k, probs, counts, uf); in _adapt_coef_probs() 1706 struct v4l2_vp9_frame_symbol_counts *counts, in v4l2_vp9_adapt_coef_probs() argument 1711 _adapt_coef_probs(probs, counts, 112); in v4l2_vp9_adapt_coef_probs() 1714 _adapt_coef_probs(probs, counts, 128); in v4l2_vp9_adapt_coef_probs() 1716 _adapt_coef_probs(probs, counts, 112); in v4l2_vp9_adapt_coef_probs() [all …]
|
| /linux/drivers/md/ |
| H A D | md-bitmap.c | 165 } counts; member 1155 unsigned long chunk = block >> bitmap->counts.chunkshift; in md_bitmap_file_set_bit() 1186 unsigned long chunk = block >> bitmap->counts.chunkshift; in md_bitmap_file_clear_bit() 1216 unsigned long chunk = block >> bitmap->counts.chunkshift; in md_bitmap_file_test_bit() 1327 unsigned long chunks = bitmap->counts.chunks; in md_bitmap_init_from_disk() 1341 int needed = ((sector_t)(i+1) << (bitmap->counts.chunkshift) in md_bitmap_init_from_disk() 1344 (sector_t)i << bitmap->counts.chunkshift, in md_bitmap_init_from_disk() 1424 int needed = ((sector_t)(i+1) << bitmap->counts.chunkshift in md_bitmap_init_from_disk() 1427 (sector_t)i << bitmap->counts.chunkshift, in md_bitmap_init_from_disk() 1514 struct bitmap_counts *counts; in bitmap_daemon_work() local [all …]
|
| /linux/drivers/scsi/ |
| H A D | ch.c | 116 u_int counts[CH_TYPES]; 234 ch->counts[i]) in ch_elem_to_typecode() 322 ch->counts[CHET_MT] = in ch_readconfig() 326 ch->counts[CHET_ST] = in ch_readconfig() 330 ch->counts[CHET_IE] = in ch_readconfig() 334 ch->counts[CHET_DT] = in ch_readconfig() 338 ch->counts[CHET_MT]); in ch_readconfig() 341 ch->counts[CHET_ST]); in ch_readconfig() 344 ch->counts[CHET_IE]); in ch_readconfig() 347 ch->counts[CHET_D in ch_readconfig() 117 u_int counts[CH_TYPES]; global() member [all...] |
| /linux/tools/testing/selftests/bpf/progs/ |
| H A D | test_btf_nokv.c | 21 struct ipv_counts *counts; in test_long_fname_2() local 24 counts = bpf_map_lookup_elem(&btf_map, &key); in test_long_fname_2() 25 if (!counts) in test_long_fname_2() 28 counts->v6++; in test_long_fname_2()
|
| H A D | test_btf_newkv.c | 22 struct ipv_counts *counts; in test_long_fname_2() local 25 counts = bpf_map_lookup_elem(&btf_map, &key); in test_long_fname_2() 26 if (!counts) in test_long_fname_2() 29 counts->v6++; in test_long_fname_2()
|
| /linux/tools/testing/kunit/ |
| H A D | kunit_parser.py | 35 counts : TestCounts - counts of the test statuses and errors of 46 self.counts = TestCounts() 52 f'{self.subtests}, {self.log}, {self.counts}, {self.skip_reason})') 60 self.counts.errors += 1 79 Tracks the counts of statuses of all test cases and any errors within 103 def add_subtest_counts(self, counts: TestCounts) -> None: 105 Adds the counts of another TestCounts object to the current 106 TestCounts object. Used to add the counts of a subtest to the 110 counts [all...] |
| /linux/tools/lib/perf/Documentation/examples/ |
| H A D | counting.c | 24 struct perf_counts_values counts; in main() local 73 perf_evsel__read(evsel, 0, 0, &counts); in main() 75 counts.val, counts.ena, counts.run); in main()
|
| /linux/drivers/hv/ |
| H A D | hv_proc.c | 22 int *counts; in hv_call_deposit_pages() local 43 counts = kzalloc_objs(int, HV_DEPOSIT_MAX); in hv_call_deposit_pages() 44 if (!counts) { in hv_call_deposit_pages() 69 counts[i] = 1 << order; in hv_call_deposit_pages() 70 num_pages -= counts[i]; in hv_call_deposit_pages() 84 for (j = 0; j < counts[i]; ++j, ++page_count) in hv_call_deposit_pages() 102 for (j = 0; j < counts[i]; ++j) in hv_call_deposit_pages() 108 kfree(counts); in hv_call_deposit_pages()
|
| /linux/drivers/gpu/drm/amd/display/dc/link/accessories/ |
| H A D | link_dp_trace.c | 64 link->dp_trace.detect_lt_trace.counts.fail = fail_count; in dp_trace_lt_fail_count_update() 66 link->dp_trace.commit_lt_trace.counts.fail = fail_count; in dp_trace_lt_fail_count_update() 73 link->dp_trace.detect_lt_trace.counts.total++; in dp_trace_lt_total_count_increment() 75 link->dp_trace.commit_lt_trace.counts.total++; in dp_trace_lt_total_count_increment() 137 return &link->dp_trace.detect_lt_trace.counts; in dp_trace_get_lt_counts() 139 return &link->dp_trace.commit_lt_trace.counts; in dp_trace_get_lt_counts()
|
| /linux/fs/xfs/scrub/ |
| H A D | quotacheck.c | 130 struct xfarray *counts, in xqcheck_update_incore_counts() argument 139 error = xfarray_load_sparse(counts, id, &xcdq); in xqcheck_update_incore_counts() 148 error = xfarray_store(counts, id, &xcdq); in xqcheck_update_incore_counts() 324 struct xfarray *counts; in xqcheck_apply_live_dqtrx() local 332 counts = xqc->ucounts; in xqcheck_apply_live_dqtrx() 335 counts = xqc->gcounts; in xqcheck_apply_live_dqtrx() 338 counts = xqc->pcounts; in xqcheck_apply_live_dqtrx() 344 if (xchk_iscan_aborted(&xqc->iscan) || counts == NULL) in xqcheck_apply_live_dqtrx() 362 error = xqcheck_update_incore_counts(xqc, counts, p->q_id, in xqcheck_apply_live_dqtrx() 560 struct xfarray *counts = xqcheck_counters_for(xqc, dqtype); in xqcheck_compare_dquot() local [all …]
|
| /linux/tools/lib/perf/Documentation/ |
| H A D | libperf-counting.txt | 37 * reads and displays event counts 171 Now we need to get the counts from events, following code iterates through the 172 events list and read counts: 177 82 perf_evsel__read(evsel, 0, 0, &counts); 179 84 counts.val, counts.ena, counts.run);
|
| /linux/tools/perf/tests/ |
| H A D | mmap-basic.c | 257 struct perf_counts_values counts = { .val = 0 }; in test_stat_user_read() 330 perf_evsel__read(evsel, 0, 0, &counts); in test_stat_user_read() 331 if (rdpmc_supported && counts.val == 0) { in test_stat_user_read() 343 perf_evsel__read(evsel, 0, 0, &counts); in test_stat_user_read() 344 start = counts.val; in test_stat_user_read() 348 perf_evsel__read(evsel, 0, 0, &counts); in test_stat_user_read() 349 end = counts.val; in test_stat_user_read() 251 struct perf_counts_values counts = { .val = 0 }; test_stat_user_read() local
|