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

Try to use ntex-mqtt in tokio run time and it cause ICE. #110528

Open
lsk569937453 opened this issue Apr 19, 2023 · 1 comment
Open

Try to use ntex-mqtt in tokio run time and it cause ICE. #110528

lsk569937453 opened this issue Apr 19, 2023 · 1 comment
Labels
A-debuginfo Area: Debugging information in compiled programs (DWARF, PDB, etc.) 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

@lsk569937453
Copy link

Code

The reproducible case is https://github.com/lsk569937453/rust-issue.

git clone git@github.com:lsk569937453/rust-issue.git
cargo run

Meta

rustc --version --verbose:

rustc 1.68.2 (9eb3afe9e 2023-03-27)
binary: rustc
commit-hash: 9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0
commit-date: 2023-03-27
host: x86_64-unknown-linux-gnu
release: 1.68.2
LLVM version: 15.0.6

Error output

error: internal compiler error: compiler/rustc_codegen_llvm/src/debuginfo/metadata/type_map.rs:133:13: type metadata for unique ID 'VariantStructType([async fn body@src/main.rs:54:50: 66:2], 0, HiddenZst)' is already in the `TypeMap`!

thread 'rustc' panicked at 'Box<dyn Any>', /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/compiler/rustc_errors/src/lib.rs:1609:9
stack backtrace:
   0:     0x7fdcb68dc59a - std::backtrace_rs::backtrace::libunwind::trace::ha271a8a7e1f3d4ef
                               at /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/library/std/src/../../backtrace/src/backtrace/libunwind.rs:93:5
   1:     0x7fdcb68dc59a - std::backtrace_rs::backtrace::trace_unsynchronized::h85739da0352c791a
                               at /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
   2:     0x7fdcb68dc59a - std::sys_common::backtrace::_print_fmt::hbc6ebcfb2910b329
                               at /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/library/std/src/sys_common/backtrace.rs:65:5
   3:     0x7fdcb68dc59a - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::he1c117e52d53614f
                               at /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/library/std/src/sys_common/backtrace.rs:44:22
   4:     0x7fdcb693e39e - core::fmt::write::h25eb51b9526b8e0c
                               at /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/library/core/src/fmt/mod.rs:1213:17
   5:     0x7fdcb68ccbe5 - std::io::Write::write_fmt::ha9edec5fb1621933
                               at /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/library/std/src/io/mod.rs:1682:15
   6:     0x7fdcb68dc365 - std::sys_common::backtrace::_print::hf8657cd429fc3452
                               at /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/library/std/src/sys_common/backtrace.rs:47:5
   7:     0x7fdcb68dc365 - std::sys_common::backtrace::print::h41b9b18ed86f86bd
                               at /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/library/std/src/sys_common/backtrace.rs:34:9
   8:     0x7fdcb68df12f - std::panicking::default_hook::{{closure}}::h22a91871f4454152
                               at /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/library/std/src/panicking.rs:267:22
   9:     0x7fdcb68dee6b - std::panicking::default_hook::h21ddc36de0cd4ae7
                               at /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/library/std/src/panicking.rs:286:9
  10:     0x7fdcb56b9324 - rustc_driver[70f63b52fde826b7]::DEFAULT_HOOK::{closure#0}::{closure#0}
  11:     0x7fdcb68df96a - <alloc::boxed::Box<F,A> as core::ops::function::Fn<Args>>::call::h6f7e3c94ecc52e2f
                               at /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/library/alloc/src/boxed.rs:2002:9
  12:     0x7fdcb68df96a - std::panicking::rust_panic_with_hook::h5059419d6d59b3d0
                               at /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/library/std/src/panicking.rs:692:13
  13:     0x7fdcb5bdf711 - std[f8b79e573431a86c]::panicking::begin_panic::<rustc_errors[53e74ce803854a4d]::ExplicitBug>::{closure#0}
  14:     0x7fdcb5bde136 - std[f8b79e573431a86c]::sys_common::backtrace::__rust_end_short_backtrace::<std[f8b79e573431a86c]::panicking::begin_panic<rustc_errors[53e74ce803854a4d]::ExplicitBug>::{closure#0}, !>
  15:     0x7fdcb5c4aad6 - std[f8b79e573431a86c]::panicking::begin_panic::<rustc_errors[53e74ce803854a4d]::ExplicitBug>
  16:     0x7fdcb5c0bcb6 - std[f8b79e573431a86c]::panic::panic_any::<rustc_errors[53e74ce803854a4d]::ExplicitBug>
  17:     0x7fdcb5c06586 - <rustc_errors[53e74ce803854a4d]::HandlerInner>::bug::<&alloc[b346c7f99e9347e5]::string::String>
  18:     0x7fdcb5c04e90 - <rustc_errors[53e74ce803854a4d]::Handler>::bug::<&alloc[b346c7f99e9347e5]::string::String>
  19:     0x7fdcb5c1a4cb - rustc_middle[6dfce017f6b7786d]::util::bug::opt_span_bug_fmt::<rustc_span[7c23fb27ec020b97]::span_encoding::Span>::{closure#0}
  20:     0x7fdcb5c1a2fa - rustc_middle[6dfce017f6b7786d]::ty::context::tls::with_opt::<rustc_middle[6dfce017f6b7786d]::util::bug::opt_span_bug_fmt<rustc_span[7c23fb27ec020b97]::span_encoding::Span>::{closure#0}, !>::{closure#0}
  21:     0x7fdcb5c1a2ca - rustc_middle[6dfce017f6b7786d]::ty::context::tls::with_context_opt::<rustc_middle[6dfce017f6b7786d]::ty::context::tls::with_opt<rustc_middle[6dfce017f6b7786d]::util::bug::opt_span_bug_fmt<rustc_span[7c23fb27ec020b97]::span_encoding::Span>::{closure#0}, !>::{closure#0}, !>
  22:     0x7fdcb5c1a416 - rustc_middle[6dfce017f6b7786d]::util::bug::opt_span_bug_fmt::<rustc_span[7c23fb27ec020b97]::span_encoding::Span>
  23:     0x7fdcb390cbe3 - rustc_middle[6dfce017f6b7786d]::util::bug::bug_fmt
  24:     0x7fdcb4f5eb8a - <rustc_codegen_llvm[da948ad3e38c86a6]::debuginfo::metadata::type_map::TypeMap>::insert
  25:     0x7fdcb555e8a6 - rustc_codegen_llvm[da948ad3e38c86a6]::debuginfo::metadata::type_map::build_type_with_children::<rustc_codegen_llvm[da948ad3e38c86a6]::debuginfo::metadata::enums::build_generator_variant_struct_type_di_node::{closure#0}, rustc_codegen_llvm[da948ad3e38c86a6]::debuginfo::metadata::enums::build_generator_variant_struct_type_di_node::{closure#1}>
  26:     0x7fdcb54fa6c4 - rustc_codegen_llvm[da948ad3e38c86a6]::debuginfo::metadata::enums::build_generator_variant_struct_type_di_node
  27:     0x7fdcb54f75f9 - <&mut rustc_codegen_llvm[da948ad3e38c86a6]::debuginfo::metadata::enums::native::build_generator_di_node::{closure#0}::{closure#0} as core[1d432356d8e1e9f1]::ops::function::FnOnce<(rustc_target[b039ca5ad3a23b78]::abi::VariantIdx,)>>::call_once
  28:     0x7fdcb553a02a - <smallvec[31f04b8acc434592]::SmallVec<[rustc_codegen_llvm[da948ad3e38c86a6]::debuginfo::metadata::enums::native::VariantMemberInfo; 16usize]> as core[1d432356d8e1e9f1]::iter::traits::collect::Extend<rustc_codegen_llvm[da948ad3e38c86a6]::debuginfo::metadata::enums::native::VariantMemberInfo>>::extend::<core[1d432356d8e1e9f1]::iter::adapters::map::Map<core[1d432356d8e1e9f1]::iter::adapters::map::Map<core[1d432356d8e1e9f1]::ops::range::Range<usize>, <rustc_index[525e17cad9ac453c]::vec::IndexVec<rustc_target[b039ca5ad3a23b78]::abi::VariantIdx, rustc_abi[7786bd53a331fdfb]::LayoutS<rustc_target[b039ca5ad3a23b78]::abi::VariantIdx>>>::indices::{closure#0}>, rustc_codegen_llvm[da948ad3e38c86a6]::debuginfo::metadata::enums::native::build_generator_di_node::{closure#0}::{closure#0}>>
  29:     0x7fdcb555f091 - rustc_codegen_llvm[da948ad3e38c86a6]::debuginfo::metadata::type_map::build_type_with_children::<rustc_codegen_llvm[da948ad3e38c86a6]::debuginfo::metadata::enums::native::build_generator_di_node::{closure#0}, for<'a, 'b, 'c> fn(&'a rustc_codegen_llvm[da948ad3e38c86a6]::context::CodegenCx<'b, 'c>) -> smallvec[31f04b8acc434592]::SmallVec<[&'b rustc_codegen_llvm[da948ad3e38c86a6]::llvm_::ffi::Metadata; 16usize]>>
  30:     0x7fdcb54f9df2 - rustc_codegen_llvm[da948ad3e38c86a6]::debuginfo::metadata::enums::build_generator_di_node
  31:     0x7fdcb3e20286 - rustc_codegen_llvm[da948ad3e38c86a6]::debuginfo::metadata::type_di_node
  32:     0x7fdcb3f6c4d6 - <rustc_codegen_llvm[da948ad3e38c86a6]::context::CodegenCx as rustc_codegen_ssa[356018be9b9ac562]::traits::debuginfo::DebugInfoMethods>::create_dbg_var
  33:     0x7fdcb3f6219c - rustc_codegen_ssa[356018be9b9ac562]::mir::codegen_mir::<rustc_codegen_llvm[da948ad3e38c86a6]::builder::Builder>
  34:     0x7fdcb4b82826 - rustc_codegen_llvm[da948ad3e38c86a6]::base::compile_codegen_unit::module_codegen
  35:     0x7fdcb4b2f91c - <rustc_query_system[59807289ca97d521]::dep_graph::graph::DepGraph<rustc_middle[6dfce017f6b7786d]::dep_graph::dep_node::DepKind>>::with_task::<rustc_middle[6dfce017f6b7786d]::ty::context::TyCtxt, rustc_span[7c23fb27ec020b97]::symbol::Symbol, rustc_codegen_ssa[356018be9b9ac562]::ModuleCodegen<rustc_codegen_llvm[da948ad3e38c86a6]::ModuleLlvm>>
  36:     0x7fdcb4b2dcb4 - rustc_codegen_llvm[da948ad3e38c86a6]::base::compile_codegen_unit
  37:     0x7fdcb4b2c4a5 - rustc_codegen_ssa[356018be9b9ac562]::base::codegen_crate::<rustc_codegen_llvm[da948ad3e38c86a6]::LlvmCodegenBackend>
  38:     0x7fdcb4b2bc79 - <rustc_codegen_llvm[da948ad3e38c86a6]::LlvmCodegenBackend as rustc_codegen_ssa[356018be9b9ac562]::traits::backend::CodegenBackend>::codegen_crate
  39:     0x7fdcb489ed01 - <rustc_session[cd7c78827427c6d6]::session::Session>::time::<alloc[b346c7f99e9347e5]::boxed::Box<dyn core[1d432356d8e1e9f1]::any::Any>, rustc_interface[698bad460dbd68d3]::passes::start_codegen::{closure#0}>
  40:     0x7fdcb489e829 - rustc_interface[698bad460dbd68d3]::passes::start_codegen
  41:     0x7fdcb489ddba - <rustc_interface[698bad460dbd68d3]::queries::Queries>::ongoing_codegen
  42:     0x7fdcb4897ab9 - rustc_span[7c23fb27ec020b97]::with_source_map::<core[1d432356d8e1e9f1]::result::Result<(), rustc_errors[53e74ce803854a4d]::ErrorGuaranteed>, rustc_interface[698bad460dbd68d3]::interface::run_compiler<core[1d432356d8e1e9f1]::result::Result<(), rustc_errors[53e74ce803854a4d]::ErrorGuaranteed>, rustc_driver[70f63b52fde826b7]::run_compiler::{closure#1}>::{closure#0}::{closure#0}>
  43:     0x7fdcb48902d4 - <scoped_tls[1044df3f3db9be03]::ScopedKey<rustc_span[7c23fb27ec020b97]::SessionGlobals>>::set::<rustc_interface[698bad460dbd68d3]::interface::run_compiler<core[1d432356d8e1e9f1]::result::Result<(), rustc_errors[53e74ce803854a4d]::ErrorGuaranteed>, rustc_driver[70f63b52fde826b7]::run_compiler::{closure#1}>::{closure#0}, core[1d432356d8e1e9f1]::result::Result<(), rustc_errors[53e74ce803854a4d]::ErrorGuaranteed>>
  44:     0x7fdcb488f9d2 - std[f8b79e573431a86c]::sys_common::backtrace::__rust_begin_short_backtrace::<rustc_interface[698bad460dbd68d3]::util::run_in_thread_pool_with_globals<rustc_interface[698bad460dbd68d3]::interface::run_compiler<core[1d432356d8e1e9f1]::result::Result<(), rustc_errors[53e74ce803854a4d]::ErrorGuaranteed>, rustc_driver[70f63b52fde826b7]::run_compiler::{closure#1}>::{closure#0}, core[1d432356d8e1e9f1]::result::Result<(), rustc_errors[53e74ce803854a4d]::ErrorGuaranteed>>::{closure#0}::{closure#0}, core[1d432356d8e1e9f1]::result::Result<(), rustc_errors[53e74ce803854a4d]::ErrorGuaranteed>>
  45:     0x7fdcb488f77a - <<std[f8b79e573431a86c]::thread::Builder>::spawn_unchecked_<rustc_interface[698bad460dbd68d3]::util::run_in_thread_pool_with_globals<rustc_interface[698bad460dbd68d3]::interface::run_compiler<core[1d432356d8e1e9f1]::result::Result<(), rustc_errors[53e74ce803854a4d]::ErrorGuaranteed>, rustc_driver[70f63b52fde826b7]::run_compiler::{closure#1}>::{closure#0}, core[1d432356d8e1e9f1]::result::Result<(), rustc_errors[53e74ce803854a4d]::ErrorGuaranteed>>::{closure#0}::{closure#0}, core[1d432356d8e1e9f1]::result::Result<(), rustc_errors[53e74ce803854a4d]::ErrorGuaranteed>>::{closure#1} as core[1d432356d8e1e9f1]::ops::function::FnOnce<()>>::call_once::{shim:vtable#0}
  46:     0x7fdcb68e9823 - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::h3205ec2d7fc232c5
                               at /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/library/alloc/src/boxed.rs:1988:9
  47:     0x7fdcb68e9823 - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::h3bb5daec8177f56b
                               at /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/library/alloc/src/boxed.rs:1988:9
  48:     0x7fdcb68e9823 - std::sys::unix::thread::Thread::new::thread_start::had7b8061e306bb5c
                               at /rustc/9eb3afe9ebe9c7d2b84b71002d44f4a0edac95e0/library/std/src/sys/unix/thread.rs:108:17
  49:     0x7fdcb2094b43 - start_thread
                               at ./nptl/./nptl/pthread_create.c:442:8
  50:     0x7fdcb2126a00 - clone3
                               at ./misc/../sysdeps/unix/sysv/linux/x86_64/clone3.S:81
  51:                0x0 - <unknown>

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.2 (9eb3afe9e 2023-03-27) running on x86_64-unknown-linux-gnu

note: compiler flags: --crate-type bin -C embed-bitcode=no -C debuginfo=2 -C incremental=[REDACTED]

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

query stack during panic:
end of query stack
error: could not compile `rust-issue`

Backtrace

<backtrace>

@lsk569937453 lsk569937453 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 Apr 19, 2023
@Noratrieb Noratrieb added the A-debuginfo Area: Debugging information in compiled programs (DWARF, PDB, etc.) label Apr 19, 2023
@matthiaskrgr
Copy link
Member

proly related to #109464

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-debuginfo Area: Debugging information in compiled programs (DWARF, PDB, etc.) 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