Skip to content

internal compiler error #140826

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

Closed
257 opened this issue May 8, 2025 · 10 comments
Closed

internal compiler error #140826

257 opened this issue May 8, 2025 · 10 comments
Labels
C-bug Category: This is a bug. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ S-needs-info Status: The issue lacks details necessary to triage or act on it. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@257
Copy link

257 commented May 8, 2025

Code

<missing, will provide later>

Meta

rustc --version --verbose:

rustc 1.88.0-nightly (fe348cd1a 2025-05-08) (gentoo)
binary: rustc
commit-hash: fe348cd1a8e0fa445b772393147ed865904dcd4d
commit-date: 2025-05-08
host: x86_64-unknown-linux-gnu
release: 1.88.0-nightly
LLVM version: 20.1.4

Error output

error: internal compiler error[E0432]: unresolved import `crate::sys::IoSourceState`
  --> /home/pmn/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/mio-1.0.3/src/io_source.rs:14:5
   |
14 | use crate::sys::IoSourceState;
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^ no `IoSourceState` in `sys`


thread 'rustc' panicked at compiler/rustc_errors/src/lib.rs:1842:17:
aborting due to `-Z treat-err-as-bug=1`

Backtrace

stack backtrace:
   0:     0x7fee2fc77cf3 - <std::sys::backtrace::BacktraceLock::print::DisplayBacktrace as core::fmt::Display>::fmt::h0499c572e39a850b
   1:     0x7fee2c142c93 - core::fmt::write::hc2ceabf6d74db53f
   2:     0x7fee2fc6b893 - <unknown>
   3:     0x7fee2fc77b52 - <unknown>
   4:     0x7fee2fc7ccda - <unknown>
   5:     0x7fee2fc7c85f - std::panicking::default_hook::h2e4d68c6fb3d69c4
   6:     0x7fee2d1b9d24 - <unknown>
   7:     0x7fee2fc7d573 - std::panicking::rust_panic_with_hook::h3f8040aecc5410d8
   8:     0x7fee2fc7d236 - <unknown>
   9:     0x7fee2fc781b9 - <unknown>
  10:     0x7fee2fc7cf0d - __rustc[a0157d8c9fdc7998]::rust_begin_unwind
  11:     0x7fee2beb9f70 - core::panicking::panic_fmt::h37890b4f85ab80d3
  12:     0x7fee2d259b0c - <unknown>
  13:     0x7fee2d25901f - <unknown>
  14:     0x7fee2ddf2482 - <unknown>
  15:     0x7fee2d258842 - <unknown>
  16:     0x7fee2d256ec7 - <rustc_errors[cb99d3d9ee887401]::DiagCtxtHandle>::emit_diagnostic
  17:     0x7fee2d28fd6c - <unknown>
  18:     0x7fee2f1e8ec0 - <unknown>
  19:     0x7fee2f1e62d2 - <unknown>
  20:     0x7fee2f2ec8ce - <unknown>
  21:     0x7fee2dd8f3e7 - rustc_interface[c48d619769ecbdc]::passes::resolver_for_lowering_raw
  22:     0x7fee2ee3e37d - <unknown>
  23:     0x7fee2eed378c - <unknown>
  24:     0x7fee2ed63027 - rustc_query_system[c8e4b506e730a7ce]::query::plumbing::try_execute_query::<rustc_query_impl[e3fedd85d360950d]::DynamicConfig<rustc_query_system[c8e4b506e730a7ce]::query::caches::SingleCache<rustc_middle[4763dae86df1014d]::query::erase::Erased<[u8; 16usize]>>, false, false, false>, rustc_query_impl[e3fedd85d360950d]::plumbing::QueryCtxt, false>
  25:     0x7fee2f02661a - <unknown>
  26:     0x7fee2d130192 - <unknown>
  27:     0x7fee2d170c95 - <unknown>
  28:     0x7fee2d16bec9 - <unknown>
  29:     0x7fee2d15227c - <unknown>
  30:     0x7fee2d19494d - <unknown>
  31:     0x7fee2d138d59 - <unknown>
  32:     0x7fee2d14e85d - <unknown>
  33:     0x7fee2fc80bab - <unknown>
  34:     0x7fee2b64d2e0 - <unknown>
  35:     0x7fee2b6cc78c - <unknown>
  36:                0x0 - <unknown>

rustc-ice-2025-05-08T19_22_00-2312147.txt

@257 257 added 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. C-bug Category: This is a bug. labels May 8, 2025
@rustbot rustbot added the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label May 8, 2025
@matthiaskrgr
Copy link
Member

aborting due to -Z treat-err-as-bug=1

this forces rustc to issue an ICE with stacktrace instead of just an error, is the ice reproducible without -Ztreat-err-as-bug=1 ?

@257
Copy link
Author

257 commented May 8, 2025

yes, reproducible but far too many errors from mio and home. i could dump it here if need be.

@fmease fmease added S-needs-info Status: The issue lacks details necessary to triage or act on it. and removed needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. labels May 8, 2025
@fmease
Copy link
Member

fmease commented May 8, 2025

First and foremost to make this more actionable for us, please simply post the parts of stderr that belong to internal compiler errors / compiler panics including any backtraces. Please do not use -Ztreat-err-as-bug=1 for this! No need to post the rest of the stderr (yet).

@257
Copy link
Author

257 commented May 9, 2025

doesn't rustc-ice-2025-05-08T19_22_00-2312147.txt include that?

@257
Copy link
Author

257 commented May 9, 2025

no it doesn't, i see

@fmease
Copy link
Member

fmease commented May 9, 2025

rustc crashed because you explicitly instructed it to crash by passing -Ztreat-err-as-bug=1. All pieces of info you have provided thus far merely belong to that explicitly requested crash which is not considered an actual bug.

If you cannot reproduce a crash without passing that flag, then there's no actual bug unless you want to report a different kind of bug (bad diagnostic, wrongfully rejected code, etc.).

@257
Copy link
Author

257 commented May 9, 2025

true that.

i'm cleaning up some warning to see if there is actually any compiler panic.

i will close this by the end of the day if i can't reproduce anything in the compiler.

@257
Copy link
Author

257 commented May 9, 2025

not a compiler issue. closing in favour of Getting "unresolved import crate::sys::IoSourceState" error running wasm-pack build

sorry for the noise.

@257 257 closed this as completed May 9, 2025
@257
Copy link
Author

257 commented May 9, 2025

for the Wondering Wanderers whom might end up here, runtime-tokio-rustls will break wasm-pack build(s)

@257
Copy link
Author

257 commented May 9, 2025

btw, i followed the instructions there, maybe in the case of panic compiler should check for -Ztreat-err-as-bug=1 before redirecting the user to file a report?

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) ❄️ S-needs-info Status: The issue lacks details necessary to triage or act on it. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

4 participants