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

Compiler panic when building rust-mozjs test (index out of bounds) #41484

Closed
jdm opened this issue Apr 23, 2017 · 3 comments
Closed

Compiler panic when building rust-mozjs test (index out of bounds) #41484

jdm opened this issue Apr 23, 2017 · 3 comments
Labels
A-MIR Area: Mid-level IR (MIR) - https://blog.rust-lang.org/2016/04/19/MIR.html I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ regression-from-stable-to-nightly Performance or correctness regression from stable to nightly.

Comments

@jdm
Copy link
Contributor

jdm commented Apr 23, 2017

This appeared at some point between the 4/18 and 4/21 nightlies.

     Running `rustc --crate-name enumerate tests/enumerate.rs --emit=dep-info,link -C debuginfo=2 --test -C metadata=592f1c2a37b4b9d5 -C extra-filename=-592f1c2a37b4b9d5 --out-dir /home/travis/build/servo/rust-mozjs/target/debug/deps -L dependency=/home/travis/build/servo/rust-mozjs/target/debug/deps --extern num_traits=/home/travis/build/servo/rust-mozjs/target/debug/deps/libnum_traits-a8c1b7cdefa880e5.rlib --extern mozjs_sys=/home/travis/build/servo/rust-mozjs/target/debug/deps/libmozjs_sys-cb584c4573e7973b.rlib --extern libc=/home/travis/build/servo/rust-mozjs/target/debug/deps/liblibc-40c5d4ad7fb59dec.rlib --extern log=/home/travis/build/servo/rust-mozjs/target/debug/deps/liblog-b8e0bbfdccaf7d7a.rlib --extern heapsize=/home/travis/build/servo/rust-mozjs/target/debug/deps/libheapsize-d98feb857df5216d.rlib --extern lazy_static=/home/travis/build/servo/rust-mozjs/target/debug/deps/liblazy_static-18005fa1be5dd889.rlib --extern js=/home/travis/build/servo/rust-mozjs/target/debug/deps/libjs-a705977d881207be.rlib -L native=/home/travis/build/servo/rust-mozjs/target/debug/build/js-98e44ff34f2dc83e/out/lib -L native=/home/travis/build/servo/rust-mozjs/target/debug/build/mozjs_sys-b28f1349c5b308d2/out/js/src -L native=/usr/lib/x86_64-linux-gnu`

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

thread 'rustc' panicked at 'index out of bounds: the len is 8 but the index is 18446744073709551615', /checkout/src/libcollections/vec.rs:1488

note: Run with `RUST_BACKTRACE=1` for a backtrace.

error: Could not compile `js`.

Caused by:

  process didn't exit successfully: `rustc --crate-name enumerate tests/enumerate.rs --emit=dep-info,link -C debuginfo=2 --test -C metadata=592f1c2a37b4b9d5 -C extra-filename=-592f1c2a37b4b9d5 --out-dir /home/travis/build/servo/rust-mozjs/target/debug/deps -L dependency=/home/travis/build/servo/rust-mozjs/target/debug/deps --extern num_traits=/home/travis/build/servo/rust-mozjs/target/debug/deps/libnum_traits-a8c1b7cdefa880e5.rlib --extern mozjs_sys=/home/travis/build/servo/rust-mozjs/target/debug/deps/libmozjs_sys-cb584c4573e7973b.rlib --extern libc=/home/travis/build/servo/rust-mozjs/target/debug/deps/liblibc-40c5d4ad7fb59dec.rlib --extern log=/home/travis/build/servo/rust-mozjs/target/debug/deps/liblog-b8e0bbfdccaf7d7a.rlib --extern heapsize=/home/travis/build/servo/rust-mozjs/target/debug/deps/libheapsize-d98feb857df5216d.rlib --extern lazy_static=/home/travis/build/servo/rust-mozjs/target/debug/deps/liblazy_static-18005fa1be5dd889.rlib --extern js=/home/travis/build/servo/rust-mozjs/target/debug/deps/libjs-a705977d881207be.rlib -L native=/home/travis/build/servo/rust-mozjs/target/debug/build/js-98e44ff34f2dc83e/out/lib -L native=/home/travis/build/servo/rust-mozjs/target/debug/build/mozjs_sys-b28f1349c5b308d2/out/js/src -L native=/usr/lib/x86_64-linux-gnu` (exit code: 101)
@jdm jdm added the I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ label Apr 23, 2017
@jdm jdm changed the title Compiler panic when building rust-mozjs test Compiler panic when building rust-mozjs test (index out of bounds) Apr 23, 2017
@jdm
Copy link
Contributor Author

jdm commented Apr 24, 2017

$ RUST_BACKTRACE=1 cargo build --test enumerate

thread 'rustc' panicked at 'index out of bounds: the len is 8 but the index is 18446744073709551615', src/libcollections/vec.rs:1488
stack backtrace:
   0: std::sys::imp::backtrace::tracing::imp::unwind_backtrace
   1: std::panicking::default_hook::{{closure}}
   2: std::panicking::default_hook
   3: std::panicking::rust_panic_with_hook
   4: std::panicking::begin_panic
   5: std::panicking::begin_panic_fmt
   6: rust_begin_unwind
   7: core::panicking::panic_fmt
   8: core::panicking::panic_bounds_check
   9: rustc::ty::AdtDef::discriminant_for_variant
  10: rustc_trans::mir::rvalue::<impl rustc_trans::mir::MirContext<'a, 'tcx>>::trans_rvalue
  11: rustc_trans::mir::block::<impl rustc_trans::mir::MirContext<'a, 'tcx>>::trans_block
  12: rustc_trans::mir::trans_mir
  13: rustc_trans::trans_item::TransItem::define
  14: rustc_trans::base::trans_crate
  15: rustc_driver::driver::phase_4_translate_to_llvm
  16: rustc_driver::driver::compile_input::{{closure}}
  17: rustc_driver::driver::phase_3_run_analysis_passes::{{closure}}
  18: rustc::ty::context::TyCtxt::create_and_enter
  19: rustc_driver::driver::phase_3_run_analysis_passes
  20: rustc_driver::driver::compile_input
  21: rustc_driver::run_compiler
  22: std::panicking::try::do_call
  23: __rust_maybe_catch_panic
  24: <F as alloc::boxed::FnBox<A>>::call_box
  25: std::sys::imp::thread::Thread::new::thread_start
  26: _pthread_body
  27: _pthread_start

@jdm jdm added A-MIR Area: Mid-level IR (MIR) - https://blog.rust-lang.org/2016/04/19/MIR.html regression-from-stable-to-nightly Performance or correctness regression from stable to nightly. labels Apr 24, 2017
@SimonSapin
Copy link
Contributor

Possibly duplicate of #41394, and fixed in #41408.

@eddyb
Copy link
Member

eddyb commented Apr 24, 2017

@SimonSapin Identical message and backtrace, definitely a dupe.

@eddyb eddyb closed this as completed Apr 24, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-MIR Area: Mid-level IR (MIR) - https://blog.rust-lang.org/2016/04/19/MIR.html I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ regression-from-stable-to-nightly Performance or correctness regression from stable to nightly.
Projects
None yet
Development

No branches or pull requests

3 participants