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

ICE compiling dashmap #79875

Closed
djmarcin opened this issue Dec 10, 2020 · 14 comments
Closed

ICE compiling dashmap #79875

djmarcin opened this issue Dec 10, 2020 · 14 comments
Labels
A-incr-comp Area: Incremental compilation C-bug Category: This is a bug. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@djmarcin
Copy link

This is just a copy/paste from the compiler error output. I'm running rust via bazel, not cargo, using nightly-2020-12-08.

INFO: From Compiling Rust lib dashmap v3.11.10 (16 files):
thread 'rustc' panicked at 'called `Option::unwrap()` on a `None` value', compiler/rustc_middle/src/ty/query/mod.rs:235:5
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/issues/new?labels=C-bug%2C+I-ICE%2C+T-compiler&template=ice.md

note: rustc 1.50.0-nightly (3d6705aa5 2020-12-07) running on x86_64-unknown-linux-gnu

note: compiler flags: -C opt-level=0 -C debuginfo=0 -C linker=/usr/bin/gcc -C link-args=-fuse-ld=gold -Wl,-no-as-needed -Wl,-z,relro,-z,now -B/usr/bin -pass-exit-codes -lstdc++ -lm -C incremental --crate-type lib

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

query stack during panic:
end of query stack
thread '<unnamed>' panicked at 'assertion failed: `(left == right)`
  left: `LLVMing`,
 right: `Codegenning`', /rustc/3d6705aa5abffe94c83bf09af8c3ba3c599845fc/compiler/rustc_codegen_ssa/src/back/write.rs:1425:21

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.50.0-nightly (3d6705aa5 2020-12-07) running on x86_64-unknown-linux-gnu

note: compiler flags: -C opt-level=0 -C debuginfo=0 -C linker=/usr/bin/gcc -C link-args=-fuse-ld=gold -Wl,-no-as-needed -Wl,-z,relro,-z,now -B/usr/bin -pass-exit-codes -lstdc++ -lm -C incremental --crate-type lib

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

query stack during panic:
end of query stack
@djmarcin djmarcin added C-bug Category: This is a bug. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Dec 10, 2020
@camelid
Copy link
Member

camelid commented Dec 10, 2020

Duplicate of #79661. Should be fixed in the next nightly (2020-12-09).

@camelid camelid closed this as completed Dec 10, 2020
@djmarcin
Copy link
Author

I just updated to 2020-12-10 and the ICE occurred again, so it doesn't appear to be fixed.

@camelid
Copy link
Member

camelid commented Dec 11, 2020

Hmm, that's unfortunate. Can you post the ICE you get on 2020-12-10 so we can see if perhaps it's slightly different?

@camelid camelid reopened this Dec 11, 2020
@djmarcin
Copy link
Author

Here's the latest error. At first the build succeeded, but a second build of the same code failed.

INFO: From Compiling Rust bin build_script_script_ (1 files):
--
  | thread 'rustc' panicked at 'Failed to recover key for type_of(f441f7c09333dbee-181350e87790bb85) with hash f441f7c09333dbee-181350e87790bb85', compiler/rustc_middle/src/ty/query/mod.rs:235:5
  | 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/issues/new?labels=C-bug%2C+I-ICE%2C+T-compiler&template=ice.md
  |  
  | note: rustc 1.50.0-nightly (f0f68778f 2020-12-09) running on x86_64-unknown-linux-gnu
  |  
  | note: compiler flags: -C opt-level=3 -C debuginfo=0 -C linker=/usr/bin/gcc -C link-args=-fuse-ld=gold -Wl,-no-as-needed -Wl,-z,relro,-z,now -B/usr/bin -pass-exit-codes -lstdc++ -lm -Wl,--gc-sections -C incremental --crate-type bin
  |  
  | note: some of the compiler flags provided by cargo are hidden
  |  
  | query stack during panic:
  | end of query stack
  | thread '<unnamed>' panicked at 'assertion failed: `(left == right)`
  | left: `LLVMing`,
  | right: `Codegenning`', /rustc/f0f68778f798d6d34649745b41770829b17ba5b8/compiler/rustc_codegen_ssa/src/back/write.rs:1425:21
  |  
  | 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.50.0-nightly (f0f68778f 2020-12-09) running on x86_64-unknown-linux-gnu
  |  
  | note: compiler flags: -C opt-level=3 -C debuginfo=0 -C linker=/usr/bin/gcc -C link-args=-fuse-ld=gold -Wl,-no-as-needed -Wl,-z,relro,-z,now -B/usr/bin -pass-exit-codes -lstdc++ -lm -Wl,--gc-sections -C incremental --crate-type bin
  |  
  | note: some of the compiler flags provided by cargo are hidden
  |  
  | query stack during panic:
  | end of query stack
  | ERROR: common/BUILD:6:19: output 'common/build_script_script_' was not created
  | ERROR: common/BUILD:6:19: Couldn't build file common/build_script_script_: not all outputs were created or valid
  | INFO: From Compiling Rust bin build_script_script_ (1 files):
  | thread 'rustc' panicked at 'called `Option::unwrap()` on a `None` value', compiler/rustc_metadata/src/rmeta/decoder.rs:1565:75
  | 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/issues/new?labels=C-bug%2C+I-ICE%2C+T-compiler&template=ice.md
  |  
  | note: rustc 1.50.0-nightly (f0f68778f 2020-12-09) running on x86_64-unknown-linux-gnu
  |  
  | note: compiler flags: -C opt-level=3 -C debuginfo=0 -C linker=/usr/bin/gcc -C link-args=-fuse-ld=gold -Wl,-no-as-needed -Wl,-z,relro,-z,now -B/usr/bin -pass-exit-codes -lstdc++ -lm -Wl,--gc-sections -C incremental --crate-type bin
  |  
  | note: some of the compiler flags provided by cargo are hidden
  |  
  | query stack during panic:
  | #0 [normalize_generic_arg_after_erasing_regions] normalizing `log::STATIC_MAX_LEVEL`
  | #1 [collect_and_partition_mono_items] collect_and_partition_mono_items
  | end of query stack

@djmarcin
Copy link
Author

An aside -- when I say 2020-12-10 I mean the file downloaded at https://static.rust-lang.org/dist/2020-12-10/rust-nightly-x86_64-unknown-linux-gnu.tar.gz -- but it appears to have embedded f0f68778f 2020-12-09. When saying a nightly version, is it the URL date or embedded date that folks usually use?

@camelid
Copy link
Member

camelid commented Dec 11, 2020

To my knowledge, the nightly version is whatever comes out of rustc --version :)

In your case, it seems to be nightly-2020-11-09.

@camelid camelid added I-prioritize Issue: Indicates that prioritization has been requested for this issue. A-incr-comp Area: Incremental compilation labels Dec 11, 2020
@camelid
Copy link
Member

camelid commented Dec 11, 2020

It seems like #79721 introduced another bug? The panic message changed.

@jyn514
Copy link
Member

jyn514 commented Dec 11, 2020

The new ICE is a duplicate of #79890.

@jyn514 jyn514 closed this as completed Dec 11, 2020
@jyn514
Copy link
Member

jyn514 commented Dec 11, 2020

Note that the fix was only merged 9 hours ago, so there isn't yet a nightly that fixes the issue: #79915. Feel free to open a new bug if your build is still broken after the next nightly.

@camelid
Copy link
Member

camelid commented Dec 11, 2020

Okay, then @djmarcin can you try again with tonight's nightly (2020-12-11) and let us know if it works? Thanks!

@camelid camelid removed the I-prioritize Issue: Indicates that prioritization has been requested for this issue. label Dec 11, 2020
@jyn514
Copy link
Member

jyn514 commented Dec 11, 2020

@camelid the next nightly won't be published until 2020-12-12, -11 has the commits from yesterday (and works now): https://github.com/willcrichton/example-analyzer/pull/1/files#diff-335ddbce02d068207f42ecdac988ee267eb014a7a1e7ffe8df7bedd66f716899R2

@camelid
Copy link
Member

camelid commented Dec 11, 2020

Hmm, but rustup says the latest nightly is 2020-12-10:

info: latest update on 2020-12-11, rust version 1.50.0-nightly (d32c320d7 2020-12-10)

@djmarcin
Copy link
Author

@camelid the next nightly won't be published until 2020-12-12, -11 has the commits from yesterday (and works now): https://github.com/willcrichton/example-analyzer/pull/1/files#diff-335ddbce02d068207f42ecdac988ee267eb014a7a1e7ffe8df7bedd66f716899R2

If I'm understanding you correctly, the nightly published sometime in the next ~12 hours or so should have the patch, though it will be labeled something like rust version 1.50.0-nightly (somehash 2020-12-11), correct?

@jyn514
Copy link
Member

jyn514 commented Dec 11, 2020

Correct, the rustc version is offset from rustup by one. Or in other words, the latest available nightly was built on the 10th but distributed on the 11th.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-incr-comp Area: Incremental compilation C-bug Category: This is a bug. I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

3 participants