Skip to content
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

Deadlock after cargo clean / cargo build with "-Z threads=8" #117775

Closed
mcskware opened this issue Nov 10, 2023 · 4 comments
Closed

Deadlock after cargo clean / cargo build with "-Z threads=8" #117775

mcskware opened this issue Nov 10, 2023 · 4 comments
Labels
C-bug Category: This is a bug. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. WG-compiler-parallel Working group: Parallelizing the compiler

Comments

@mcskware
Copy link

Code

Somewhere in compiling winit, but atm I don't believe it's a problem with winit itself, as the backtrace indicated a deadlock.

Meta

This was after cargo clean / cargo build. Not 100% repro, but attaching the error log generated by the new multi-threaded compiler output.

rustc --version --verbose:

rustc 1.75.0-nightly (0f44eb32f 2023-11-09)
binary: rustc
commit-hash: 0f44eb32f1123ac93ab404d74c295263ce468343
commit-date: 2023-11-09
host: x86_64-pc-windows-msvc
release: 1.75.0-nightly
LLVM version: 17.0.4

Error output

[rustc-ice-2023-11-10T08_37_24-4604.txt](https://github.com/rust-lang/rust/files/13317340/rustc-ice-2023-11-10T08_37_24-4604.txt)
Backtrace

thread '<unnamed>' panicked at compiler\rustc_query_system\src\query\job.rs:543:9:
deadlock detected
stack backtrace:
   0:     0x7ffb6e26dc8f - std::backtrace::Backtrace::force_capture::h6aede448aae39e29
   1:     0x7ffb6e26dbf4 - std::backtrace::Backtrace::force_capture::h6aede448aae39e29
   2:     0x7ffb4fcd58c9 - <tracing_subscriber[de94de57bf501850]::fmt::format::Writer>::write_fmt
   3:     0x7ffb6e286793 - std::panicking::rust_panic_with_hook::hcb987b1ecc5fa88c
   4:     0x7ffb6e2865fb - <std::panicking::begin_panic_handler::StaticStrPayload as core::panic::PanicPayload>::take_box::hbc634cae263d72ff
   5:     0x7ffb6e2837d9 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::he80476ffca7049f1
   6:     0x7ffb6e286344 - rust_begin_unwind
   7:     0x7ffb6e2da847 - core::panicking::panic_fmt::hfa027a7b393787ab
   8:     0x7ffb51110582 - rustc_query_system[33dd738688d1d0a0]::query::job::deadlock
   9:     0x7ffb4fc7a3a3 - rustc_driver_impl[4b7af9b0a721c687]::init_env_logger
  10:     0x7ffb4fcb0d64 - <rustc_data_structures[1d787abe22cd578d]::hashes::Hash128 as core[501979ae5256a6aa]::fmt::Debug>::fmt
  11:     0x7ffb4fc7aad8 - rustc_driver_impl[4b7af9b0a721c687]::init_env_logger
  12:     0x7ffb6e2989fc - std::sys::windows::thread::Thread::new::h33d6c5598eae0caf
  13:     0x7ffbe4b0257d - BaseThreadInitThunk
  14:     0x7ffbe5a2aa78 - RtlUserThreadStart

@mcskware mcskware added C-bug Category: This is a bug. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Nov 10, 2023
@rustbot rustbot added the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Nov 10, 2023
@mcskware
Copy link
Author

@SparrowLii SparrowLii added the WG-compiler-parallel Working group: Parallelizing the compiler label Nov 10, 2023
@saethlin saethlin removed the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Nov 10, 2023
@SparrowLii
Copy link
Member

Could you provide the minimal example causes the ICE?

@SparrowLii
Copy link
Member

Can you reproduce this bug using the latest nightly version to get the new error output?

@SparrowLii
Copy link
Member

I think this has been fixed by #118488

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: This is a bug. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. WG-compiler-parallel Working group: Parallelizing the compiler
Projects
None yet
Development

No branches or pull requests

4 participants