Lines Matching defs:pcpus
574 static int pyrf_cpu_map__init(struct pyrf_cpu_map *pcpus,
584 pcpus->cpus = perf_cpu_map__new(cpustr);
585 if (pcpus->cpus == NULL)
590 static void pyrf_cpu_map__delete(struct pyrf_cpu_map *pcpus)
592 perf_cpu_map__put(pcpus->cpus);
593 Py_TYPE(pcpus)->tp_free((PyObject*)pcpus);
598 struct pyrf_cpu_map *pcpus = (void *)obj;
600 return pcpus->cpus->nr;
605 struct pyrf_cpu_map *pcpus = (void *)obj;
607 if (i >= pcpus->cpus->nr)
610 return Py_BuildValue("i", pcpus->cpus->map[i]);
833 PyObject *pcpus = NULL, *pthreads = NULL;
838 &pcpus, &pthreads, &group, &inherit))
844 if (pcpus != NULL)
845 cpus = ((struct pyrf_cpu_map *)pcpus)->cpus;
899 PyObject *pcpus = NULL, *pthreads = NULL;
903 if (!PyArg_ParseTuple(args, "OO", &pcpus, &pthreads))
907 cpus = ((struct pyrf_cpu_map *)pcpus)->cpus;