Skip to content

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

@yorickpeterse

Description

@yorickpeterse

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)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions