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

Unexpected compiler panic in 2018-05-12 nightly #50707

Closed
jgrillo opened this issue May 13, 2018 · 5 comments
Closed

Unexpected compiler panic in 2018-05-12 nightly #50707

jgrillo opened this issue May 13, 2018 · 5 comments
Assignees
Labels
C-bug Category: This is a bug. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ P-high High priority regression-from-stable-to-nightly Performance or correctness regression from stable to nightly. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@jgrillo
Copy link

jgrillo commented May 13, 2018

I'm getting a panic thread 'main' panicked at 'miri allocation never successfully created', libcore/option.rs:914:5 while trying to compile an actix project using cargo with rustc version 1.27.0-nightly (ff2ac35db 2018-05-12).

This is the invocation with a backtrace and cargo's failure message:

[jgrillo@localhost wordcountrs]$ RUST_BACKTRACE=1 cargo build --release
   Compiling h2 v0.1.6
   Compiling trust-dns-proto v0.3.3
   Compiling tokio-signal v0.1.5
   Compiling actix v0.5.6
   Compiling cookie v0.10.1
thread 'main' panicked at 'miri allocation never successfully created', libcore/option.rs:914:5
stack backtrace:
   0: std::sys::unix::backtrace::tracing::imp::unwind_backtrace
             at libstd/sys/unix/backtrace/tracing/gcc_s.rs:49
   1: std::sys_common::backtrace::print
             at libstd/sys_common/backtrace.rs:71
             at libstd/sys_common/backtrace.rs:59
   2: std::panicking::default_hook::{{closure}}
             at libstd/panicking.rs:211
   3: std::panicking::default_hook
             at libstd/panicking.rs:227
   4: rustc::util::common::panic_hook
   5: std::panicking::rust_panic_with_hook
             at libstd/panicking.rs:467
   6: std::panicking::begin_panic_fmt
             at libstd/panicking.rs:350
   7: rust_begin_unwind
             at libstd/panicking.rs:328
   8: core::panicking::panic_fmt
             at libcore/panicking.rs:71
   9: core::option::expect_failed
             at libcore/option.rs:914
  10: rustc_mir::interpret::const_eval::value_to_const_value
  11: rustc_mir::interpret::const_eval::const_val_field
  12: rustc_mir::hair::pattern::PatternContext::const_to_pat::{{closure}}
  13: <alloc::vec::Vec<T> as alloc::vec::SpecExtend<T, I>>::from_iter
  14: rustc_mir::hair::pattern::PatternContext::const_to_pat
  15: rustc_mir::hair::pattern::PatternContext::lower_path
  16: rustc_mir::hair::pattern::PatternContext::lower_pattern
  17: core::ops::function::impls::<impl core::ops::function::FnOnce<A> for &'a mut F>::call_once
  18: <alloc::vec::Vec<T> as alloc::vec::SpecExtend<T, I>>::from_iter
  19: <alloc::vec::Vec<T> as alloc::vec::SpecExtend<T, I>>::from_iter
  20: <rustc_mir::hair::pattern::check_match::MatchVisitor<'a, 'tcx> as rustc::hir::intravisit::Visitor<'tcx>>::visit_expr
  21: rustc::hir::intravisit::walk_expr
  22: <rustc_mir::hair::pattern::check_match::MatchVisitor<'a, 'tcx> as rustc::hir::intravisit::Visitor<'tcx>>::visit_expr
  23: <rustc_mir::hair::pattern::check_match::MatchVisitor<'a, 'tcx> as rustc::hir::intravisit::Visitor<'tcx>>::visit_expr
  24: <rustc_mir::hair::pattern::check_match::MatchVisitor<'a, 'tcx> as rustc::hir::intravisit::Visitor<'tcx>>::visit_body
  25: rustc::session::Session::track_errors
  26: rustc_mir::hair::pattern::check_match::check_match
  27: rustc::dep_graph::graph::DepGraph::with_task_impl
  28: rustc::ty::context::tls::with_related_context
  29: rustc::ty::maps::plumbing::<impl rustc::ty::context::TyCtxt<'a, 'gcx, 'tcx>>::force_query_with_job
  30: rustc::ty::maps::plumbing::<impl rustc::ty::context::TyCtxt<'a, 'gcx, 'tcx>>::get_query
  31: rustc::hir::intravisit::Visitor::visit_nested_body
  32: rustc::hir::Crate::visit_all_item_likes
  33: rustc_mir::hair::pattern::check_match::check_crate
  34: rustc::util::common::time
  35: rustc::ty::context::tls::enter_context
  36: <std::thread::local::LocalKey<T>>::with
  37: rustc::ty::context::TyCtxt::create_and_enter
  38: rustc_driver::driver::compile_input
  39: rustc_driver::run_compiler_impl
  40: <scoped_tls::ScopedKey<T>>::set
  41: syntax::with_globals
  42: <std::panic::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once
  43: __rust_maybe_catch_panic
             at libpanic_unwind/lib.rs:105
  44: rustc_driver::run
  45: rustc_driver::main
  46: std::rt::lang_start::{{closure}}
  47: std::panicking::try::do_call
             at libstd/rt.rs:59
             at libstd/panicking.rs:310
  48: __rust_maybe_catch_panic
             at libpanic_unwind/lib.rs:105
  49: std::rt::lang_start_internal
             at libstd/panicking.rs:289
             at libstd/panic.rs:374
             at libstd/rt.rs:58
  50: main
  51: __libc_start_main
  52: <unknown>
query stack during panic:
#0 [check_match] processing `hpack::table::index_static`
end of query stack

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/blob/master/CONTRIBUTING.md#bug-reports

note: rustc 1.27.0-nightly (ff2ac35db 2018-05-12) running on x86_64-unknown-linux-gnu

note: compiler flags: -C opt-level=3 --crate-type lib

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

error: Could not compile `h2`.
warning: build failed, waiting for other jobs to finish...
error: build failed

rustc --version --verbose output:

rustc 1.27.0-nightly (ff2ac35db 2018-05-12)
binary: rustc
commit-hash: ff2ac35db93a80b2de5daa4f280bf1503d62c164
commit-date: 2018-05-12
host: x86_64-unknown-linux-gnu
release: 1.27.0-nightly
LLVM version: 6.0

Please let me know if I can provide any more information. Thanks!

@maccam912
Copy link

I just got an identical bug. I'm also using actix-web, had the "miri allocation" message and "could not compile h2". It looks like @jgrillo has this bug report covered, but let me know if I can help out at all too.

@pietroalbini pietroalbini added I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ C-bug Category: This is a bug. regression-from-stable-to-nightly Performance or correctness regression from stable to nightly. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels May 13, 2018
@pietroalbini
Copy link
Member

Thanks for reporting this! This is indeed a regression from stable to nightly, and it happens when trying to compile the h2 crate.

A bisect points at #50249 as the cause of the regression. cc @oli-obk @Zoxc

bors added a commit that referenced this issue May 16, 2018
Fix conversion from Miri Value to ConstValue

This fixes an error compiling the `immeta` 0.3.6 crate. #50707 may be fixed too.

r? @oli-obk
@nikomatsakis nikomatsakis added the P-high High priority label May 17, 2018
@nikomatsakis
Copy link
Contributor

Possibly fixed. Marking as P-high until we verify.

@lnicola
Copy link
Member

lnicola commented May 17, 2018

Fixed for me in last nightly.

@pietroalbini
Copy link
Member

This is fixed on the latest nightly.

volzkzg added a commit to citahub/cita-build that referenced this issue May 17, 2018
rink1969 pushed a commit to citahub/cita that referenced this issue May 24, 2018
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) ❄️ P-high High priority regression-from-stable-to-nightly Performance or correctness regression from stable to nightly. 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

6 participants