Return the number of active CPUs on a Darwin system.
()
| 124 | |
| 125 | |
| 126 | def _num_cpus_darwin(): |
| 127 | """Return the number of active CPUs on a Darwin system.""" |
| 128 | p = subprocess.Popen(['sysctl','-n','hw.ncpu'],stdout=subprocess.PIPE) |
| 129 | return p.stdout.read() |
| 130 | |
| 131 | |
| 132 | def _num_cpus_windows(): |