Skip to content

miri no longer builds after rust-lang/rust#101333 #101344

Closed
@rust-highfive

Description

@rust-highfive
Contributor

Hello, this is your friendly neighborhood mergebot.
After merging PR #101333, I observed that the tool miri has failing tests.
A follow-up PR to the repository https://github.com/rust-lang/miri is needed to fix the fallout.

cc @matthiaskrgr, do you think you would have time to do the follow-up work?
If so, that would be great!

Activity

RalfJung

RalfJung commented on Sep 2, 2022

@RalfJung
Member

Ah damn it, we keep getting broken so there's still no nightly with Miri. :(

RalfJung

RalfJung commented on Sep 2, 2022

@RalfJung
Member

Building std now ICEs on windows...?

thread 'rustc' panicked at 'range start index 1 out of range for slice of length 0', library\core\src\slice\index.rs:52:5
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

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.65.0-nightly (9ba169a73 2022-09-02) running on x86_64-pc-windows-msvc

note: compiler flags: --crate-type dylib --crate-type rlib -C opt-level=3 -C embed-bitcode=no -C debuginfo=0 -C debug-assertions=on -C debug-assertions=off -C overflow-checks=on -Z force-unstable-if-unmarked -Z tls-model=initial-exec

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

query stack during panic:
#0 [mir_drops_elaborated_and_const_checked] elaborating drops for `sys::windows::fs::<impl at D:\a\rust\rust\library\std\src\sys\windows\fs.rs:278:1: 278:10>::file_attr`
#1 [optimized_mir] optimizing MIR for `sys::windows::fs::<impl at D:\a\rust\rust\library\std\src\sys\windows\fs.rs:278:1: 278:10>::file_attr`
end of query stack
[RUSTC-TIMING] std test:false 5.705
error: could not compile `std`

The same target works fine on my system, so it is host-specific. Sounds like one of the PRs in that rollup is buggy...

compiler-errors

compiler-errors commented on Sep 2, 2022

@compiler-errors
Member

@RalfJung do you have a stack trace for that ICE?

RalfJung

RalfJung commented on Sep 2, 2022

@RalfJung
Member

Nope, I cannot reproduce so all we got is the log from CI. The ICE is here.

RalfJung

RalfJung commented on Sep 2, 2022

@RalfJung
Member

Miri CI cannot reproduce either, not even in a Windows host. It's a 32bit host though.

Would be great if someone with an x86_64 windows host could try to clone the Miri repo and do ./rustup-toolchain HEAD && ./miri test.

tmandry

tmandry commented on Sep 2, 2022

@tmandry
Member

We're seeing a related-looking issue on Fuchsia on the same commit:

https://logs.chromium.org/logs/fuchsia/buildbucket/cr-buildbucket/8804097715115352817/+/u/build/failure_summary

 RUST_BACKTRACE=1 ../../../recipe_cleanup/rust9fky53v8/bin/rustc --color=always --crate-name fuchsia_hyper_test_support ../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs --crate-type rlib --emit=dep-info=obj/src/lib/testing/fuchsia-hyper-test-support/libfuchsia_hyper_test_support.rlib.d,link -Zdep-info-omit-d-target --cfg=__rust_toolchain=\"nkWzzIr653CqEaEbcmzgxh10WYbCeZIvyr4NGPe9ZJgC\" -L gen/zircon/public/sysroot/cpp/lib -Clinker=../../prebuilt/third_party/clang/linux-x64/bin/lld -Clink-arg=--sysroot=gen/zircon/public/sysroot/cpp -Clink-arg=-L../../prebuilt/third_party/clang/linux-x64/bin/../lib/x86_64-unknown-fuchsia -Clink-arg=-L../../prebuilt/third_party/clang/linux-x64/lib/clang/16.0.0/lib/x86_64-unknown-fuchsia -Clink-arg=--pack-dyn-relocs=relr -Clink-arg=-dynamic-linker=ld.so.1 -Clink-arg=--icf=all -Clink-arg=-zrel -Zremap-cwd-prefix=. -Cforce-frame-pointers -Copt-level=0 -Cdebuginfo=2 -Zallow-features= --target x86_64-fuchsia --cap-lints=warn -Wrust-2018-idioms -Dwarnings -Cdebug-assertions=yes -Clink-args=-zstack-size=0x200000 -Cpanic=abort -Cforce-unwind-tables=yes -Zpanic_abort_tests -Dunused_crate_dependencies -Dunused_results -Aunused_results --edition=2021 -o obj/src/lib/testing/fuchsia-hyper-test-support/libfuchsia_hyper_test_support.rlib -Ldependency=obj/src/lib/fuchsia-async -Ldependency=host_x64/obj/src/lib/fuchsia-async-macro -Ldependency=obj/third_party/rust_crates -Ldependency=host_x64/obj/third_party/rust_crates -Ldependency=obj/src/lib/zerocopy -Ldependency=host_x64/obj/src/lib/zerocopy/zerocopy-derive -Ldependency=obj/src/lib/zircon/rust -Ldependency=obj/src/lib/fuchsia-hyper -Ldependency=obj/sdk/fidl/fuchsia.net.name/fuchsia.net.name_rust -Ldependency=obj/src/lib/fidl/rust/fidl -Ldependency=obj/sdk/fidl/fuchsia.net/fuchsia.net_rust -Ldependency=obj/zircon/vdso/zx/zx_rust -Ldependency=obj/sdk/fidl/fuchsia.posix.socket/fuchsia.posix.socket_rust -Ldependency=obj/sdk/fidl/fuchsia.io/fuchsia.io_rust -Ldependency=obj/sdk/fidl/fuchsia.unknown/fuchsia.unknown_rust -Ldependency=obj/sdk/fidl/fuchsia.net.interfaces/fuchsia.net.interfaces_rust -Ldependency=obj/sdk/fidl/fuchsia.hardware.network/fuchsia.hardware.network_rust -Ldependency=obj/sdk/fidl/fuchsia.posix/fuchsia.posix_rust -Ldependency=obj/src/lib/network/fidl_fuchsia_net_ext -Ldependency=obj/src/connectivity/lib/net-types -Ldependency=obj/src/lib/webpki-roots-fuchsia -Ldependency=obj/src/sys/lib/fidl-connector -Ldependency=obj/src/lib/fuchsia-component -Ldependency=obj/sdk/fidl/fuchsia.component/fuchsia.component_rust -Ldependency=obj/sdk/fidl/fuchsia.component.decl/fuchsia.component.decl_rust -Ldependency=obj/sdk/fidl/fuchsia.data/fuchsia.data_rust -Ldependency=obj/sdk/fidl/fuchsia.url/fuchsia.url_rust -Ldependency=obj/sdk/fidl/fuchsia.process/fuchsia.process_rust -Ldependency=obj/sdk/fidl/fuchsia.ldsvc/fuchsia.ldsvc_rust -Ldependency=obj/sdk/fidl/fuchsia.sys/fuchsia.sys_rust -Ldependency=obj/sdk/fidl/fuchsia.mem/fuchsia.mem_rust -Ldependency=obj/src/lib/fdio/rust -Ldependency=obj/sdk/fidl/fuchsia.device/fuchsia.device_rust -Ldependency=obj/src/lib/fuchsia-runtime -Ldependency=obj/src/lib/fuchsia-fs -Ldependency=obj/src/lib/storage/vfs/rust -Ldependency=host_x64/obj/src/lib/storage/vfs/rust/macros -Ldependency=obj/src/lib/trace/rust -Ldependency=obj/src/lib/cstr -Lnative=obj/third_party/rust_crates/compat/ring -Lnative=x64-shared/link_stub -Clink-arg=-Bdynamic -Clink-arg=obj/third_party/rust_crates/compat/ring/libring-core.a -Clink-arg=x64-shared/link_stub/libtrace-engine.so --extern fuchsia_async=obj/src/lib/fuchsia-async/libfuchsia_async.rlib --extern futures=obj/third_party/rust_crates/libfutures-e6516813fcd2ea59.rlib --extern fuchsia_hyper=obj/src/lib/fuchsia-hyper/libfuchsia_hyper.rlib --extern hyper=obj/third_party/rust_crates/libhyper-cc7cc936a1c0e0fb.rlib --extern tokio=obj/third_party/rust_crates/libtokio-93e9171240b81c17.rlib --extern rustls=obj/third_party/rust_crates/librustls-72f8bc3d6c17ed51.rlib --extern tokio_rustls=obj/third_party/rust_crates/libtokio_rustls-16584d9dad632eb3.rlib --extern anyhow=obj/third_party/rust_crates/libanyhow-6015da1b46818404.rlib --extern chrono=obj/third_party/rust_crates/libchrono-5f4599162f3bf073.rlib && ../../prebuilt/third_party/python3/linux-x64/bin/python3.8 -S ../../build/gn/verify_depfile.py -t "//src/lib/testing/fuchsia-hyper-test-support:fuchsia-hyper-test-support.actual" -d obj/src/lib/testing/fuchsia-hyper-test-support/libfuchsia_hyper_test_support.rlib.d ../../src/lib/testing/fuchsia-hyper-test-support/src/fault_injection.rs ../../src/lib/testing/fuchsia-hyper-test-support/src/handler.rs ../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs
error: internal compiler error: no errors encountered even though `delay_span_bug` issued

error: internal compiler error: broken MIR in DropGlue(DefId(2:2764 ~ core[496b]::ptr::drop_in_place), Some(hyper::proto::h1::dispatch::Server<hyper::service::util::ServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:193:48: 193:58], hyper::Body>, hyper::Body>)) (after pass PhaseChange-Runtime(Optimized)) at bb0[0]:
                                Field projection `(*_1).field[0]` specified type `std::pin::Pin<std::boxed::Box<std::option::Option<futures::future::Map<futures::future::Inspect<std::future::from_generator::GenFuture<[static generator@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:98:25: 105:6]>, [closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:199:34: 199:42]>, fn(hyper::Response<hyper::Body>) -> std::result::Result<hyper::Response<hyper::Body>, std::convert::Infallible> {std::result::Result::<hyper::Response<hyper::Body>, std::convert::Infallible>::Ok}>>>>`, but actual type is std::pin::Pin<std::boxed::Box<std::option::Option<<hyper::service::util::ServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:193:48: 193:58], hyper::Body> as hyper::service::http::HttpService<hyper::Body>>::Future>>>
  |
  = note: delayed at compiler/rustc_const_eval/src/transform/validate.rs:127:36

error: internal compiler error: broken MIR in DropGlue(DefId(2:2764 ~ core[496b]::ptr::drop_in_place), Some(hyper::server::server::new_svc::State<std::pin::Pin<std::boxed::Box<dyn AsyncReadWrite>>, std::future::from_generator::GenFuture<[static generator@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:192:24: 210:14]>, hyper::service::util::ServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:193:48: 193:58], hyper::Body>, fuchsia_hyper::Executor, hyper::server::shutdown::GracefulWatcher>)) (after pass PhaseChange-Runtime(Optimized)) at bb4[0]:
                                Field projection `((*_1) as Connected).field[0]` specified type `hyper::common::drain::Watching<hyper::server::conn::upgrades::UpgradeableConnection<std::pin::Pin<std::boxed::Box<dyn AsyncReadWrite>>, hyper::service::util::ServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:193:48: 193:58], hyper::Body>, fuchsia_hyper::Executor>, for<'r> fn(std::pin::Pin<&'r mut hyper::server::conn::upgrades::UpgradeableConnection<std::pin::Pin<std::boxed::Box<dyn AsyncReadWrite>>, hyper::service::util::ServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:193:48: 193:58], hyper::Body>, fuchsia_hyper::Executor>>)>`, but actual type is <hyper::server::shutdown::GracefulWatcher as hyper::server::server::Watcher<std::pin::Pin<std::boxed::Box<dyn AsyncReadWrite>>, hyper::service::util::ServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:193:48: 193:58], hyper::Body>, fuchsia_hyper::Executor>>::Future
  |
  = note: delayed at compiler/rustc_const_eval/src/transform/validate.rs:127:36

error: internal compiler error: broken MIR in DropGlue(DefId(2:2764 ~ core[496b]::ptr::drop_in_place), Some(hyper::server::conn::Connection<std::pin::Pin<std::boxed::Box<dyn AsyncReadWrite>>, hyper::service::util::ServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:193:48: 193:58], hyper::Body>, fuchsia_hyper::Executor>)) (after pass PhaseChange-Runtime(Optimized)) at bb0[0]:
                                Field projection `(*_1).field[0]` specified type `std::option::Option<hyper::server::conn::ProtoServer<std::pin::Pin<std::boxed::Box<dyn AsyncReadWrite>>, hyper::Body, hyper::service::util::ServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:193:48: 193:58], hyper::Body>, fuchsia_hyper::Executor>>`, but actual type is std::option::Option<hyper::server::conn::ProtoServer<std::pin::Pin<std::boxed::Box<dyn AsyncReadWrite>>, <hyper::service::util::ServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:193:48: 193:58], hyper::Body> as hyper::service::http::HttpService<hyper::Body>>::ResBody, hyper::service::util::ServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:193:48: 193:58], hyper::Body>, fuchsia_hyper::Executor>>
  |
  = note: delayed at compiler/rustc_const_eval/src/transform/validate.rs:127:36

error: internal compiler error: broken MIR in DropGlue(DefId(2:2764 ~ core[496b]::ptr::drop_in_place), Some(futures::future::Remote<futures::future::Fuse<futures::future::Map<hyper::server::server::new_svc::NewSvcTask<std::pin::Pin<std::boxed::Box<dyn AsyncReadWrite>>, std::future::from_generator::GenFuture<[static generator@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:192:24: 210:14]>, hyper::service::util::ServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:193:48: 193:58], hyper::Body>, fuchsia_hyper::Executor, hyper::server::shutdown::GracefulWatcher>, [closure@<fuchsia_hyper::Executor as hyper::rt::Executor<hyper::server::server::new_svc::NewSvcTask<std::pin::Pin<std::boxed::Box<dyn AsyncReadWrite>>, std::future::from_generator::GenFuture<[static generator@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:192:24: 210:14]>, hyper::service::util::ServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:193:48: 193:58], hyper::Body>, fuchsia_hyper::Executor, hyper::server::shutdown::GracefulWatcher>>>::execute::{closure#0}]>>>)) (after pass PhaseChange-Runtime(Optimized)) at bb0[0]:
                                Field projection `(*_1).field[0]` specified type `std::option::Option<futures::futures_channel::oneshot::Sender<std::result::Result<(), std::boxed::Box<dyn std::any::Any + std::marker::Send>>>>`, but actual type is std::option::Option<futures::futures_channel::oneshot::Sender<std::result::Result<<futures::future::Fuse<futures::future::Map<hyper::server::server::new_svc::NewSvcTask<std::pin::Pin<std::boxed::Box<dyn AsyncReadWrite>>, std::future::from_generator::GenFuture<[static generator@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:192:24: 210:14]>, hyper::service::util::ServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:193:48: 193:58], hyper::Body>, fuchsia_hyper::Executor, hyper::server::shutdown::GracefulWatcher>, [closure@<fuchsia_hyper::Executor as hyper::rt::Executor<hyper::server::server::new_svc::NewSvcTask<std::pin::Pin<std::boxed::Box<dyn AsyncReadWrite>>, std::future::from_generator::GenFuture<[static generator@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:192:24: 210:14]>, hyper::service::util::ServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:193:48: 193:58], hyper::Body>, fuchsia_hyper::Executor, hyper::server::shutdown::GracefulWatcher>>>::execute::{closure#0}]>> as futures::Future>::Output, std::boxed::Box<(dyn std::any::Any + std::marker::Send + 'static)>>>>
  |
  = note: delayed at compiler/rustc_const_eval/src/transform/validate.rs:127:36

error: internal compiler error: broken MIR in DropGlue(DefId(2:2764 ~ core[496b]::ptr::drop_in_place), Some(futures::future::Remote<futures::future::Fuse<futures::future::UnwrapOrElse<hyper::server::shutdown::Graceful<hyper::server::accept::from_stream::FromStream<std::pin::Pin<std::boxed::Box<dyn futures::Stream<Item = std::result::Result<std::pin::Pin<std::boxed::Box<dyn AsyncReadWrite>>, anyhow::Error>> + std::marker::Send>>>, hyper::service::make::MakeServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:187:40: 187:54]>, futures::future::Map<futures::futures_channel::oneshot::Receiver<()>, [closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:219:29: 219:34]>, fuchsia_hyper::Executor>, [closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:221:29: 221:32]>>>)) (after pass PhaseChange-Runtime(Optimized)) at bb0[0]:
                                Field projection `(*_1).field[0]` specified type `std::option::Option<futures::futures_channel::oneshot::Sender<std::result::Result<(), std::boxed::Box<dyn std::any::Any + std::marker::Send>>>>`, but actual type is std::option::Option<futures::futures_channel::oneshot::Sender<std::result::Result<<futures::future::Fuse<futures::future::UnwrapOrElse<hyper::server::shutdown::Graceful<hyper::server::accept::from_stream::FromStream<std::pin::Pin<std::boxed::Box<dyn futures::Stream<Item = std::result::Result<std::pin::Pin<std::boxed::Box<dyn AsyncReadWrite>>, anyhow::Error>> + std::marker::Send>>>, hyper::service::make::MakeServiceFn<[closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:187:40: 187:54]>, futures::future::Map<futures::futures_channel::oneshot::Receiver<()>, [closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:219:29: 219:34]>, fuchsia_hyper::Executor>, [closure@../../src/lib/testing/fuchsia-hyper-test-support/src/lib.rs:221:29: 221:32]>> as futures::Future>::Output, std::boxed::Box<(dyn std::any::Any + std::marker::Send + 'static)>>>>
  |
  = note: delayed at compiler/rustc_const_eval/src/transform/validate.rs:127:36

thread 'rustc' panicked at 'Box<dyn Any>', compiler/rustc_errors/src/lib.rs:1499:13
stack backtrace:
   0: std::panicking::begin_panic::<rustc_errors::ExplicitBug>
   1: std::panic::panic_any::<rustc_errors::ExplicitBug>
   2: <rustc_errors::HandlerInner as core::ops::drop::Drop>::drop
   3: core::ptr::drop_in_place::<rustc_session::parse::ParseSess>
   4: <alloc::rc::Rc<rustc_session::session::Session> as core::ops::drop::Drop>::drop
   5: core::ptr::drop_in_place::<rustc_interface::interface::Compiler>
   6: rustc_span::with_source_map::<core::result::Result<(), rustc_errors::ErrorGuaranteed>, rustc_interface::interface::create_compiler_and_run<core::result::Result<(), rustc_errors::ErrorGuaranteed>, rustc_driver::run_compiler::{closure#1}>::{closure#1}>
   7: rustc_interface::interface::create_compiler_and_run::<core::result::Result<(), rustc_errors::ErrorGuaranteed>, rustc_driver::run_compiler::{closure#1}>
   8: <scoped_tls::ScopedKey<rustc_span::SessionGlobals>>::set::<rustc_interface::interface::run_compiler<core::result::Result<(), rustc_errors::ErrorGuaranteed>, rustc_driver::run_compiler::{closure#1}>::{closure#0}, core::result::Result<(), rustc_errors::ErrorGuaranteed>>
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

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.65.0-nightly (9ba169a73 2022-09-02) running on x86_64-unknown-linux-gnu

note: compiler flags: --crate-type rlib -Z dep-info-omit-d-target -C linker=../../prebuilt/third_party/clang/linux-x64/bin/lld -C link-arg=--sysroot=gen/zircon/public/sysroot/cpp -C link-arg=-L../../prebuilt/third_party/clang/linux-x64/bin/../lib/x86_64-unknown-fuchsia -C link-arg=-L../../prebuilt/third_party/clang/linux-x64/lib/clang/16.0.0/lib/x86_64-unknown-fuchsia -C link-arg=--pack-dyn-relocs=relr -C link-arg=-dynamic-linker=ld.so.1 -C link-arg=--icf=all -C link-arg=-zrel -Z remap-cwd-prefix=. -C force-frame-pointers -C opt-level=0 -C debuginfo=2 -Z allow-features= -C debug-assertions=yes -C link-args=-zstack-size=0x200000 -C panic=abort -C force-unwind-tables=yes -Z panic_abort_tests -C link-arg=-Bdynamic -C link-arg=obj/third_party/rust_crates/compat/ring/libring-core.a -C link-arg=x64-shared/link_stub/libtrace-engine.so

query stack during panic:
end of query stack
saethlin

saethlin commented on Sep 3, 2022

@saethlin
Member

I'm unable to reproduce the ICE with ./miri test on

Default host: x86_64-pc-windows-msvc

miri (directory override for 'C:\Users\kimoc\miri')
rustc 1.65.0-nightly (9ba169a73 2022-09-02)

Btw the advice of ./rustup-toolchain HEAD results in a build error, because Miri was broken again by another PR.

Noratrieb

Noratrieb commented on Sep 3, 2022

@Noratrieb
Member

This does look like my PR causes this.

17 remaining items

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

A-miriArea: The miri toolC-bugCategory: This is a bug.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

    Participants

    @RalfJung@oli-obk@tmandry@compiler-errors@rust-highfive

    Issue actions

      `miri` no longer builds after rust-lang/rust#101333 · Issue #101344 · rust-lang/rust