-
Notifications
You must be signed in to change notification settings - Fork 12.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Revert "remove num_cpus dependency" in rustc and update cargo #97911
Conversation
1 commit in 85e457e158db216a2938d51bc3b617a5a7fe6015..4d92f07f34ba7fb7d7f207564942508f46c225d3 2022-06-07 21:57:52 +0000 to 2022-06-09 01:18:36 +0000 - Revert 10427: switch from num_cpus
… rustc_session" This reverts commit 2d854f9.
Updates src/tools/cargo. cc @ehuss |
(rust-highfive has picked a reviewer for you, use r? to override) |
|
@bors r+ rollup=never |
📌 Commit fbc86e0 has been approved by |
I already claimed the issue and wrote that I'll be working on that. |
@dtolnay @Mark-Simulacrum, should this be beta nominated so users don't have to wait for 1.63 for this to reach stable? |
☀️ Test successful - checks-actions |
Finished benchmarking commit (420c970): comparison url. Instruction count
Max RSS (memory usage)Results
CyclesResults
If you disagree with this performance assessment, please file an issue in rust-lang/rustc-perf. @rustbot label: -perf-regression Footnotes |
Revert "remove num_cpus dependency" in rustc and update cargo Fixes rust-lang#97549. This PR reverts rust-lang#94524 and does a Cargo update to pull in rust-lang/cargo#10737. Rust 1.61.0 has a regression in which it misidentifies the number of available CPUs in some environments, leading to enormously increased memory usage and failing builds. In between Rust 1.60 and 1.61 both rustc and cargo replaced some uses of `num_cpus` with `available_parallelism`, which eliminated support for cgroupv1, still apparently in common use. This PR switches both rustc and cargo back to using `num_cpus` in order to support environments where the available parallelism is controlled by cgroupv1. Both can use `available_parallism` again once it handles cgroupv1 (if ever). I have confirmed that the rustc part of this PR fixes the memory usage regression in my non-Cargo environment, and others have confirmed in rust-lang#97549 that the Cargo regression was at fault for the memory usage regression in their environments.
[beta] Beta backports * Remove the unused-#[doc(hidden)] logic from the unused_attributes lint rust-lang#98336 * debuginfo: Fix NatVis for Rc and Arc with unsized pointees. rust-lang#98137 * Revert "remove num_cpus dependency" in rustc and update cargo rust-lang#97911 * Update LLVM submodule rust-lang#97690 * Revert rust-lang#96682. rust-lang#97636 * don't do Sized and other return type checks on RPIT's real type rust-lang#97431 * Temporarily disable submodule archive downloads. rust-lang#98423
…=jyn514 Reland changes replacing num_cpus with available_parallelism Since rust-lang#97925 added cgroupv1 support the problem in rust-lang#97549 which lead to the previous revert should be addressed now. Cargo has reapplied the replacement too rust-lang/cargo#10969 Reverts 1ae4b25 (part of rust-lang#97911) Relands rust-lang#94524
…=jyn514 Reland changes replacing num_cpus with available_parallelism Since rust-lang#97925 added cgroupv1 support the problem in rust-lang#97549 which lead to the previous revert should be addressed now. Cargo has reapplied the replacement too rust-lang/cargo#10969 Reverts 1ae4b25 (part of rust-lang#97911) Relands rust-lang#94524
Fixes #97549. This PR reverts #94524 and does a Cargo update to pull in rust-lang/cargo#10737.
Rust 1.61.0 has a regression in which it misidentifies the number of available CPUs in some environments, leading to enormously increased memory usage and failing builds. In between Rust 1.60 and 1.61 both rustc and cargo replaced some uses of
num_cpus
withavailable_parallelism
, which eliminated support for cgroupv1, still apparently in common use. This PR switches both rustc and cargo back to usingnum_cpus
in order to support environments where the available parallelism is controlled by cgroupv1. Both can useavailable_parallism
again once it handles cgroupv1 (if ever).I have confirmed that the rustc part of this PR fixes the memory usage regression in my non-Cargo environment, and others have confirmed in #97549 that the Cargo regression was at fault for the memory usage regression in their environments.