rust-lang / rust

Empowering everyone to build reliable and efficient software.
https://www.rust-lang.org
Other
98.03k stars 12.68k forks source link

ICE: could not decode incremental cache: Any #68116

Closed tesuji closed 4 years ago

tesuji commented 4 years ago

Sorry I cannot provide a minimal reproduce since this ICE happened when I incrementally built the Rustc.

thread '<unnamed>' panicked at 'internal error: entered unreachable code', /home/lzutao/fork/rust/compiler/src/librustc/dep_graph/dep_node.rs:118:34                                                                                                                            
note: run with `RUST_BACKTRACE=1` environment variable to display a 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/blob/master/CONTRIBUTING.md#bug-reports                                                                                                                                                               

note: rustc 1.42.0-dev running on x86_64-unknown-linux-gnu                                                                                                                                                                                                                      

note: compiler flags: -Z external-macro-backtrace -Z binary-dep-depinfo -Z force-unstable-if-unmarked -C opt-level=2 -C debuginfo=0 -C incremental -C link-args=-Wl,-rpath,$ORIGIN/../lib -C prefer-dynamic -C llvm-args=-import-instr-limit=10 -C debug-assertions=n --crate-ty
pe lib                                                                                                                                                                                                                                                                          

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

Master hash: e6217972644588a3be4fecb85b195f17b0220047

tesuji commented 4 years ago

Diff between config.conf: diff config.toml.example config.toml

--- config.toml.example 2020-01-10 12:45:28.064159323 +0000
+++ config.toml 2020-01-10 18:40:23.019243486 +0000
@@ -36,7 +36,7 @@
 #assertions = false

 # Indicates whether ccache is used when building LLVM
-#ccache = false
+ccache = true
 # or alternatively ...
 #ccache = "/path/to/ccache"

@@ -52,7 +52,7 @@
 # Tell the LLVM build system to use Ninja instead of the platform default for
 # the generated build system. This can sometimes be faster than make, for
 # example.
-#ninja = false
+ninja = true

 # LLVM targets to build support for.
 # Note: this is NOT related to Rust compilation targets. However, as Rust is
@@ -63,7 +63,7 @@
 # support. You'll need to write a target specification at least, and most
 # likely, teach rustc about the C ABI of the target. Get in touch with the
 # Rust team and file an issue if you need assistance in porting!
-#targets = "AArch64;ARM;Hexagon;MSP430;Mips;NVPTX;PowerPC;RISCV;Sparc;SystemZ;WebAssembly;X86"
+targets = "AArch64;ARM;X86;RISCV"

 # LLVM experimental targets to build support for. These targets are specified in
 # the same format as above, but since these targets are experimental, they are
@@ -335,7 +335,7 @@
 #backtrace = true

 # Whether to always use incremental compilation when building rustc
-#incremental = false
+incremental = true

 # Build a multi-threaded rustc
 #parallel-compiler = false
tesuji commented 4 years ago

The ICE disappears when I tried to touch a file and rerun.

tesuji commented 4 years ago

Closed until I find a snippet that trigger this.