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 on building Redox #32783

Closed
Viknet opened this issue Apr 6, 2016 · 12 comments
Closed

Compiler panic on building Redox #32783

Viknet opened this issue Apr 6, 2016 · 12 comments
Labels
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

@Viknet
Copy link

Viknet commented Apr 6, 2016

I tried to build current Redox OS HEAD with last available rustc-nightly and got an ICE.

Meta

rustc --version --verbose:

rustc 1.9.0-nightly (241a9d0dd 2016-04-05)
binary: rustic
commit-hash: 241a9d0ddf99fd40d273c615e9b1e8ce6052d94a
commit-date: 2016-04-05
host: x86_64-apple-darwin
release: 1.9.0-nightly

Backtrace:

❯❯❯ make qemu                                                                                                                                                ⏎ master
RUST_BACKTRACE=1 rustc --target=i386-unknown-redox.json -L build/i386-unknown-redox/debug -C no-prepopulate-passes -C no-stack-check -C opt-level=2 -Z no-landing-pads -A dead_code -C ar=i386-elf-ar -C linker=i386-elf-gcc -o build/i386-unknown-redox/debug/libstd.rlib libstd/src/lib.rs -L native=libc/lib/
error: internal compiler error: ../src/librustc_metadata/encoder.rs:220: encode_symbol: id not found 49044
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: run with `RUST_BACKTRACE=1` for a backtrace
thread 'rustc' panicked at 'Box<Any>', ../src/libsyntax/errors/mod.rs:575
stack backtrace:
   1:        0x110b66978 - std::sys::backtrace::tracing::imp::write::h714760a4c8c0cdd8
   2:        0x110b72dc5 - std::panicking::default_hook::_$u7b$$u7b$closure$u7d$$u7d$::hff309ab1d83ffd90
   3:        0x110b728fd - std::panicking::default_hook::h08ad3bb09872855b
   4:        0x110b36196 - std::sys_common::unwind::begin_unwind_inner::h406d5f1a330b854b
   5:        0x110113cea - std::sys_common::unwind::begin_unwind::hb10e2b9ef92fd4a6
   6:        0x110113b19 - syntax::errors::Handler::bug::h112319de7e910c9e
   7:        0x10f494c9c - rustc::session::opt_span_bug_fmt::_$u7b$$u7b$closure$u7d$$u7d$::h2c926d3e6a2eb430
   8:        0x10f494b01 - rustc::session::opt_span_bug_fmt::he2c7fbeab8bf3d1d
   9:        0x10f4a36a9 - rustc::session::bug_fmt::h9f67e9cd7aa5a073
  10:        0x10cab64f0 - rustc_metadata::encoder::encode_symbol::h165ac8a162612975
  11:        0x10cac310b - rustc_metadata::encoder::encode_info_for_item::hfab1a46f9bf30c3c
  12:        0x10cac9c71 - rustc::front::map::Map::with_path_next::h6ba163a93b4eab46
  13:        0x10cac9ca4 - rustc::front::map::Map::with_path_next::h6ba163a93b4eab46
  14:        0x10cac9ca4 - rustc::front::map::Map::with_path_next::h6ba163a93b4eab46
  15:        0x10caccd4e - _<encoder..EncodeVisitor<'a, 'b, 'c, 'tcx> as rustc_front..intravisit..Visitor<'tcx>>::visit_item::h1cde6db68ffd78b8
  16:        0x10cad3f5d - rustc_metadata::encoder::encode_metadata_inner::hcfb24759120a6c88
  17:        0x10cacfb19 - rustc_metadata::encoder::encode_metadata::ha3e422357afb6bf6
  18:        0x10cb2c07f - rustc_metadata::csearch::_<impl rustc..middle..cstore..CrateStore<'tcx> for cstore..CStore>::encode_metadata::h88a2f338ac9ea48a
  19:        0x10ccafee2 - rustc_trans::base::trans_crate::_$u7b$$u7b$closure$u7d$$u7d$::h6042c55692ac48ec
  20:        0x10cca1dfd - rustc_trans::base::trans_crate::h45d3e3b1384148fb
  21:        0x10c24fce0 - rustc_driver::driver::phase_4_translate_to_llvm::h8d5ab3a4d94eae6a
  22:        0x10c24e434 - rustc_driver::driver::compile_input::_$u7b$$u7b$closure$u7d$$u7d$::hd32acfaba89541b2
  23:        0x10c24b02d - rustc_driver::driver::phase_3_run_analysis_passes::_$u7b$$u7b$closure$u7d$$u7d$::h1692b932d4d7b15b
  24:        0x10c2451a5 - rustc::ty::context::TyCtxt::create_and_enter::h926ea4fe45f15d00
  25:        0x10c241ba5 - rustc_driver::driver::phase_3_run_analysis_passes::h3c035e5cf4758407
  26:        0x10c215af1 - rustc_driver::driver::compile_input::h650fe5b01cb8d74d
  27:        0x10c1fc04f - rustc_driver::run_compiler::h68d23e0e9b7b247d
  28:        0x10c1f93e2 - std::sys_common::unwind::try::try_fn::h67fde221a73148bc
  29:        0x110b63fdb - __rust_try
  30:        0x110b63f63 - std::sys_common::unwind::inner_try::h4e97625a08807651
  31:        0x10c1f9c79 - _<F as std..boxed..FnBox<A>>::call_box::hc8936fa120642c49
  32:        0x110b71c88 - std::sys::thread::Thread::new::thread_start::h74af400293164137
  33:     0x7fff9f86399c - _pthread_body
  34:     0x7fff9f863919 - _pthread_start

make: *** [build/i386-unknown-redox/debug/libstd.rlib] Error 101
@jackpot51
Copy link
Contributor

We are getting this in Redox travis too:

https://travis-ci.org/redox-os/redox/builds/121316042

It looks like it affects OS X and FreeBSD as well as Linux

https://github.com/redox-os/redox/issues/606#issuecomment-206649111

@Viknet
Copy link
Author

Viknet commented Apr 7, 2016

Older version of rustc doesn't have this error:
rustc --version --verbose

rustc 1.9.0-nightly (e1195c24b 2016-03-31)
binary: rustc
commit-hash: e1195c24bb567019d7cdc65bf5a4c642e38475d1
commit-date: 2016-03-31
host: x86_64-apple-darwin
release: 1.9.0-nightly

@johalun
Copy link

johalun commented Apr 7, 2016

Got problems here as well.

JMBA:redox johannes$ rustc -V
rustc 1.9.0-nightly (241a9d0dd 2016-04-05)
error: internal compiler error: ../src/librustc_metadata/encoder.rs:220: encode_symbol: id not found 49044
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: run with RUST_BACKTRACE=1 for a backtrace
thread 'rustc' panicked at 'Box<Any>', ../src/libsyntax/errors/mod.rs:575
stack backtrace:
   1:        0x10f734978 - std::sys::backtrace::tracing::imp::write::h714760a4c8c0cdd8
   2:        0x10f740dc5 - std::panicking::defaulthook::$u7b$$u7b$closure$u7d$$u7d$::hff309ab1d83ffd90
   3:        0x10f7408fd - std::panicking::default_hook::h08ad3bb09872855b
   4:        0x10f704196 - std::sys_common::unwind::begin_unwind_inner::h406d5f1a330b854b
   5:        0x10ece5cea - std::sys_common::unwind::begin_unwind::hb10e2b9ef92fd4a6
   6:        0x10ece5b19 - syntax::errors::Handler::bug::h112319de7e910c9e
   7:        0x10e072c9c - rustc::session::opt_span_bugfmt::$u7b$$u7b$closure$u7d$$u7d$::h2c926d3e6a2eb430
   8:        0x10e072b01 - rustc::session::opt_span_bug_fmt::he2c7fbeab8bf3d1d
   9:        0x10e0816a9 - rustc::session::bug_fmt::h9f67e9cd7aa5a073
  10:        0x10b68a4f0 - rustc_metadata::encoder::encode_symbol::h165ac8a162612975
  11:        0x10b69710b - rustc_metadata::encoder::encode_info_for_item::hfab1a46f9bf30c3c
  12:        0x10b69dc71 - rustc::front::map::Map::with_path_next::h6ba163a93b4eab46
  13:        0x10b69dca4 - rustc::front::map::Map::with_path_next::h6ba163a93b4eab46
  14:        0x10b69dca4 - rustc::front::map::Map::with_pathnext::h6ba163a93b4eab46
  15:        0x10b6a0d4e - <encoder..EncodeVisitor<'a, 'b, 'c, 'tcx> as rustc_front..intravisit..Visitor<'tcx>>::visit_item::h1cde6db68ffd78b8
  16:        0x10b6a7f5d - rustc_metadata::encoder::encode_metadata_inner::hcfb24759120a6c88
  17:        0x10b6a3b19 - rustc_metadata::encoder::encode_metadata::ha3e422357afb6bf6
  18:        0x10b70007f - rustcmetadata::csearch::<impl rustc..middle..cstore..CrateStore<'tcx> for cstore..CStore>::encode_metadata::h88a2f338ac9ea48a
  19:        0x10b885ee2 - rustc_trans::base::transcrate::$u7b$$u7b$closure$u7d$$u7d$::h6042c55692ac48ec
  20:        0x10b877dfd - rustc_trans::base::trans_crate::h45d3e3b1384148fb
  21:        0x10ae1cce0 - rustc_driver::driver::phase_4_translate_to_llvm::h8d5ab3a4d94eae6a
  22:        0x10ae1b434 - rustc_driver::driver::compileinput::$u7b$$u7b$closure$u7d$$u7d$::hd32acfaba89541b2
  23:        0x10ae1802d - rustc_driver::driver::phase_3_run_analysispasses::$u7b$$u7b$closure$u7d$$u7d$::h1692b932d4d7b15b
  24:        0x10ae121a5 - rustc::ty::context::TyCtxt::create_and_enter::h926ea4fe45f15d00
  25:        0x10ae0eba5 - rustc_driver::driver::phase_3_run_analysis_passes::h3c035e5cf4758407
  26:        0x10ade2af1 - rustc_driver::driver::compile_input::h650fe5b01cb8d74d
  27:        0x10adc904f - rustc_driver::run_compiler::h68d23e0e9b7b247d
  28:        0x10adc63e2 - std::sys_common::unwind::try::try_fn::h67fde221a73148bc
  29:        0x10f731fdb - __rust_try
  30:        0x10f731f63 - std::sys_common::unwind::innertry::h4e97625a08807651
  31:        0x10adc6c79 - <F as std..boxed..FnBox<A>>::call_box::hc8936fa120642c49
  32:        0x10f73fc88 - std::sys::thread::Thread::new::thread_start::h74af400293164137
  33:     0x7fff9302199c - _pthread_body
  34:     0x7fff93021919 - _pthread_start

make: * [build/i386-unknown-redox/debug/libstd.rlib] Error 101

@johalun
Copy link

johalun commented Apr 7, 2016

JMBA:redox johannes$ multirust override nightly-2016-04-05
...
JMBA:redox johannes$ rustc -V
rustc 1.9.0-nightly (600dc3552 2016-04-04)

make all in redox succeeds

JMBA:redox johannes$ multirust override nightly-2016-04-06
...
JMBA:redox johannes$ rustc -V
rustc 1.9.0-nightly (241a9d0dd 2016-04-05)

make all in redox fails

@arielb1 arielb1 added I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ I-nominated regression-from-stable-to-nightly Performance or correctness regression from stable to nightly. labels Apr 7, 2016
@pthariensflame
Copy link
Contributor

Same here. rustc -V responds with rustc 1.9.0-nightly (7979dd608 2016-04-07) and make all produces:

mkdir -p build/i386-unknown-redox/debug
RUST_BACKTRACE=1 rustc --target=i386-unknown-redox.json -L build/i386-unknown-redox/debug -C no-prepopulate-passes -C no-stack-check -C opt-level=2 -Z no-landing-pads -A dead_code -C ar=i386-elf-ar -C linker=i386-elf-gcc -o build/i386-unknown-redox/debug/libcore.rlib rust/src/libcore/lib.rs
RUST_BACKTRACE=1 rustc --target=i386-unknown-redox.json -L build/i386-unknown-redox/debug -C no-prepopulate-passes -C no-stack-check -C opt-level=2 -Z no-landing-pads -A dead_code -C ar=i386-elf-ar -C linker=i386-elf-gcc -o build/i386-unknown-redox/debug/libio.rlib crates/io/lib.rs
RUST_BACKTRACE=1 rustc --target=i386-unknown-redox.json -L build/i386-unknown-redox/debug -C no-prepopulate-passes -C no-stack-check -C opt-level=2 -Z no-landing-pads -A dead_code -C ar=i386-elf-ar -C linker=i386-elf-gcc -o build/i386-unknown-redox/debug/liballoc_system.rlib liballoc_system/lib.rs
RUST_BACKTRACE=1 rustc --target=i386-unknown-redox.json -L build/i386-unknown-redox/debug -C no-prepopulate-passes -C no-stack-check -C opt-level=2 -Z no-landing-pads -A dead_code -C ar=i386-elf-ar -C linker=i386-elf-gcc -o build/i386-unknown-redox/debug/liballoc.rlib rust/src/liballoc/lib.rs
RUST_BACKTRACE=1 rustc --target=i386-unknown-redox.json -L build/i386-unknown-redox/debug -C no-prepopulate-passes -C no-stack-check -C opt-level=2 -Z no-landing-pads -A dead_code -C ar=i386-elf-ar -C linker=i386-elf-gcc -o build/i386-unknown-redox/debug/librustc_unicode.rlib rust/src/librustc_unicode/lib.rs
RUST_BACKTRACE=1 rustc --target=i386-unknown-redox.json -L build/i386-unknown-redox/debug -C no-prepopulate-passes -C no-stack-check -C opt-level=2 -Z no-landing-pads -A dead_code -C ar=i386-elf-ar -C linker=i386-elf-gcc -o build/i386-unknown-redox/debug/libcollections.rlib rust/src/libcollections/lib.rs
RUST_BACKTRACE=1 rustc --target=i386-unknown-redox.json -L build/i386-unknown-redox/debug -C no-prepopulate-passes -C no-stack-check -C opt-level=2 -Z no-landing-pads -A dead_code -C ar=i386-elf-ar -C linker=i386-elf-gcc -o build/i386-unknown-redox/debug/librand.rlib rust/src/librand/lib.rs
RUST_BACKTRACE=1 rustc --target=i386-unknown-redox.json -L build/i386-unknown-redox/debug -C no-prepopulate-passes -C no-stack-check -C opt-level=2 -Z no-landing-pads -A dead_code -C ar=i386-elf-ar -C linker=i386-elf-gcc -o build/i386-unknown-redox/debug/libsystem.rlib crates/system/lib.rs
RUST_BACKTRACE=1 rustc --target=i386-unknown-redox.json -L build/i386-unknown-redox/debug -C no-prepopulate-passes -C no-stack-check -C opt-level=2 -Z no-landing-pads -A dead_code -C ar=i386-elf-ar -C linker=i386-elf-gcc -o build/i386-unknown-redox/debug/libstd.rlib libstd/src/lib.rs -L native=libc/lib/
error: internal compiler error: ../src/librustc_metadata/encoder.rs:218: encode_symbol: id not found 49044
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: run with `RUST_BACKTRACE=1` for a backtrace
thread 'rustc' panicked at 'Box<Any>', ../src/libsyntax/errors/mod.rs:575
stack backtrace:
   1:        0x10b8e4838 - std::sys::backtrace::tracing::imp::write::h714760a4c8c0cdd8
   2:        0x10b8f0c75 - std::panicking::default_hook::_$u7b$$u7b$closure$u7d$$u7d$::hff309ab1d83ffd90
   3:        0x10b8f07af - std::panicking::default_hook::h08ad3bb09872855b
   4:        0x10b8b5396 - std::sys_common::unwind::begin_unwind_inner::h406d5f1a330b854b
   5:        0x10aeadc3a - std::sys_common::unwind::begin_unwind::hb10e2b9ef92fd4a6
   6:        0x10aeada69 - syntax::errors::Handler::bug::h112319de7e910c9e
   7:        0x10a26babc - rustc::session::opt_span_bug_fmt::_$u7b$$u7b$closure$u7d$$u7d$::h2c926d3e6a2eb430
   8:        0x10a26b921 - rustc::session::opt_span_bug_fmt::he2c7fbeab8bf3d1d
   9:        0x10a282119 - rustc::session::bug_fmt::h9f67e9cd7aa5a073
  10:        0x10754e9c0 - rustc_metadata::encoder::encode_symbol::h165ac8a162612975
  11:        0x10755a1d3 - rustc_metadata::encoder::encode_info_for_item::h60f93cd3dd34a5cf
  12:        0x10756a42d - rustc_metadata::encoder::encode_metadata_inner::ha8580aa6ef04664a
  13:        0x107565fe9 - rustc_metadata::encoder::encode_metadata::h4120aac9f1041ba6
  14:        0x1075c1a1f - rustc_metadata::csearch::_<impl rustc..middle..cstore..CrateStore<'tcx> for cstore..CStore>::encode_metadata::he92619b644b6d919
  15:        0x107947262 - rustc_trans::base::trans_crate::_$u7b$$u7b$closure$u7d$$u7d$::h6042c55692ac48ec
  16:        0x107939f0d - rustc_trans::base::trans_crate::h45d3e3b1384148fb
  17:        0x106fcf3aa - rustc_driver::driver::phase_4_translate_to_llvm::h8d5ab3a4d94eae6a
  18:        0x106fcdb5c - rustc_driver::driver::compile_input::_$u7b$$u7b$closure$u7d$$u7d$::hd32acfaba89541b2
  19:        0x106fca4ed - rustc_driver::driver::phase_3_run_analysis_passes::_$u7b$$u7b$closure$u7d$$u7d$::h8148bf3bd7eb17b2
  20:        0x106fc40a5 - rustc::ty::context::TyCtxt::create_and_enter::h963727672a0d2ef1
  21:        0x106fc0aac - rustc_driver::driver::phase_3_run_analysis_passes::h035bf2dff707c080
  22:        0x106f946e1 - rustc_driver::driver::compile_input::h650fe5b01cb8d74d
  23:        0x106f7aeff - rustc_driver::run_compiler::h68d23e0e9b7b247d
  24:        0x106f78292 - std::sys_common::unwind::try::try_fn::h67fde221a73148bc
  25:        0x10b8e1fcb - __rust_try
  26:        0x10b8e1f53 - std::sys_common::unwind::inner_try::h4e97625a08807651
  27:        0x106f78b29 - _<F as std..boxed..FnBox<A>>::call_box::hc8936fa120642c49
  28:        0x10b8efb48 - std::sys::thread::Thread::new::thread_start::h74af400293164137
  29:     0x7fff8626f99c - _pthread_body
  30:     0x7fff8626f919 - _pthread_start

Makefile:434: recipe for target 'build/i386-unknown-redox/debug/libstd.rlib' failed
make: *** [build/i386-unknown-redox/debug/libstd.rlib] Error 101

Current redox commit is 53146f4ee9e5030b467990baae214c3ebeb37c98.

@joeabbey
Copy link

joeabbey commented Apr 9, 2016

FWIW, also seeing the above reported issue

RUST_BACKTRACE=1 rustc --target=i386-unknown-redox.json -L build/i386-unknown-redox/debug -C no-prepopulate-passes -C no-stack-check -C opt-level=2 -Z no-landing-pads -A dead_code -C ar=i386-elf-ar -C linker=i386-elf-gcc -o build/i386-unknown-redox/debug/libstd.rlib libstd/src/lib.rs -L native=libc/lib/
error: internal compiler error: ../src/librustc_metadata/encoder.rs:218: encode_symbol: id not found 49044
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: run with `RUST_BACKTRACE=1` for a backtrace
thread 'rustc' panicked at 'Box<Any>', ../src/libsyntax/errors/mod.rs:575
stack backtrace:
   1:        0x11252d838 - std::sys::backtrace::tracing::imp::write::h714760a4c8c0cdd8
   2:        0x112539c75 - std::panicking::default_hook::_$u7b$$u7b$closure$u7d$$u7d$::hff309ab1d83ffd90
   3:        0x1125397af - std::panicking::default_hook::h08ad3bb09872855b
   4:        0x1124fe396 - std::sys_common::unwind::begin_unwind_inner::h406d5f1a330b854b
   5:        0x111b06c3a - std::sys_common::unwind::begin_unwind::hb10e2b9ef92fd4a6
   6:        0x111b06a69 - syntax::errors::Handler::bug::h112319de7e910c9e
   7:        0x110ed6abc - rustc::session::opt_span_bug_fmt::_$u7b$$u7b$closure$u7d$$u7d$::h2c926d3e6a2eb430
   8:        0x110ed6921 - rustc::session::opt_span_bug_fmt::he2c7fbeab8bf3d1d
   9:        0x110eed119 - rustc::session::bug_fmt::h9f67e9cd7aa5a073
  10:        0x10e1c59c0 - rustc_metadata::encoder::encode_symbol::h165ac8a162612975
  11:        0x10e1d11d3 - rustc_metadata::encoder::encode_info_for_item::h60f93cd3dd34a5cf
  12:        0x10e1e142d - rustc_metadata::encoder::encode_metadata_inner::ha8580aa6ef04664a
  13:        0x10e1dcfe9 - rustc_metadata::encoder::encode_metadata::h4120aac9f1041ba6
  14:        0x10e238a1f - rustc_metadata::csearch::_<impl rustc..middle..cstore..CrateStore<'tcx> for cstore..CStore>::encode_metadata::he92619b644b6d919
  15:        0x10e5bd262 - rustc_trans::base::trans_crate::_$u7b$$u7b$closure$u7d$$u7d$::h6042c55692ac48ec
  16:        0x10e5aff0d - rustc_trans::base::trans_crate::h45d3e3b1384148fb
  17:        0x10dc4d3aa - rustc_driver::driver::phase_4_translate_to_llvm::h8d5ab3a4d94eae6a
  18:        0x10dc4bb5c - rustc_driver::driver::compile_input::_$u7b$$u7b$closure$u7d$$u7d$::hd32acfaba89541b2
  19:        0x10dc484ed - rustc_driver::driver::phase_3_run_analysis_passes::_$u7b$$u7b$closure$u7d$$u7d$::h8148bf3bd7eb17b2
  20:        0x10dc420a5 - rustc::ty::context::TyCtxt::create_and_enter::h963727672a0d2ef1
  21:        0x10dc3eaac - rustc_driver::driver::phase_3_run_analysis_passes::h035bf2dff707c080
  22:        0x10dc126e1 - rustc_driver::driver::compile_input::h650fe5b01cb8d74d
  23:        0x10dbf8eff - rustc_driver::run_compiler::h68d23e0e9b7b247d
  24:        0x10dbf6292 - std::sys_common::unwind::try::try_fn::h67fde221a73148bc
  25:        0x11252afcb - __rust_try
  26:        0x11252af53 - std::sys_common::unwind::inner_try::h4e97625a08807651
  27:        0x10dbf6b29 - _<F as std..boxed..FnBox<A>>::call_box::hc8936fa120642c49
  28:        0x112538b48 - std::sys::thread::Thread::new::thread_start::h74af400293164137
  29:     0x7fff8f80199c - _pthread_body
  30:     0x7fff8f801919 - _pthread_start

@nikomatsakis
Copy link
Contributor

What is the simplest way for me to reproduce this problem? Does anyone have a narrowed test case of any kind? The instructions at https://github.com/redox-os/redox seem complex (run some script, run qemu etc) -- it'd be great if there were some rust file I could build without all those steps. Any tips?

@Viknet
Copy link
Author

Viknet commented Apr 12, 2016

I'm sure, you can just clone Redox repo (git clone git@github.com:redox-os/redox.git --origin upstream --recursive; git submodule update --recursive --init), install nasm and try to build project (make all).
It will fail pretty early on compiling redox/libstd.

@pmarcelll
Copy link
Contributor

Based on @yohanesu75's comment, I examined the commits between the two nightlies, and the most suspicious was #32742. I've built a version of rustc based on e8ab71f (right before the merge), compiled Redox succesfully, built another version based on 953c3b5 (merge commit of #32742), with which I was able to reproduce the ICE.

cc @eddyb

@jackpot51
Copy link
Contributor

Very interesting @pmarcelll. I am working to find the code in libstd that triggers it

@jackpot51
Copy link
Contributor

I found it, it is alloc_system.rs

Trying to find a fix, the file can be seen here: https://github.com/redox-os/redox/blob/master/libstd/src/alloc_system.rs

@eddyb
Copy link
Member

eddyb commented Apr 14, 2016

@pmarcelll I see what the problem is. Writing the test is going to be the tricky part, I believe I need two extern { fn ... } items using the same symbol, exported from the crate and used in another crate.

Manishearth added a commit to Manishearth/rust that referenced this issue Apr 15, 2016
trans: always register an item's symbol, even if duplicated.

Fixes rust-lang#32783 which was introduced by not always registering item symbols in rust-lang#32742.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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

9 participants