summaryrefslogtreecommitdiffstats
path: root/vendor/num_cpus
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/num_cpus')
-rw-r--r--vendor/num_cpus/.cargo-checksum.json2
-rw-r--r--vendor/num_cpus/CHANGELOG.md10
-rw-r--r--vendor/num_cpus/Cargo.lock9
-rw-r--r--vendor/num_cpus/Cargo.toml8
-rw-r--r--vendor/num_cpus/README.md3
-rw-r--r--vendor/num_cpus/src/lib.rs28
6 files changed, 46 insertions, 14 deletions
diff --git a/vendor/num_cpus/.cargo-checksum.json b/vendor/num_cpus/.cargo-checksum.json
index 496119d1d..9e045558a 100644
--- a/vendor/num_cpus/.cargo-checksum.json
+++ b/vendor/num_cpus/.cargo-checksum.json
@@ -1 +1 @@
-{"files":{"CHANGELOG.md":"66c7e8dedaa631c5e8d189b896efb691a97529358a56ad78282fbd4cbae3c638","CONTRIBUTING.md":"2390961aab1bba026135338da1216b6cc828dfaeed9357d9c155c55a252d3efb","Cargo.lock":"5a782f53bfc63c9ef7a901472c8ae3599d3f5ecb6f8bb9ce871235b4d9c8bfc1","Cargo.toml":"7a8fa6033b28607f305e144269902dc62c082cf02f76780fcce866810fcf931b","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"0593d22d122d4bfec6407115e3907546312976f75473417aaa4c57ecd2095ae6","README.md":"7760d315d3efd2306affa4c8e4dcdb3a245ae30b3c9cfb9cffed2f1116c86362","ci/cgroups/Dockerfile":"567f00918a6422b363e2c21e57bd47cef9dcc03d0ab109c9605e052f83af7e89","examples/values.rs":"46c833324b7339d359054c4f8e8284259e860df206c552c63b5893ade59c16a6","fixtures/cgroups/cgroups/ceil/cpu.cfs_period_us":"d2ace393dc9388863d75d8de140df516d7ffe4aa7ed2f9a545aa71c9930d6638","fixtures/cgroups/cgroups/ceil/cpu.cfs_quota_us":"7ccd86cde0b22ffc2318f2509726d2a13053f6973e96dc5ca6965a56497e485e","fixtures/cgroups/cgroups/good/cpu.cfs_period_us":"d2ace393dc9388863d75d8de140df516d7ffe4aa7ed2f9a545aa71c9930d6638","fixtures/cgroups/cgroups/good/cpu.cfs_quota_us":"cdc3397c35d915e5fe61f8d2bdedcae00a225d55cc6b090580cde1b71c63463b","fixtures/cgroups/cgroups/zero-period/cpu.cfs_period_us":"74d01a0c051c963d9a9b8ab9dbeab1723f0ad8534ea9fa6a942f358d7fa011b4","fixtures/cgroups/cgroups/zero-period/cpu.cfs_quota_us":"1e6ffd8a95fab538ddd645a767e8cc505722d5c8aaf008969f2ed8ab753ff61e","fixtures/cgroups/proc/cgroups/cgroup":"6812299a4409bfd831ed751fdbbfdd9c5749f69acd7b14c5b0a704271a1f74c6","fixtures/cgroups/proc/cgroups/mountinfo":"3187b0b1c0fa192790abced7d435190e8979059186055688e4c3c2ca013398c6","fixtures/cgroups/proc/cgroups/mountinfo_multi_opt":"d1e397752bc5c4558a3230ad847e89c6885362eab68a53b08dbf219de2e0138a","fixtures/cgroups/proc/cgroups/mountinfo_zero_opt":"91b03b270c76460bc19225aa4b743f893c7d32173e9609ef77e5a04814ab81ff","fixtures/cgroups2/cgroups/ceil/cpu.max":"d6eb496d0851963c9e6a9cf33c0a3ef2f08cbbee2a387c093b30ceca23239226","fixtures/cgroups2/cgroups/good/cpu.max":"2f8bd783be33cf80b6a2a0cf810f81ccf85f988c72c9bb76fa6172b6e4ec2b02","fixtures/cgroups2/cgroups/zero-period/cpu.max":"f42f2771a5f669873e0f45400ff64c481618029fe14a5bcb15d51b426646a9aa","fixtures/cgroups2/proc/cgroups/cgroup":"f8327c16331cc79ecbf875bd7bea6cf1831757589c39e16a149bfb3b6f81f7c8","fixtures/cgroups2/proc/cgroups/cgroup_multi":"96e107b552b1f51a8e96199c12e42dc3807e207d5a1be4a901f49db8e23ed869","fixtures/cgroups2/proc/cgroups/mountinfo":"7ac8cda160d4d80de73195fda560b46ed3826f43ef07fb513308549b32b08b56","src/lib.rs":"81fc237964757a53689db848b1df4fed75bbd6a6e7a9063b6bb008161f8c22af","src/linux.rs":"378ea174d00d560e16fda4b09fb523dda5f4c6f420e46af7d317393a39d88dd1"},"package":"0fac9e2da13b5eb447a6ce3d392f23a29d8694bff781bf03a16cd9ac8697593b"} \ No newline at end of file
+{"files":{"CHANGELOG.md":"383e4f0cbad35bca2de42f4f75a710caede322b576f470c1fe7e850de0a61130","CONTRIBUTING.md":"2390961aab1bba026135338da1216b6cc828dfaeed9357d9c155c55a252d3efb","Cargo.lock":"3d43a8c49d8356b9de781787a561544dbe38aace7b4988fd6cced900ae9e65b2","Cargo.toml":"416683fd268a33c39acedff0a1da11052704b7aa426d8e70fb851ea9d65cf222","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"0593d22d122d4bfec6407115e3907546312976f75473417aaa4c57ecd2095ae6","README.md":"c1412b9d035de412ec90f23a479c0c774ddbff26213a3cef39ca69b9fcd6858a","ci/cgroups/Dockerfile":"567f00918a6422b363e2c21e57bd47cef9dcc03d0ab109c9605e052f83af7e89","examples/values.rs":"46c833324b7339d359054c4f8e8284259e860df206c552c63b5893ade59c16a6","fixtures/cgroups/cgroups/ceil/cpu.cfs_period_us":"d2ace393dc9388863d75d8de140df516d7ffe4aa7ed2f9a545aa71c9930d6638","fixtures/cgroups/cgroups/ceil/cpu.cfs_quota_us":"7ccd86cde0b22ffc2318f2509726d2a13053f6973e96dc5ca6965a56497e485e","fixtures/cgroups/cgroups/good/cpu.cfs_period_us":"d2ace393dc9388863d75d8de140df516d7ffe4aa7ed2f9a545aa71c9930d6638","fixtures/cgroups/cgroups/good/cpu.cfs_quota_us":"cdc3397c35d915e5fe61f8d2bdedcae00a225d55cc6b090580cde1b71c63463b","fixtures/cgroups/cgroups/zero-period/cpu.cfs_period_us":"74d01a0c051c963d9a9b8ab9dbeab1723f0ad8534ea9fa6a942f358d7fa011b4","fixtures/cgroups/cgroups/zero-period/cpu.cfs_quota_us":"1e6ffd8a95fab538ddd645a767e8cc505722d5c8aaf008969f2ed8ab753ff61e","fixtures/cgroups/proc/cgroups/cgroup":"6812299a4409bfd831ed751fdbbfdd9c5749f69acd7b14c5b0a704271a1f74c6","fixtures/cgroups/proc/cgroups/mountinfo":"3187b0b1c0fa192790abced7d435190e8979059186055688e4c3c2ca013398c6","fixtures/cgroups/proc/cgroups/mountinfo_multi_opt":"d1e397752bc5c4558a3230ad847e89c6885362eab68a53b08dbf219de2e0138a","fixtures/cgroups/proc/cgroups/mountinfo_zero_opt":"91b03b270c76460bc19225aa4b743f893c7d32173e9609ef77e5a04814ab81ff","fixtures/cgroups2/cgroups/ceil/cpu.max":"d6eb496d0851963c9e6a9cf33c0a3ef2f08cbbee2a387c093b30ceca23239226","fixtures/cgroups2/cgroups/good/cpu.max":"2f8bd783be33cf80b6a2a0cf810f81ccf85f988c72c9bb76fa6172b6e4ec2b02","fixtures/cgroups2/cgroups/zero-period/cpu.max":"f42f2771a5f669873e0f45400ff64c481618029fe14a5bcb15d51b426646a9aa","fixtures/cgroups2/proc/cgroups/cgroup":"f8327c16331cc79ecbf875bd7bea6cf1831757589c39e16a149bfb3b6f81f7c8","fixtures/cgroups2/proc/cgroups/cgroup_multi":"96e107b552b1f51a8e96199c12e42dc3807e207d5a1be4a901f49db8e23ed869","fixtures/cgroups2/proc/cgroups/mountinfo":"7ac8cda160d4d80de73195fda560b46ed3826f43ef07fb513308549b32b08b56","src/lib.rs":"b75d07d301d2534e405445d8358b95996fcef10552ece0adb7a80a2d5ad25f17","src/linux.rs":"378ea174d00d560e16fda4b09fb523dda5f4c6f420e46af7d317393a39d88dd1"},"package":"4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43"} \ No newline at end of file
diff --git a/vendor/num_cpus/CHANGELOG.md b/vendor/num_cpus/CHANGELOG.md
index 5be725c54..72b3e8838 100644
--- a/vendor/num_cpus/CHANGELOG.md
+++ b/vendor/num_cpus/CHANGELOG.md
@@ -1,3 +1,13 @@
+## v1.16.0
+
+### Features
+
+- add support for AIX operating system
+
+### Fixes
+
+- update hermit-abi to 0.3.0
+
## v1.15.0
### Fixes
diff --git a/vendor/num_cpus/Cargo.lock b/vendor/num_cpus/Cargo.lock
index 1e955390a..29bff55de 100644
--- a/vendor/num_cpus/Cargo.lock
+++ b/vendor/num_cpus/Cargo.lock
@@ -4,12 +4,9 @@ version = 3
[[package]]
name = "hermit-abi"
-version = "0.2.6"
+version = "0.3.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ee512640fe35acbfb4bb779db6f0d80704c2cacfa2e39b601ef3e3f47d1ae4c7"
-dependencies = [
- "libc",
-]
+checksum = "fed44880c466736ef9a5c5b5facefb5ed0785676d0c02d612db14e54f0d84286"
[[package]]
name = "libc"
@@ -19,7 +16,7 @@ checksum = "1a31a0627fdf1f6a39ec0dd577e101440b7db22672c0901fe00a9a6fbb5c24e8"
[[package]]
name = "num_cpus"
-version = "1.15.0"
+version = "1.16.0"
dependencies = [
"hermit-abi",
"libc",
diff --git a/vendor/num_cpus/Cargo.toml b/vendor/num_cpus/Cargo.toml
index 6d62e8626..29adde847 100644
--- a/vendor/num_cpus/Cargo.toml
+++ b/vendor/num_cpus/Cargo.toml
@@ -11,7 +11,7 @@
[package]
name = "num_cpus"
-version = "1.15.0"
+version = "1.16.0"
authors = ["Sean McArthur <sean@seanmonstar.com>"]
description = "Get the number of CPUs on a machine."
documentation = "https://docs.rs/num_cpus"
@@ -25,8 +25,8 @@ categories = ["hardware-support"]
license = "MIT OR Apache-2.0"
repository = "https://github.com/seanmonstar/num_cpus"
-[target."cfg(all(any(target_arch = \"x86_64\", target_arch = \"aarch64\"), target_os = \"hermit\"))".dependencies.hermit-abi]
-version = "0.2.6"
-
[target."cfg(not(windows))".dependencies.libc]
version = "0.2.26"
+
+[target."cfg(target_os = \"hermit\")".dependencies.hermit-abi]
+version = "0.3.0"
diff --git a/vendor/num_cpus/README.md b/vendor/num_cpus/README.md
index 1de7d8ec6..74041b8de 100644
--- a/vendor/num_cpus/README.md
+++ b/vendor/num_cpus/README.md
@@ -1,8 +1,7 @@
# num_cpus
[![crates.io](https://img.shields.io/crates/v/num_cpus.svg)](https://crates.io/crates/num_cpus)
-[![Travis CI Status](https://travis-ci.org/seanmonstar/num_cpus.svg?branch=master)](https://travis-ci.org/seanmonstar/num_cpus)
-[![AppVeyor status](https://ci.appveyor.com/api/projects/status/qn8t6grhko5jwno6?svg=true)](https://ci.appveyor.com/project/seanmonstar/num-cpus)
+[![CI Status](https://github.com/seanmonstar/num_cpus/actions/workflows/ci.yml/badge.svg)](https://github.com/seanmonstar/num_cpus/actions)
- [Documentation](https://docs.rs/num_cpus)
- [CHANGELOG](CHANGELOG.md)
diff --git a/vendor/num_cpus/src/lib.rs b/vendor/num_cpus/src/lib.rs
index 20474af4b..fa1267c66 100644
--- a/vendor/num_cpus/src/lib.rs
+++ b/vendor/num_cpus/src/lib.rs
@@ -110,7 +110,12 @@ pub fn get_physical() -> usize {
}
-#[cfg(not(any(target_os = "linux", target_os = "windows", target_os="macos", target_os="openbsd")))]
+#[cfg(not(any(
+ target_os = "linux",
+ target_os = "windows",
+ target_os = "macos",
+ target_os = "openbsd",
+ target_os = "aix")))]
#[inline]
fn get_num_physical_cpus() -> usize {
// Not implemented, fall back
@@ -327,11 +332,31 @@ fn get_num_physical_cpus() -> usize {
cpus as usize
}
+#[cfg(target_os = "aix")]
+fn get_num_physical_cpus() -> usize {
+ match get_smt_threads_aix() {
+ Some(num) => get_num_cpus() / num,
+ None => get_num_cpus(),
+ }
+}
+
+#[cfg(target_os = "aix")]
+fn get_smt_threads_aix() -> Option<usize> {
+ let smt = unsafe {
+ libc::getsystemcfg(libc::SC_SMT_TC)
+ };
+ if smt == u64::MAX {
+ return None;
+ }
+ Some(smt as usize)
+}
+
#[cfg(any(
target_os = "nacl",
target_os = "macos",
target_os = "ios",
target_os = "android",
+ target_os = "aix",
target_os = "solaris",
target_os = "illumos",
target_os = "fuchsia")
@@ -413,6 +438,7 @@ fn get_num_cpus() -> usize {
target_os = "macos",
target_os = "ios",
target_os = "android",
+ target_os = "aix",
target_os = "solaris",
target_os = "illumos",
target_os = "fuchsia",