Snap for 7325276 from f01cacb86e74d8c83163a8e06ca05c88e142e82e to sc-release Change-Id: I7345d46f954eed55e6d4ae80dae5cb7a085484cd
Count the number of CPUs on the current machine.
Add to Cargo.toml:
[dependencies] num_cpus = "1.0"
In your main.rs or lib.rs:
main.rs
lib.rs
extern crate num_cpus; // count logical cores this process could try to use let num = num_cpus::get();