Skip to content

ICE rustc 1.26.2 'specified instant was later than self' #51648

Closed
@ncoish

Description

@ncoish

After ~2 weeks of continuously building our project without fail, our Windows build machines (2 of them) began throwing an error of this kind, while building dependencies:

thread 'rustc' panicked at 'specified instant was later than self', libcore\option.rs:916:5

 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.26.2 (594fb253c 2018-06-01) running on i686-pc-windows-msvc
 
 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 `ws`.

Each time this failure occurred it was on a different dependency of the project. It's also worth noting that this failure did not occur on every build, but it was very frequent. The failure occurs using both i686-pc-windows-msvc and x86_64-pc-windows-msvc.

A very similar issue was reported in rustc 1.23.0: #47684

Restarting the affected build machines seems to have stopped the issue from occurring, at least temporarily.

If there's anything I can do to help diagnose/solve this problem, I'm eager to jump in.

Meta

rustc --version --verbose:
rustc 1.26.2 (594fb25 2018-06-01)
binary: rustc
commit-hash: 594fb25
commit-date: 2018-06-01
host: i686-pc-windows-msvc
release: 1.26.2
LLVM version: 6.0

Backtrace:

    0: <i32 as std::sys::windows::net::IsMinusOne>::is_minus_one
    1: std::panicking::take_hook
    2: std::panicking::take_hook
    3: rustc::ty::maps::on_disk_cache::__ty_decoder_impl::<impl serialize::serialize::Decoder for rustc::ty::maps::on_disk_cache::CacheDecoder<'a, 'tcx, 'x>>::read_str
    4: std::panicking::begin_panic_fmt
    5: rust_begin_unwind
    6: core::panicking::panic_fmt
    7: core::option::expect_failed
    8: <std::ffi::c_str::IntoStringError as core::fmt::Debug>::fmt
    9: std::time::Instant::elapsed
   10: rustc_trans_utils::link::invalid_output_for_target
   11: rustc_trans_utils::symbol_names::provide
   12: rustc::dep_graph::graph::DepGraph::assert_ignored
   13: rustc::ty::maps::<impl rustc::ty::maps::queries::wasm_import_module_map<'tcx>>::try_get
   14: <rustc::ty::context::TyCtxt<'a, 'gcx, 'tcx> as rustc::ty::layout::HasTyCtxt<'gcx>>::tcx
   15: rustc::ty::maps::<impl rustc::ty::maps::queries::symbol_name<'tcx>>::ensure
   16: rustc::ty::maps::<impl rustc::ty::maps::queries::symbol_name<'tcx>>::try_get
   17: rustc::ty::maps::TyCtxtAt::symbol_name
   18: rustc::ty::maps::<impl rustc::ty::context::TyCtxt<'a, 'tcx, 'lcx>>::symbol_name
   19: <rustc_trans::base::ValueIter as core::iter::iterator::Iterator>::next
   20: <rustc_trans::ModuleLlvm as core::fmt::Debug>::fmt
   21: <rustc_trans::base::ValueIter as core::iter::iterator::Iterator>::next
   22: rustc::dep_graph::graph::DepGraph::assert_ignored
   23: rustc::ty::maps::<impl rustc::ty::maps::queries::wasm_import_module_map<'tcx>>::try_get
   24: <rustc::ty::context::TyCtxt<'a, 'gcx, 'tcx> as rustc::ty::layout::HasTyCtxt<'gcx>>::tcx
   25: rustc::ty::maps::<impl rustc::ty::maps::queries::collect_and_partition_translation_items<'tcx>>::ensure
   26: rustc::ty::maps::<impl rustc::ty::maps::queries::collect_and_partition_translation_items<'tcx>>::try_get
   27: rustc::ty::maps::TyCtxtAt::collect_and_partition_translation_items
   28: rustc::ty::maps::<impl rustc::ty::context::TyCtxt<'a, 'tcx, 'lcx>>::collect_and_partition_translation_items
   29: <rustc_trans::LlvmTransCrate as rustc_trans_utils::trans_crate::TransCrate>::trans_crate
   30: rustc_driver::driver::build_output_filenames
   31: rustc_driver::driver::phase_4_translate_to_llvm
   32: <rustc_driver::pretty::UserIdentifiedItem as core::fmt::Debug>::fmt
   33: <rustc_driver::pretty::UserIdentifiedItem as core::fmt::Debug>::fmt
   34: <rustc_driver::pretty::UserIdentifiedItem as core::fmt::Debug>::fmt
   35: <rustc_driver::profile::trace::Query as core::fmt::Debug>::fmt
   36: rustc_driver::driver::compile_input
   37: rustc_driver::run_compiler
   38: rustc_driver::target_features::add_configuration
   39: <rustc_driver::derive_registrar::Finder as rustc::hir::itemlikevisit::ItemLikeVisitor<'v>>::visit_impl_item
   40: <rustc_driver::pretty::UserIdentifiedItem as core::fmt::Debug>::fmt
   41: _rust_maybe_catch_panic
   42: rustc_driver::driver::build_output_filenames
   43: <<std::sys_common::remutex::ReentrantMutex<T> as core::fmt::Debug>::fmt::LockedPlaceholder as core::fmt::Debug>::fmt
   44: std::sys::windows::thread::Thread::new
   45: BaseThreadInitThunk
   46: RtlSubscribeWnfStateChangeNotification
   47: RtlSubscribeWnfStateChangeNotification

and the relevant output of systeminfo:

Host Name:                 ---
OS Name:                   Microsoft Windows Server 2016 Datacenter
OS Version:                10.0.14393 N/A Build 14393
OS Manufacturer:           Microsoft Corporation
OS Configuration:          Standalone Server
OS Build Type:             Multiprocessor Free
Original Install Date:     9/8/2017, 2:59:51 PM
System Boot Time:          6/19/2018, 10:49:50 AM
System Manufacturer:       Xen
System Model:              HVM domU
System Type:               x64-based PC
Processor(s):              1 Processor(s) Installed.
                           [01]: Intel64 Family 6 Model 63 Stepping 2 GenuineIntel ~2400 Mhz
BIOS Version:              Xen 4.2.amazon, 8/24/2006
Windows Directory:         C:\Windows
System Directory:          C:\Windows\system32
Boot Device:               \Device\HarddiskVolume1
System Locale:             en-us;English (United States)
Input Locale:              en-us;English (United States)
Time Zone:                 (UTC-05:00) Eastern Time (US & Canada)
Total Physical Memory:     32,768 MB
Available Physical Memory: 30,423 MB
Virtual Memory: Max Size:  37,632 MB
Virtual Memory: Available: 35,042 MB
Virtual Memory: In Use:    2,590 MB

Metadata

Metadata

Assignees

Labels

C-bugCategory: This is a bug.I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️O-windowsOperating system: WindowsO-x86_32Target: x86 processors, 32 bit (like i686-*) (IA-32)T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions