Lines Matching full:other
400 * If 'other' is subset of '*orig', '*orig' keeps itself with no reference count
403 * If '*orig' is subset of 'other', '*orig' reuses 'other' with its reference
408 int perf_cpu_map__merge(struct perf_cpu_map **orig, struct perf_cpu_map *other) in perf_cpu_map__merge() argument
415 if (perf_cpu_map__is_subset(*orig, other)) in perf_cpu_map__merge()
417 if (perf_cpu_map__is_subset(other, *orig)) { in perf_cpu_map__merge()
419 *orig = perf_cpu_map__get(other); in perf_cpu_map__merge()
423 tmp_len = __perf_cpu_map__nr(*orig) + __perf_cpu_map__nr(other); in perf_cpu_map__merge()
430 while (i < __perf_cpu_map__nr(*orig) && j < __perf_cpu_map__nr(other)) { in perf_cpu_map__merge()
431 if (__perf_cpu_map__cpu(*orig, i).cpu <= __perf_cpu_map__cpu(other, j).cpu) { in perf_cpu_map__merge()
432 if (__perf_cpu_map__cpu(*orig, i).cpu == __perf_cpu_map__cpu(other, j).cpu) in perf_cpu_map__merge()
436 tmp_cpus[k++] = __perf_cpu_map__cpu(other, j++); in perf_cpu_map__merge()
442 while (j < __perf_cpu_map__nr(other)) in perf_cpu_map__merge()
443 tmp_cpus[k++] = __perf_cpu_map__cpu(other, j++); in perf_cpu_map__merge()
454 struct perf_cpu_map *other) in perf_cpu_map__intersect() argument
461 if (perf_cpu_map__is_subset(other, orig)) in perf_cpu_map__intersect()
463 if (perf_cpu_map__is_subset(orig, other)) in perf_cpu_map__intersect()
464 return perf_cpu_map__get(other); in perf_cpu_map__intersect()
466 tmp_len = max(__perf_cpu_map__nr(orig), __perf_cpu_map__nr(other)); in perf_cpu_map__intersect()
472 while (i < __perf_cpu_map__nr(orig) && j < __perf_cpu_map__nr(other)) { in perf_cpu_map__intersect()
473 if (__perf_cpu_map__cpu(orig, i).cpu < __perf_cpu_map__cpu(other, j).cpu) in perf_cpu_map__intersect()
475 else if (__perf_cpu_map__cpu(orig, i).cpu > __perf_cpu_map__cpu(other, j).cpu) in perf_cpu_map__intersect()