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

LLVM ERROR: fixup value too large for data type #84006

Open
chipsenkbeil opened this issue Apr 8, 2021 · 3 comments
Open

LLVM ERROR: fixup value too large for data type #84006

chipsenkbeil opened this issue Apr 8, 2021 · 3 comments
Labels
A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. C-bug Category: This is a bug. O-AArch64 Armv8-A or later processors in AArch64 mode O-macos Operating system: macOS T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@chipsenkbeil
Copy link

chipsenkbeil commented Apr 8, 2021

Moving from user forum: https://users.rust-lang.org/t/llvm-error-fixup-value-too-large-for-data-type/58059


Platform: Apple M1 (Mac Mini & Macbook Air)
Operating System: Mac OS X Big Sur 11.2.2
Host: aarch64-apple-darwin
Rust: 1.51.0 (stable)

Works fine on other systems such as Ubuntu with x86_64.


To reproduce, open vimwiki-rs RefactorToEntity branch, navigate to the vimwiki-server directory, and run cargo build --release. This will fail on the final step with the LLVM error.

Screen Shot 2021-04-08 at 12 52 18 PM


When building a release version of my binary, I'm encountering, "LLVM ERROR: fixup value too large for data type!" This only happens with release, which is configured with these settings:

[profile.release]
opt-level = 'z'
lto = true
codegen-units = 1

These settings worked fine until I recently refactored my binary to use a new library I wrote that generates a lot of code using a mixture of derive and attribute macros, so I'm assuming it has something to do with that, but this error message doesn't tell me anything that I can do to try to fix it myself.

For reference, the project being compiled is vimwiki-server of vimwiki-rs RefactorToEntity branch. It's a lot of code, so trying to undo changes one at a time is going to be difficult.

Has anyone seen this error before? What kinds of Rust code can lead to this?

@chipsenkbeil chipsenkbeil added the C-bug Category: This is a bug. label Apr 8, 2021
@jonas-schievink jonas-schievink added A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. O-Arm Target: 32-bit Arm processors (armv6, armv7, thumb...), including 64-bit Arm in AArch32 state O-macos Operating system: macOS labels Apr 8, 2021
@the8472
Copy link
Member

the8472 commented Apr 8, 2021

Looks like it has been fixed upstream llvm/llvm-project@38348fa and isn't in the rust-lang llvm repo.

@the8472
Copy link
Member

the8472 commented Apr 8, 2021

Nevermind, github search doesn't find it when it's on branches, it's in the rust llvm repo on the llvm12 branch: rust-lang/llvm-project@38348fa

The bump to llvm12 happened recently, it's not in a stable release yet. You could try nightly.

@chipsenkbeil
Copy link
Author

Nevermind, github search doesn't find it when it's on branches, it's in the rust llvm repo on the llvm12 branch: rust-lang/llvm-project@38348fa

The bump to llvm12 happened recently, it's not in a stable release yet. You could try nightly.

Tried nightly, but it's failing to compile because of issues with version 0.7.4 of lexical-core, some transitive dependency. So unable to verify whether upstream changes would fix, but crossing fingers 😄

@workingjubilee workingjubilee added O-AArch64 Armv8-A or later processors in AArch64 mode and removed O-Arm Target: 32-bit Arm processors (armv6, armv7, thumb...), including 64-bit Arm in AArch32 state labels Mar 18, 2022
@Noratrieb Noratrieb added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Apr 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. C-bug Category: This is a bug. O-AArch64 Armv8-A or later processors in AArch64 mode O-macos Operating system: macOS 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

5 participants