Skip to content

Compiler failure on nightly #105885

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
ZNielsen opened this issue Dec 19, 2022 · 2 comments
Closed

Compiler failure on nightly #105885

ZNielsen opened this issue Dec 19, 2022 · 2 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.

Comments

@ZNielsen
Copy link

ZNielsen commented Dec 19, 2022

Hit an error with the nightly compiler. Not sure what the last nightly version I was using was, but I can confirm this used to build just fine.

Meta

rustc --version --verbose:

rustc 1.68.0-nightly (0468a00ae 2022-12-17)
binary: rustc
commit-hash: 0468a00ae3fd6ef1a6a0f9eaf637d7aa9e604acc
commit-date: 2022-12-17
host: aarch64-apple-darwin
release: 1.68.0-nightly
LLVM version: 15.0.6

Error output

error: internal compiler error: compiler/rustc_codegen_llvm/src/context.rs:971:13: failed to get layout for `rocket::futures::future::Either<((), Pin<&mut rocket::futures::future::MapErr<hyper::server::shutdown::Graceful<rocket::h
ttp::private::Incoming<rocket::ext::CancellableListener<rocket::Shutdown, L>>, hyper::service::make::MakeServiceFn<[closure@rocket::server::<impl Rocket<Orbit>>::http_server<L>::{closure#0}::{closure#0}]>, rocket::Shutdown, hyper:
:common::exec::Exec>, [closure@rocket::server::<impl Rocket<Orbit>>::http_server<L>::{closure#0}::{closure#1}]>>), (Result<(), rocket::Error>, rocket::Shutdown)>`: unable to determine layout for `rocket::futures::future::Either<((
), Pin<&mut rocket::futures::future::MapErr<hyper::server::shutdown::Graceful<rocket::http::private::Incoming<rocket::ext::CancellableListener<rocket::Shutdown, L>>, hyper::service::make::MakeServiceFn<[closure@rocket::server::<im
pl Rocket<Orbit>>::http_server<L>::{closure#0}::{closure#0}]>, rocket::Shutdown, hyper::common::exec::Exec>, [closure@rocket::server::<impl Rocket<Orbit>>::http_server<L>::{closure#0}::{closure#1}]>>), (Result<(), rocket::Error>,
rocket::Shutdown)>` because `rocket::futures::future::Either<((), Pin<&mut rocket::futures::future::MapErr<hyper::server::shutdown::Graceful<rocket::http::private::Incoming<rocket::ext::CancellableListener<rocket::Shutdown, L>>, h
yper::service::make::MakeServiceFn<[closure@rocket::server::<impl Rocket<Orbit>>::http_server<L>::{closure#0}::{closure#0}]>, rocket::Shutdown, hyper::common::exec::Exec>, [closure@rocket::server::<impl Rocket<Orbit>>::http_server
<L>::{closure#0}::{closure#1}]>>), (Result<(), rocket::Error>, rocket::Shutdown)>` cannot be normalized
Backtrace

thread 'rustc' panicked at 'Box<dyn Any>', /rustc/0468a00ae3fd6ef1a6a0f9eaf637d7aa9e604acc/compiler/rustc_errors/src/lib.rs:973:33
stack backtrace:
   0:        0x101652894 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h78b40c26d5b68363
   1:        0x1016a3b4c - core::fmt::write::h10a4055287babe71
   2:        0x101645e50 - std::io::Write::write_fmt::had0bf36856ab3411
   3:        0x1016526a8 - std::sys_common::backtrace::print::h54c1e3ac308e8d12
   4:        0x101655158 - std::panicking::default_hook::{{closure}}::h943b7ea12ce7721b
   5:        0x101654eb0 - std::panicking::default_hook::h7ea6571063632ef6
   6:        0x1098b22e4 - rustc_driver[aea5d5b66a820d93]::DEFAULT_HOOK::{closure#0}::{closure#0}
   7:        0x101655850 - std::panicking::rust_panic_with_hook::hdedc2fa44c593b2e
   8:        0x109acb484 - std[94c272b5e7685a6e]::panicking::begin_panic::<rustc_errors[9698c2e11fa3da5b]::ExplicitBug>::{closure#0}
   9:        0x109ac6edc - std[94c272b5e7685a6e]::sys_common::backtrace::__rust_end_short_backtrace::<std[94c272b5e7685a6e]::panicking::begin_panic<rustc_errors[9698c2e11fa3da5b]::ExplicitBug>::{closure#0}, !>
  10:        0x10dabfd94 - std[94c272b5e7685a6e]::panicking::begin_panic::<rustc_errors[9698c2e11fa3da5b]::ExplicitBug>
  11:        0x109ac6c7c - std[94c272b5e7685a6e]::panic::panic_any::<rustc_errors[9698c2e11fa3da5b]::ExplicitBug>
  12:        0x109abf53c - <rustc_errors[9698c2e11fa3da5b]::HandlerInner>::span_bug::<rustc_span[6fffbf6d99902008]::span_encoding::Span, &alloc[e4ff4d0497fd8ba1]::string::String>
  13:        0x109abf0e0 - <rustc_errors[9698c2e11fa3da5b]::Handler>::span_bug::<rustc_span[6fffbf6d99902008]::span_encoding::Span, &alloc[e4ff4d0497fd8ba1]::string::String>
  14:        0x1099efb3c - rustc_middle[f1c1ea426cbec5e4]::ty::context::tls::with_context_opt::<rustc_middle[f1c1ea426cbec5e4]::ty::context::tls::with_opt<rustc_middle[f1c1ea426cbec5e4]::util::bug::opt_span_bug_fmt<rustc_span[6fff
bf6d99902008]::span_encoding::Span>::{closure#0}, ()>::{closure#0}, ()>
  15:        0x1099efa08 - rustc_middle[f1c1ea426cbec5e4]::util::bug::opt_span_bug_fmt::<rustc_span[6fffbf6d99902008]::span_encoding::Span>
  16:        0x10dabfe08 - rustc_middle[f1c1ea426cbec5e4]::util::bug::span_bug_fmt::<rustc_span[6fffbf6d99902008]::span_encoding::Span>
  17:        0x1099eb518 - <rustc_codegen_llvm[bcc25b7c68fc7c93]::context::CodegenCx as rustc_middle[f1c1ea426cbec5e4]::ty::layout::LayoutOfHelpers>::handle_layout_err
  18:        0x1099e486c - <rustc_codegen_llvm[bcc25b7c68fc7c93]::context::CodegenCx as rustc_middle[f1c1ea426cbec5e4]::ty::layout::LayoutOf>::spanned_layout_of::{closure#0}
  19:        0x1099eae70 - ___rust_realloc
  20:        0x1099dfbac - <rustc_codegen_ssa[a9885fd9e56bc2f4]::mir::place::PlaceRef<&rustc_codegen_llvm[bcc25b7c68fc7c93]::llvm_::ffi::Value>>::project_type::<rustc_codegen_llvm[bcc25b7c68fc7c93]::builder::Builder>
  21:        0x109ab751c - <rustc_codegen_ssa[a9885fd9e56bc2f4]::mir::FunctionCx<rustc_codegen_llvm[bcc25b7c68fc7c93]::builder::Builder>>::codegen_place
  22:        0x109ab7cc4 - <rustc_codegen_ssa[a9885fd9e56bc2f4]::mir::FunctionCx<rustc_codegen_llvm[bcc25b7c68fc7c93]::builder::Builder>>::codegen_consume
  23:        0x109aac7cc - <rustc_codegen_ssa[a9885fd9e56bc2f4]::mir::FunctionCx<rustc_codegen_llvm[bcc25b7c68fc7c93]::builder::Builder>>::codegen_rvalue
  24:        0x109ab3e04 - <rustc_codegen_ssa[a9885fd9e56bc2f4]::mir::FunctionCx<rustc_codegen_llvm[bcc25b7c68fc7c93]::builder::Builder>>::codegen_block
  25:        0x109aab0a0 - rustc_codegen_ssa[a9885fd9e56bc2f4]::mir::codegen_mir::<rustc_codegen_llvm[bcc25b7c68fc7c93]::builder::Builder>
  26:        0x1099c7600 - rustc_codegen_ssa[a9885fd9e56bc2f4]::base::codegen_instance::<rustc_codegen_llvm[bcc25b7c68fc7c93]::builder::Builder>
  27:        0x109a65cb8 - <rustc_middle[f1c1ea426cbec5e4]::mir::mono::MonoItem as rustc_codegen_ssa[a9885fd9e56bc2f4]::mono_item::MonoItemExt>::define::<rustc_codegen_llvm[bcc25b7c68fc7c93]::builder::Builder>
  28:        0x109ad1550 - rustc_codegen_llvm[bcc25b7c68fc7c93]::base::compile_codegen_unit::module_codegen
  29:        0x109a2ee40 - <rustc_query_system[c8ea2281b441e7cd]::dep_graph::graph::DepGraph<rustc_middle[f1c1ea426cbec5e4]::dep_graph::dep_node::DepKind>>::with_task::<rustc_middle[f1c1ea426cbec5e4]::ty::context::TyCtxt, rustc_sp
an[6fffbf6d99902008]::symbol::Symbol, rustc_codegen_ssa[a9885fd9e56bc2f4]::ModuleCodegen<rustc_codegen_llvm[bcc25b7c68fc7c93]::ModuleLlvm>>
  30:        0x109ad62f0 - <rustc_codegen_llvm[bcc25b7c68fc7c93]::LlvmCodegenBackend as rustc_codegen_ssa[a9885fd9e56bc2f4]::traits::backend::ExtraBackendMethods>::compile_codegen_unit
  31:        0x1099c6ddc - rustc_codegen_ssa[a9885fd9e56bc2f4]::base::codegen_crate::<rustc_codegen_llvm[bcc25b7c68fc7c93]::LlvmCodegenBackend>
  32:        0x109ad747c - <rustc_codegen_llvm[bcc25b7c68fc7c93]::LlvmCodegenBackend as rustc_codegen_ssa[a9885fd9e56bc2f4]::traits::backend::CodegenBackend>::codegen_crate
  33:        0x109928fdc - <rustc_session[125d6d33ae4a5792]::session::Session>::time::<alloc[e4ff4d0497fd8ba1]::boxed::Box<dyn core[e4a553f48de12b3]::any::Any>, rustc_interface[688da3a0d72c0835]::passes::start_codegen::{closure#0}
>
  34:        0x109955c28 - rustc_interface[688da3a0d72c0835]::passes::start_codegen
  35:        0x109954c10 - <rustc_interface[688da3a0d72c0835]::passes::QueryContext>::enter::<<rustc_interface[688da3a0d72c0835]::queries::Queries>::ongoing_codegen::{closure#0}::{closure#0}, core[e4a553f48de12b3]::result::Result<
alloc[e4ff4d0497fd8ba1]::boxed::Box<dyn core[e4a553f48de12b3]::any::Any>, rustc_errors[9698c2e11fa3da5b]::ErrorGuaranteed>>
  36:        0x1099a5ba8 - <rustc_interface[688da3a0d72c0835]::queries::Queries>::ongoing_codegen
  37:        0x10988ebd0 - rustc_span[6fffbf6d99902008]::with_source_map::<core[e4a553f48de12b3]::result::Result<(), rustc_errors[9698c2e11fa3da5b]::ErrorGuaranteed>, rustc_interface[688da3a0d72c0835]::interface::run_compiler<core
[e4a553f48de12b3]::result::Result<(), rustc_errors[9698c2e11fa3da5b]::ErrorGuaranteed>, rustc_driver[aea5d5b66a820d93]::run_compiler::{closure#1}>::{closure#0}::{closure#0}>
  38:        0x109882814 - <scoped_tls[65bd00771f499b86]::ScopedKey<rustc_span[6fffbf6d99902008]::SessionGlobals>>::set::<rustc_interface[688da3a0d72c0835]::interface::run_compiler<core[e4a553f48de12b3]::result::Result<(), rustc_e
rrors[9698c2e11fa3da5b]::ErrorGuaranteed>, rustc_driver[aea5d5b66a820d93]::run_compiler::{closure#1}>::{closure#0}, core[e4a553f48de12b3]::result::Result<(), rustc_errors[9698c2e11fa3da5b]::ErrorGuaranteed>>
  39:        0x109857530 - std[94c272b5e7685a6e]::sys_common::backtrace::__rust_begin_short_backtrace::<rustc_interface[688da3a0d72c0835]::util::run_in_thread_pool_with_globals<rustc_interface[688da3a0d72c0835]::interface::run_com
piler<core[e4a553f48de12b3]::result::Result<(), rustc_errors[9698c2e11fa3da5b]::ErrorGuaranteed>, rustc_driver[aea5d5b66a820d93]::run_compiler::{closure#1}>::{closure#0}, core[e4a553f48de12b3]::result::Result<(), rustc_errors[9698
c2e11fa3da5b]::ErrorGuaranteed>>::{closure#0}::{closure#0}, core[e4a553f48de12b3]::result::Result<(), rustc_errors[9698c2e11fa3da5b]::ErrorGuaranteed>>
  40:        0x10983e148 - <<std[94c272b5e7685a6e]::thread::Builder>::spawn_unchecked_<rustc_interface[688da3a0d72c0835]::util::run_in_thread_pool_with_globals<rustc_interface[688da3a0d72c0835]::interface::run_compiler<core[e4a553
f48de12b3]::result::Result<(), rustc_errors[9698c2e11fa3da5b]::ErrorGuaranteed>, rustc_driver[aea5d5b66a820d93]::run_compiler::{closure#1}>::{closure#0}, core[e4a553f48de12b3]::result::Result<(), rustc_errors[9698c2e11fa3da5b]::Er
rorGuaranteed>>::{closure#0}::{closure#0}, core[e4a553f48de12b3]::result::Result<(), rustc_errors[9698c2e11fa3da5b]::ErrorGuaranteed>>::{closure#1} as core[e4a553f48de12b3]::ops::function::FnOnce<()>>::call_once::{shim:vtable#0}
  41:        0x10165dc6c - std::sys::unix::thread::Thread::new::thread_start::h54da5a7b9c5163fa
  42:        0x1a0cb506c - __pthread_deallocate

Extra info

note: the compiler unexpectedly panicked. this is a bug.

note: we would appreciate a bug report: https://github.com/rust-lang/rust/issues/new?labels=C-bug%2C+I-ICE%2C+T-compiler&template=ice.md

note: rustc 1.68.0-nightly (0468a00ae 2022-12-17) running on aarch64-apple-darwin

note: compiler flags: --crate-type bin -C opt-level=3 -C embed-bitcode=no

note: some of the compiler flags provided by cargo are hidden

query stack during panic:
end of query stack

@ZNielsen ZNielsen 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 Dec 19, 2022
@trevyn
Copy link
Contributor

trevyn commented Dec 19, 2022

Probably a dupe of #105809

@jackh726
Copy link
Member

Closing as duplicate.

@jackh726 jackh726 closed this as not planned Won't fix, can't repro, duplicate, stale Dec 19, 2022
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.
Projects
None yet
Development

No branches or pull requests

3 participants