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

Building a project using cargo --release results in "LLVM Error: Broken function found" #25940

Closed
yorickpeterse opened this issue Jun 1, 2015 · 4 comments
Labels
I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️

Comments

@yorickpeterse
Copy link

Moving over from rust-lang/cargo#1667:

To reproduce:

  1. git clone [email protected]:YorickPeterse/aeon.git
  2. cd aeon
  3. cargo build --release --verbose

This will result in the following output:

$ cargo build --release --verbose
   Compiling aeon v0.0.1 (file:///home/yorickpeterse/Private/Projects/rust/aeon)
     Running `rustc src/lib.rs --crate-name libaeon --crate-type lib -C opt-level=3 --out-dir /home/yorickpeterse/Private/Projects/rust/aeon/target/release --emit=dep-info,link -L dependency=/home/yorickpeterse/Private/Projects/rust/aeon/target/release -L dependency=/home/yorickpeterse/Private/Projects/rust/aeon/target/release/deps`
Attributes 'readnone and readonly' are incompatible!
void (%"2.core::result::Result<core::option::Option<alloc::rc::Rc<core::cell::RefCell<object::Object>>>, collections::string::String>"*, %"virtual_machine::VirtualMachine"*, i64, %"compiled_code::CompiledCode"*)* @"_ZN15virtual_machine28VirtualMachine$LT$$u27$l$GT$3run20hd9ac846594b29f06JraE"
LLVM ERROR: Broken function found, compilation aborted!
Could not compile `aeon`.

Caused by:
  Process didn't exit successfully: `rustc src/lib.rs --crate-name libaeon --crate-type lib -C opt-level=3 --out-dir /home/yorickpeterse/Private/Projects/rust/aeon/target/release --emit=dep-info,link -L dependency=/home/yorickpeterse/Private/Projects/rust/aeon/target/release -L dependency=/home/yorickpeterse/Private/Projects/rust/aeon/target/release/deps` (exit code: 1)

Rust version: rustc 1.0.0-dev (built 2015-05-17)
Cargo version: cargo 0.3.0-nightly (06dbe65 2015-05-29) (built 2015-05-29)
LLVM version: 3.5.2
Platform: Linux tuxbook 4.0.4-1-ARCH #1 SMP PREEMPT Mon May 18 06:43:19 CEST 2015 x86_64 GNU/Linux (Arch Linux)

@yorickpeterse
Copy link
Author

Expanded rustc version info:

rustc 1.0.0-dev (built 2015-05-17)
binary: rustc
commit-hash: unknown
commit-date: unknown
build-date: 2015-05-17
host: x86_64-unknown-linux-gnu
release: 1.0.0-dev

Sadly don't have a shorter way to reproduce this at the moment as I'm not even sure what's going on :/

@mitaa
Copy link
Contributor

mitaa commented Jun 1, 2015

cc #24713 (a dup?)

@jdm jdm added the I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ label Jun 1, 2015
@emoon
Copy link
Contributor

emoon commented Nov 21, 2015

Tested this on rustc 1.4.0 (8ab8581 2015-10-27) and seems to build as expected so I wonder if this is still an issue?

@yorickpeterse
Copy link
Author

Correct, running cargo build --release on my project now succeeds. Closing this, thanks to whoever/whatever fixed it!

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) ❄️
Projects
None yet
Development

No branches or pull requests

4 participants