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

ICE: Featuring core in std makes compiler go sideways #91767

Closed
workingjubilee opened this issue Dec 11, 2021 · 8 comments
Closed

ICE: Featuring core in std makes compiler go sideways #91767

workingjubilee opened this issue Dec 11, 2021 · 8 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

@workingjubilee
Copy link
Member

workingjubilee commented Dec 11, 2021

On Zulip, I was told this should "just work" by @Mark-Simulacrum. It does not and in fact ICEs, so I am reporting it as a bug for others to investigate at their leisure. @camelid might also be interested. 🤷

Code

This is provoked by applying the following diff and invoking x.py check.

diff --git a/library/core/Cargo.toml b/library/core/Cargo.toml
index 6f10b9e4342..f65757e8cb8 100644
--- a/library/core/Cargo.toml
+++ b/library/core/Cargo.toml
@@ -30,3 +30,4 @@ panic_immediate_abort = []
 # Make `RefCell` store additional debugging information, which is printed out when
 # a borrow error occurs
 debug_refcell = []
+as_std = []
diff --git a/library/std/Cargo.toml b/library/std/Cargo.toml
index f7111748321..538cf4e4e15 100644
--- a/library/std/Cargo.toml
+++ b/library/std/Cargo.toml
@@ -14,7 +14,7 @@ alloc = { path = "../alloc" }
 cfg-if = { version = "0.1.8", features = ['rustc-dep-of-std'] }
 panic_unwind = { path = "../panic_unwind", optional = true }
 panic_abort = { path = "../panic_abort" }
-core = { path = "../core" }
+core = { path = "../core", features = ['as_std'] }
 libc = { version = "0.2.108", default-features = false, features = ['rustc-dep-of-std'] }
 compiler_builtins = { version = "0.1.55" }
 profiler_builtins = { path = "../profiler_builtins", optional = true }

Meta

This is an issue during bootstrapping the compiler. The build was based on e6b883c.

Error output

thread 'rustc' panicked at 'no entry found for key', compiler\rustc_metadata\src\rmeta\decoder\cstore_impl.rs:492:9
thread 'rustc' panicked at 'no entry found for key', compiler\rustc_metadata\src\rmeta\decoder\cstore_impl.rs:492:9
stack backtrace:
stack backtrace:
Backtrace

thread 'rustc' panicked at 'no entry found for key', compiler\rustc_metadata\src\rmeta\decoder\cstore_impl.rs:492:9
thread 'rustc' panicked at 'no entry found for key', compiler\rustc_metadata\src\rmeta\decoder\cstore_impl.rs:492:9
stack backtrace:
stack backtrace:
   0:     0x7ff9a444970f - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::he7b0c252d602fcdc
   1:     0x7ff9a4473fba - core::fmt::write::h6aa0db73705fd604
   2:     0x7ff9a443b468 - <std::io::IoSliceMut as core::fmt::Debug>::fmt::h8e4c6764c89f6382
   3:     0x7ff9a444cc56 - std::panicking::take_hook::h30eaa8b54ef03df3
   4:     0x7ff9a444c73c - std::panicking::take_hook::h30eaa8b54ef03df3
   5:     0x7ff998efaf5e - <rustc_middle[4db38f5bb30aa45a]::mir::Operand as rustc_mir_dataflow[1f04c5db66c6e383]::move_paths::abs_domain::Lift>::lift
   6:     0x7ff9a444d569 - std::panicking::rust_panic_with_hook::hef9b22ae6e202465
   7:     0x7ff9a444d00b - rust_begin_unwind
   8:     0x7ff9a444a037 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::he7b0c252d602fcdc
   9:     0x7ff9a444cf69 - rust_begin_unwind
  10:     0x7ff9a44a8440 - core::panicking::panic_fmt::h8a2153897acddc1e
  11:     0x7ff9a4470bd0 - <core::panic::panic_info::PanicInfo as core::fmt::Display>::fmt::h1be40518aba961fa
  12:     0x7ff9a44a833b - core::option::expect_failed::h310324ec3680c3dc
  13:     0x7ff99cb1aee6 - <rustc_metadata[3f552bc9b26a2513]::creader::CStore as rustc_session[80b12927c96efe93]::cstore::CrateStore>::stable_crate_id_to_crate_num
  14:     0x7ff99c6ec1c0 - <rustc_query_impl[8639f0a94254e3b9]::on_disk_cache::OnDiskCache>::load_side_effects
    Checking rls-data v0.19.1
  15:     0x7ff99c608fdf - <rustc_span[fb335929b56265a7]::span_encoding::Span as rustc_serialize[9f7480aaaa4758fb]::serialize::Decodable<rustc_query_impl[8639f0a94254e3b9]::on_disk_cache::CacheDecoder>>::decode
  16:     0x7ff99c7de3ad - rustc_query_impl[8639f0a94254e3b9]::query_callbacks::diagnostic_hir_wf_check
  17:     0x7ff99c81fc20 - <&[rustc_ast[313453e987c93035]::ast::InlineAsmTemplatePiece] as rustc_serialize[9f7480aaaa4758fb]::serialize::Decodable<rustc_query_impl[8639f0a94254e3b9]::on_disk_cache::CacheDecoder>>::decode
  18:     0x7ff99c7f1766 - rustc_query_impl[8639f0a94254e3b9]::query_callbacks::diagnostic_hir_wf_check
  19:     0x7ff99c6e7b4c - <rustc_query_impl[8639f0a94254e3b9]::on_disk_cache::OnDiskCache>::load_side_effects
  20:     0x7ff99c5cad24 - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  21:     0x7ff99c5695c2 - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  22:     0x7ff99c625012 - <rustc_query_impl[8639f0a94254e3b9]::queries::diagnostic_hir_wf_check as rustc_query_system[7f2d0936c5979e74]::query::config::QueryDescription<rustc_query_impl[8639f0a94254e3b9]::plumbing::QueryCtxt>>::describe
  23:     0x7ff99c4d7a3f - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  24:     0x7ff99c586a61 - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  25:     0x7ff99c6646f9 - <rustc_query_impl[8639f0a94254e3b9]::Queries as rustc_middle[4db38f5bb30aa45a]::ty::query::QueryEngine>::try_mark_green
  26:     0x7ff99babb0b6 - rustc_ty_utils[ac82e78d48daf646]::provide
  27:     0x7ff99c68edbf - <rustc_span[fb335929b56265a7]::def_id::LocalDefId as rustc_query_impl[8639f0a94254e3b9]::profiling_support::SpecIntoSelfProfilingString>::spec_to_self_profile_string
  28:     0x7ff99c74a966 - rustc_query_impl[8639f0a94254e3b9]::query_callbacks::diagnostic_hir_wf_check
  29:     0x7ff99c6378db - <rustc_query_impl[8639f0a94254e3b9]::queries::diagnostic_hir_wf_check as rustc_query_system[7f2d0936c5979e74]::query::config::QueryDescription<rustc_query_impl[8639f0a94254e3b9]::plumbing::QueryCtxt>>::describe
  30:     0x7ff99c4d1b7f - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  31:     0x7ff99c5c642c - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  32:     0x7ff99b9fa767 - <rustc_typeck[44a0375dafd03453]::check::wfcheck::GATSubstCollector as rustc_middle[4db38f5bb30aa45a]::ty::fold::TypeVisitor>::visit_ty
  33:     0x7ff99ba04240 - <rustc_typeck[44a0375dafd03453]::check::upvar::InferBorrowKind as rustc_typeck[44a0375dafd03453]::expr_use_visitor::Delegate>::mutate
  34:     0x7ff99c68e446 - <rustc_span[fb335929b56265a7]::def_id::LocalDefId as rustc_query_impl[8639f0a94254e3b9]::profiling_support::SpecIntoSelfProfilingString>::spec_to_self_profile_string
  35:     0x7ff99c746c51 - rustc_query_impl[8639f0a94254e3b9]::query_callbacks::diagnostic_hir_wf_check
  36:     0x7ff99c643b07 - <rustc_query_impl[8639f0a94254e3b9]::queries::diagnostic_hir_wf_check as rustc_query_system[7f2d0936c5979e74]::query::config::QueryDescription<rustc_query_impl[8639f0a94254e3b9]::plumbing::QueryCtxt>>::describe
  37:     0x7ff99c4a9b34 - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  38:     0x7ff99c5a5342 - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  39:     0x7ff99ba395e7 - <rustc_typeck[44a0375dafd03453]::variance::terms::InferredIndex as core[5e9b1f0661f006a4]::fmt::Debug>::fmt
  40:     0x7ff99b98a119 - <rustc_typeck[44a0375dafd03453]::constrained_generic_params::Parameter as core[5e9b1f0661f006a4]::fmt::Debug>::fmt
  41:     0x7ff99b8f4902 - <rustc_typeck[44a0375dafd03453]::outlives::explicit::ExplicitPredicatesMap as core[5e9b1f0661f006a4]::fmt::Debug>::fmt
  42:     0x7ff99b8f14bf - rustc_typeck[44a0375dafd03453]::check_crate
  43:     0x7ff99905e62f - rustc_interface[3b7069506c759068]::passes::analysis
  44:     0x7ff99c69023b - <rustc_span[fb335929b56265a7]::def_id::LocalDefId as rustc_query_impl[8639f0a94254e3b9]::profiling_support::SpecIntoSelfProfilingString>::spec_to_self_profile_string
  45:     0x7ff99c76257e - rustc_query_impl[8639f0a94254e3b9]::query_callbacks::diagnostic_hir_wf_check
  46:     0x7ff99c6342d1 - <rustc_query_impl[8639f0a94254e3b9]::queries::diagnostic_hir_wf_check as rustc_query_system[7f2d0936c5979e74]::query::config::QueryDescription<rustc_query_impl[8639f0a94254e3b9]::plumbing::QueryCtxt>>::describe
  47:     0x7ff99c529b99 - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  48:     0x7ff99c5c3792 - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  49:     0x7ff998f7ab70 - <rustc_driver[a96692e377e9fbc1]::args::Error as core[5e9b1f0661f006a4]::fmt::Debug>::fmt
  50:     0x7ff998f20a4f - <rustc_middle[4db38f5bb30aa45a]::ty::SymbolName as core[5e9b1f0661f006a4]::fmt::Display>::fmt  51:     0x7ff998f12435 - <rustc_ast_passes[8672db41ecf6779a]::node_count::NodeCounter as rustc_ast[313453e987c93035]::visit::Visitor>::visit_attribute
  52:     0x7ff998f22001 - <rustc_middle[4db38f5bb30aa45a]::ty::SymbolName as core[5e9b1f0661f006a4]::fmt::Display>::fmt  53:     0x7ff998f1da93 - rustc_driver[a96692e377e9fbc1]::pretty::print_after_hir_lowering
  54:     0x7ff998f978d8 - <rustc_driver[a96692e377e9fbc1]::args::Error as core[5e9b1f0661f006a4]::fmt::Debug>::fmt
  55:     0x7ff9a445ac6c - std::sys::windows::thread::Thread::new::hfa213d96886b5f6f
  56:     0x7ffa296c7034 - BaseThreadInitThunk
  57:     0x7ffa2a4c2651 - RtlUserThreadStart

error: internal compiler error: unexpected panic

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.58.0-beta.1 (426b94d7d 2021-11-29) running on x86_64-pc-windows-msvc

note: compiler flags: -Z symbol-mangling-version=v0 -Z macro-backtrace -Z tls-model=initial-exec -Z unstable-options -Z binary-dep-depinfo -Z force-unstable-if-unmarked -C opt-level=3 -C embed-bitcode=no -C debuginfo=0 -C incremental -C target-feature=+crt-static -C prefer-dynamic -C llvm-args=-import-instr-limit=10 --crate-type lib

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

query stack during panic:
#0 [predicates_of] computing predicates of `json::FormatShim`
#1 [param_env] computing normalized predicates of `json::FormatShim`
#2 [check_item_well_formed] checking that `json::FormatShim` is well-formed
#3 [analysis] running analysis passes on this crate
end of query stack
   0:     0x7ff9a444970f - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::he7b0c252d602fcdc
   1:     0x7ff9a4473fba - core::fmt::write::h6aa0db73705fd604
   2:     0x7ff9a443b468 - <std::io::IoSliceMut as core::fmt::Debug>::fmt::h8e4c6764c89f6382
   3:     0x7ff9a444cc56 - std::panicking::take_hook::h30eaa8b54ef03df3
   4:     0x7ff9a444c73c - std::panicking::take_hook::h30eaa8b54ef03df3
   5:     0x7ff998efaf5e - <rustc_middle[4db38f5bb30aa45a]::mir::Operand as rustc_mir_dataflow[1f04c5db66c6e383]::move_paths::abs_domain::Lift>::lift
   6:     0x7ff9a444d569 - std::panicking::rust_panic_with_hook::hef9b22ae6e202465
   7:     0x7ff9a444d00b - rust_begin_unwind
   8:     0x7ff9a444a037 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::he7b0c252d602fcdc
   9:     0x7ff9a444cf69 - rust_begin_unwind
  10:     0x7ff9a44a8440 - core::panicking::panic_fmt::h8a2153897acddc1e
  11:     0x7ff9a4470bd0 - <core::panic::panic_info::PanicInfo as core::fmt::Display>::fmt::h1be40518aba961fa
  12:     0x7ff9a44a833b - core::option::expect_failed::h310324ec3680c3dc
  13:     0x7ff99cb1aee6 - <rustc_metadata[3f552bc9b26a2513]::creader::CStore as rustc_session[80b12927c96efe93]::cstore::CrateStore>::stable_crate_id_to_crate_num
  14:     0x7ff99c6ec1c0 - <rustc_query_impl[8639f0a94254e3b9]::on_disk_cache::OnDiskCache>::load_side_effects
  15:     0x7ff99c608fdf - <rustc_span[fb335929b56265a7]::span_encoding::Span as rustc_serialize[9f7480aaaa4758fb]::serialize::Decodable<rustc_query_impl[8639f0a94254e3b9]::on_disk_cache::CacheDecoder>>::decode
  16:     0x7ff99c7de3ad - rustc_query_impl[8639f0a94254e3b9]::query_callbacks::diagnostic_hir_wf_check
  17:     0x7ff99c81fc20 - <&[rustc_ast[313453e987c93035]::ast::InlineAsmTemplatePiece] as rustc_serialize[9f7480aaaa4758fb]::serialize::Decodable<rustc_query_impl[8639f0a94254e3b9]::on_disk_cache::CacheDecoder>>::decode
  18:     0x7ff99c7f1766 - rustc_query_impl[8639f0a94254e3b9]::query_callbacks::diagnostic_hir_wf_check
  19:     0x7ff99c6e7b4c - <rustc_query_impl[8639f0a94254e3b9]::on_disk_cache::OnDiskCache>::load_side_effects
  20:     0x7ff99c5cad24 - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  21:     0x7ff99c5695c2 - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  22:     0x7ff99c625012 - <rustc_query_impl[8639f0a94254e3b9]::queries::diagnostic_hir_wf_check as rustc_query_system[7f2d0936c5979e74]::query::config::QueryDescription<rustc_query_impl[8639f0a94254e3b9]::plumbing::QueryCtxt>>::describe
  23:     0x7ff99c4d7a3f - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  24:     0x7ff99c586a61 - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  25:     0x7ff99c6646f9 - <rustc_query_impl[8639f0a94254e3b9]::Queries as rustc_middle[4db38f5bb30aa45a]::ty::query::QueryEngine>::try_mark_green
  26:     0x7ff99babb0b6 - rustc_ty_utils[ac82e78d48daf646]::provide
  27:     0x7ff99c68edbf - <rustc_span[fb335929b56265a7]::def_id::LocalDefId as rustc_query_impl[8639f0a94254e3b9]::profiling_support::SpecIntoSelfProfilingString>::spec_to_self_profile_string
  28:     0x7ff99c74a966 - rustc_query_impl[8639f0a94254e3b9]::query_callbacks::diagnostic_hir_wf_check
  29:     0x7ff99c6378db - <rustc_query_impl[8639f0a94254e3b9]::queries::diagnostic_hir_wf_check as rustc_query_system[7f2d0936c5979e74]::query::config::QueryDescription<rustc_query_impl[8639f0a94254e3b9]::plumbing::QueryCtxt>>::describe
  30:     0x7ff99c4d1b7f - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  31:     0x7ff99c5c642c - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  32:     0x7ff99b9fa767 - <rustc_typeck[44a0375dafd03453]::check::wfcheck::GATSubstCollector as rustc_middle[4db38f5bb30aa45a]::ty::fold::TypeVisitor>::visit_ty
  33:     0x7ff99ba04240 - <rustc_typeck[44a0375dafd03453]::check::upvar::InferBorrowKind as rustc_typeck[44a0375dafd03453]::expr_use_visitor::Delegate>::mutate
  34:     0x7ff99c68e446 - <rustc_span[fb335929b56265a7]::def_id::LocalDefId as rustc_query_impl[8639f0a94254e3b9]::profiling_support::SpecIntoSelfProfilingString>::spec_to_self_profile_string
  35:     0x7ff99c746c51 - rustc_query_impl[8639f0a94254e3b9]::query_callbacks::diagnostic_hir_wf_check
  36:     0x7ff99c643b07 - <rustc_query_impl[8639f0a94254e3b9]::queries::diagnostic_hir_wf_check as rustc_query_system[7f2d0936c5979e74]::query::config::QueryDescription<rustc_query_impl[8639f0a94254e3b9]::plumbing::QueryCtxt>>::describe
  37:     0x7ff99c4a9b34 - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  38:     0x7ff99c5a5342 - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  39:     0x7ff99ba395e7 - <rustc_typeck[44a0375dafd03453]::variance::terms::InferredIndex as core[5e9b1f0661f006a4]::fmt::Debug>::fmt
  40:     0x7ff99b98a119 - <rustc_typeck[44a0375dafd03453]::constrained_generic_params::Parameter as core[5e9b1f0661f006a4]::fmt::Debug>::fmt
  41:     0x7ff99b8f4902 - <rustc_typeck[44a0375dafd03453]::outlives::explicit::ExplicitPredicatesMap as core[5e9b1f0661f006a4]::fmt::Debug>::fmt
  42:     0x7ff99b8f14bf - rustc_typeck[44a0375dafd03453]::check_crate
  43:     0x7ff99905e62f - rustc_interface[3b7069506c759068]::passes::analysis
  44:     0x7ff99c69023b - <rustc_span[fb335929b56265a7]::def_id::LocalDefId as rustc_query_impl[8639f0a94254e3b9]::profiling_support::SpecIntoSelfProfilingString>::spec_to_self_profile_string
  45:     0x7ff99c76257e - rustc_query_impl[8639f0a94254e3b9]::query_callbacks::diagnostic_hir_wf_check
  46:     0x7ff99c6342d1 - <rustc_query_impl[8639f0a94254e3b9]::queries::diagnostic_hir_wf_check as rustc_query_system[7f2d0936c5979e74]::query::config::QueryDescription<rustc_query_impl[8639f0a94254e3b9]::plumbing::QueryCtxt>>::describe
  47:     0x7ff99c529b99 - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  48:     0x7ff99c5c3792 - <rustc_mir_dataflow[1f04c5db66c6e383]::framework::engine::RustcMirAttrs>::output_path
  49:     0x7ff998f7ab70 - <rustc_driver[a96692e377e9fbc1]::args::Error as core[5e9b1f0661f006a4]::fmt::Debug>::fmt
  50:     0x7ff998f20a4f - <rustc_middle[4db38f5bb30aa45a]::ty::SymbolName as core[5e9b1f0661f006a4]::fmt::Display>::fmt  51:     0x7ff998f12435 - <rustc_ast_passes[8672db41ecf6779a]::node_count::NodeCounter as rustc_ast[313453e987c93035]::visit::Visitor>::visit_attribute
  52:     0x7ff998f22001 - <rustc_middle[4db38f5bb30aa45a]::ty::SymbolName as core[5e9b1f0661f006a4]::fmt::Display>::fmt  53:     0x7ff998f1da93 - rustc_driver[a96692e377e9fbc1]::pretty::print_after_hir_lowering
  54:     0x7ff998f978d8 - <rustc_driver[a96692e377e9fbc1]::args::Error as core[5e9b1f0661f006a4]::fmt::Debug>::fmt
  55:     0x7ff9a445ac6c - std::sys::windows::thread::Thread::new::hfa213d96886b5f6f
  56:     0x7ffa296c7034 - BaseThreadInitThunk
  57:     0x7ffa2a4c2651 - RtlUserThreadStart

error: internal compiler error: unexpected panic

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.58.0-beta.1 (426b94d7d 2021-11-29) running on x86_64-pc-windows-msvc

note: compiler flags: -Z symbol-mangling-version=v0 -Z macro-backtrace -Z tls-model=initial-exec -Z unstable-options -Z binary-dep-depinfo -Z force-unstable-if-unmarked -C opt-level=3 -C embed-bitcode=no -C debuginfo=0 -C incremental -C target-feature=+crt-static -C prefer-dynamic -C llvm-args=-import-instr-limit=10

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

query stack during panic:
#0 [predicates_of] computing predicates of `json::FormatShim`
#1 [param_env] computing normalized predicates of `json::FormatShim`
#2 [check_item_well_formed] checking that `json::FormatShim` is well-formed
#3 [analysis] running analysis passes on this crate
end of query stack
    Checking measureme v10.0.0
    Checking matchers v0.0.1
    Checking tracing-subscriber v0.2.16
error: could not compile `rustc_serialize`

Caused by:
  process didn't exit successfully: `C:\Users\${name}\project\rustc\build\bootstrap/debug/rustc --crate-name rustc_serialize --edition=2021 compiler\rustc_serialize\src\lib.rs --error-format=json --json=diagnostic-rendered-ansi --crate-type lib --emit=dep-info,metadata -C opt-level=3 -C embed-bitcode=no -C debuginfo=0 -C metadata=69e74595040b2647 -C extra-filename=-69e74595040b2647 --out-dir C:\Users\${name}\project\rustc\build\x86_64-pc-windows-msvc\stage0-rustc\x86_64-pc-windows-msvc\release\deps --target x86_64-pc-windows-msvc -C incremental=C:\Users\${name}\project\rustc\build\x86_64-pc-windows-msvc\stage0-rustc\x86_64-pc-windows-msvc\release\incremental -L dependency=C:\Users\${name}\project\rustc\build\x86_64-pc-windows-msvc\stage0-rustc\x86_64-pc-windows-msvc\release\deps -L dependency=C:\Users\${name}\project\rustc\build\x86_64-pc-windows-msvc\stage0-rustc\release\deps --extern indexmap=C:\Users\${name}\project\rustc\build\x86_64-pc-windows-msvc\stage0-rustc\x86_64-pc-windows-msvc\release\deps\libindexmap-960edd89f26b597a.rmeta --extern smallvec=C:\Users\${name}\project\rustc\build\x86_64-pc-windows-msvc\stage0-rustc\x86_64-pc-windows-msvc\release\deps\libsmallvec-8c19e1eddb5b7608.rmeta --cfg=bootstrap -Zsymbol-mangling-version=v0 -Zmacro-backtrace -Ctarget-feature=+crt-static -Ztls-model=initial-exec -Zunstable-options -Wrustc::internal -Cprefer-dynamic -Cllvm-args=-import-instr-limit=10 -Z binary-dep-depinfo` (exit code: 0x80000003)
warning: build failed, waiting for other jobs to finish...
error: build failed

@workingjubilee workingjubilee 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 Dec 11, 2021
@camelid
Copy link
Member

camelid commented Dec 11, 2021

Hmm, I wonder if this ICE is related to #91715.

@workingjubilee can you try cherry-picking that PR (it just changes one line) and see if it fixes it?

@workingjubilee
Copy link
Member Author

No love: that doesn't even seem to change the errors in a discernible way.

@Mark-Simulacrum
Copy link
Member

Running this on latest master (229d0a9) does not produce the error above for me with x.py check or x.py build. So potentially this is fixed, or the diff above is incomplete?

Potentially your config.toml might be relevant as well.

@workingjubilee
Copy link
Member Author

huh. it looks like my config.toml is

# Includes one of the default files in src/bootstrap/defaults
profile = "library"
changelog-seen = 2

which is probably wrong, but I am not sure in what way, honestly.

@camelid
Copy link
Member

camelid commented Dec 12, 2021

The profile line essentially copies this into your config:

# These defaults are meant for contributors to the standard library and documentation.
[build]
# When building the standard library, you almost never want to build the compiler itself.
build-stage = 0
test-stage = 0
bench-stage = 0

[rust]
# This greatly increases the speed of rebuilds, especially when there are only minor changes. However, it makes the initial build slightly slower.
incremental = true

[llvm]
# Will download LLVM from CI if available on your platform.
download-ci-llvm = "if-available"

@Mark-Simulacrum
Copy link
Member

Even with that config.toml, I'm still not able to reproduce this on 229d0a9. Can you re-verify, and perhaps paste a full log from x.py, rather than just the ICE? It's not impossible, I suppose, that this is somehow related to incremental.

@workingjubilee
Copy link
Member Author

Huh, entirely possible. Lemme try with a fresh clone on my end.

@workingjubilee
Copy link
Member Author

workingjubilee commented Dec 13, 2021

Huuuh.
Okay, that actually worked. And even though x.py clean and then rebuilding didn't seem to make it "go" before, it clears now (I suspect this is due to Windows and buggy file locking... really gotta switch back to my usual environment). Looks like this is indeed an incremental issue.
Feel free to close this if there's no realistic actions to take here, then.

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