Lines Matching refs:tmp_cpus
81 static struct perf_cpu_map *cpu_map__trim_new(int nr_cpus, int *tmp_cpus) in cpu_map__trim_new() argument
88 memcpy(cpus->map, tmp_cpus, payload_size); in cpu_map__trim_new()
108 int *tmp_cpus = NULL, *tmp; in perf_cpu_map__read() local
127 tmp = realloc(tmp_cpus, max_entries * sizeof(int)); in perf_cpu_map__read()
130 tmp_cpus = tmp; in perf_cpu_map__read()
134 tmp_cpus[nr_cpus++] = prev; in perf_cpu_map__read()
138 tmp = realloc(tmp_cpus, max_entries * sizeof(int)); in perf_cpu_map__read()
141 tmp_cpus = tmp; in perf_cpu_map__read()
144 tmp_cpus[nr_cpus++] = cpu; in perf_cpu_map__read()
154 cpus = cpu_map__trim_new(nr_cpus, tmp_cpus); in perf_cpu_map__read()
158 free(tmp_cpus); in perf_cpu_map__read()
182 int *tmp_cpus = NULL, *tmp; in perf_cpu_map__new() local
223 if (tmp_cpus[i] == (int)start_cpu) in perf_cpu_map__new()
228 tmp = realloc(tmp_cpus, max_entries * sizeof(int)); in perf_cpu_map__new()
231 tmp_cpus = tmp; in perf_cpu_map__new()
233 tmp_cpus[nr_cpus++] = (int)start_cpu; in perf_cpu_map__new()
242 cpus = cpu_map__trim_new(nr_cpus, tmp_cpus); in perf_cpu_map__new()
248 free(tmp_cpus); in perf_cpu_map__new()
300 int *tmp_cpus; in perf_cpu_map__merge() local
318 tmp_cpus = malloc(tmp_len * sizeof(int)); in perf_cpu_map__merge()
319 if (!tmp_cpus) in perf_cpu_map__merge()
328 tmp_cpus[k++] = orig->map[i++]; in perf_cpu_map__merge()
330 tmp_cpus[k++] = other->map[j++]; in perf_cpu_map__merge()
334 tmp_cpus[k++] = orig->map[i++]; in perf_cpu_map__merge()
337 tmp_cpus[k++] = other->map[j++]; in perf_cpu_map__merge()
340 merged = cpu_map__trim_new(k, tmp_cpus); in perf_cpu_map__merge()
341 free(tmp_cpus); in perf_cpu_map__merge()