Crate num_cpus [−] [src]
🔬 This is a nightly-only experimental API. (
this crate is being loaded from the sysroot, and unstable location; did you mean to load this crate from crates.io via
A crate with utilities to determine the number of CPUs available on the current system.
let cpus = num_cpus::get();
Returns the number of available CPUs of the current system.
Returns the number of physical cores of the current system.