-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
LLVM error "ran out of registers during register allocation" on 32-bit x86 with code-coverage #42200
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
Comments
The tail of the IR dump with # *** IR Dump After Live Register Matrix ***:
Therefore, the error seems to occur at the next step, "Greedy Register Allocator". |
Can you output the result of Edit: I have used Github Action to reproduce the error with full LLVM IR, see here: link Edit2: I reproduce the error on a nightly built Julia to match the new version LLVM on my computer. Unfortunately, I can't reproduce the error by copying LLVM IR and compiling it with |
We have upgraded LLVM 7 times since this issue, so hopefully it is just okay now? |
@vtjnash error: ran out of registers during register allocation
ERROR: Package RanOutOfRegisters errored during testing
julia> versioninfo()
Julia Version 1.6.7
Commit 3b76b25b64 (2022-07-19 15:11 UTC)
Platform Info:
OS: Windows (i686-w64-mingw32)
CPU: 11th Gen Intel(R) Core(TM) i7-1165G7 @ 2.80GHz
WORD_SIZE: 32
LIBM: libopenlibm
LLVM: libLLVM-11.0.1 (ORCJIT, tigerlake) |
Next LTS should be announced imminently. There is unlikely to be more 1.6 releases, as there haven't been in a while. |
I was about to press 👍 but checked just to be sure. error: ran out of registers during register allocation
ERROR: Package RanOutOfRegisters errored during testing
julia> versioninfo()
Julia Version 1.10.3
Commit 0b4590a550 (2024-04-30 10:59 UTC)
Build Info:
Official https://julialang.org/ release
Platform Info:
OS: Windows (i686-w64-mingw32)
CPU: 8 × 11th Gen Intel(R) Core(TM) i7-1165G7 @ 2.80GHz
WORD_SIZE: 32
LIBM: libopenlibm
LLVM: libLLVM-15.0.7 (ORCJIT, tigerlake)
Threads: 1 default, 0 interactive, 1 GC (on 8 virtual cores) error: ran out of registers during register allocation
ERROR: Package RanOutOfRegisters errored during testing
julia> versioninfo()
Julia Version 1.12.0-DEV.462
Commit da6892ffc9 (2024-05-04 02:54 UTC)
Build Info:
Official https://julialang.org/ release
Platform Info:
OS: Windows (i686-w64-mingw32)
CPU: 8 × 11th Gen Intel(R) Core(TM) i7-1165G7 @ 2.80GHz
WORD_SIZE: 32
LLVM: libLLVM-17.0.6 (ORCJIT, tigerlake)
Threads: 1 default, 0 interactive, 1 GC (on 8 virtual cores) Perhaps this is not a problem on the LLVM side? |
Weirdly, I can not reproduce the problem with GitHub Actions now. Some context (host CPU?) seems to have changed.🤔 However, as I showed above, it reproduces in my local environment. |
This appears to be a problem that occurs on Intel CPUs. If a non-Intel architecture is set as the cpu-target on an Intel CPU, no error occurs. E.g.:
The |
This comes from the discussion on Discourse.
I found a strange error "ran out of registers during register allocation" in the CI log of a package.
The error occurs on 32-bit x86, but I couldn't figure out the trigger for a long time. Later, @ChenNingCong found that the code for code coverage had something to do with it.
The following is an MWE. I think the easiest way to reproduce the error is to write it in
runtests.jl
and run it withpkg> test --coverage
.Output of v1.6.2 on Windows (i686-w64-mingw32)
This problem occurs in the following versions (on both Linux and Windows):
On the other hand, it does not seem to occur on x86-64 or 32-/64-bit ARM.
If you have difficulty preparing a 32-bit x86 environment, you can also use GitHub Actions to reproduce the error.
The text was updated successfully, but these errors were encountered: