Lines Matching refs:perf_cpu

20 	RC_STRUCT(perf_cpu_map) *cpus = malloc(sizeof(*cpus) + sizeof(struct perf_cpu) * nr_cpus);  in perf_cpu_map__alloc()
97 const struct perf_cpu *cpu_a = a, *cpu_b = b; in cmp_cpu()
102 static struct perf_cpu __perf_cpu_map__cpu(const struct perf_cpu_map *cpus, int idx) in __perf_cpu_map__cpu()
107 static struct perf_cpu_map *cpu_map__trim_new(int nr_cpus, const struct perf_cpu *tmp_cpus) in cpu_map__trim_new()
109 size_t payload_size = nr_cpus * sizeof(struct perf_cpu); in cpu_map__trim_new()
115 qsort(RC_CHK_ACCESS(cpus)->map, nr_cpus, sizeof(struct perf_cpu), cmp_cpu); in cpu_map__trim_new()
136 struct perf_cpu *tmp_cpus = NULL, *tmp; in perf_cpu_map__read()
155 tmp = realloc(tmp_cpus, max_entries * sizeof(struct perf_cpu)); in perf_cpu_map__read()
166 tmp = realloc(tmp_cpus, max_entries * sizeof(struct perf_cpu)); in perf_cpu_map__read()
210 struct perf_cpu *tmp_cpus = NULL, *tmp; in perf_cpu_map__new()
256 tmp = realloc(tmp_cpus, max_entries * sizeof(struct perf_cpu)); in perf_cpu_map__new()
286 struct perf_cpu perf_cpu_map__cpu(const struct perf_cpu_map *cpus, int idx) in perf_cpu_map__cpu()
288 struct perf_cpu result = { in perf_cpu_map__cpu()
308 int perf_cpu_map__idx(const struct perf_cpu_map *cpus, struct perf_cpu cpu) in perf_cpu_map__idx()
319 struct perf_cpu cpu_at_idx = __perf_cpu_map__cpu(cpus, idx); in perf_cpu_map__idx()
333 bool perf_cpu_map__has(const struct perf_cpu_map *cpus, struct perf_cpu cpu) in perf_cpu_map__has()
364 struct perf_cpu perf_cpu_map__max(const struct perf_cpu_map *map) in perf_cpu_map__max()
366 struct perf_cpu result = { in perf_cpu_map__max()
407 struct perf_cpu *tmp_cpus; in perf_cpu_map__merge()
420 tmp_cpus = malloc(tmp_len * sizeof(struct perf_cpu)); in perf_cpu_map__merge()
451 struct perf_cpu *tmp_cpus; in perf_cpu_map__intersect()
462 tmp_cpus = malloc(tmp_len * sizeof(struct perf_cpu)); in perf_cpu_map__intersect()