Snap for 7357013 from cfce29c65a1c3ced12f398d7ea096bda6529c3de to sc-d1-release

Change-Id: I1b88d4fe3da0cc5a2bd1aad1f5dcd50725187242
tree: 384e51cab6b1186d6bfada666e744f0884b51d82
  1. ci/
  2. examples/
  3. fixtures/
  4. src/
  5. .appveyor.yml
  6. .cargo_vcs_info.json
  7. .gitignore
  8. .travis.yml
  9. Android.bp
  10. Cargo.lock
  11. Cargo.toml
  12. Cargo.toml.orig
  13. cargo2android.json
  14. CHANGELOG.md
  15. CONTRIBUTING.md
  16. LICENSE-APACHE
  17. LICENSE-MIT
  18. METADATA
  19. MODULE_LICENSE_APACHE2
  20. OWNERS
  21. README.md
README.md

num_cpus

crates.io Travis CI Status AppVeyor status

Count the number of CPUs on the current machine.

Usage

Add to Cargo.toml:

[dependencies]
num_cpus = "1.0"

In your main.rs or lib.rs:

extern crate num_cpus;

// count logical cores this process could try to use
let num = num_cpus::get();