Repository navigation
Build the LLVM backend on every platform in CI - #32
Merged
siahisaforker merged 1 commit intoSep 17, 2026
Merged
Conversation
The LLVM backend had no coverage on macOS at all, and on Windows only under MSYS2/UCRT64 mingw GCC. MSVC built the repo but configured without DOLRECOMP_ENABLE_LLVM, so src/backend/llvm was never compiled there. An MSVC-only break therefore could not be seen by any job, and one duly landed: __builtin_popcountll in abi_policy.cpp, which MSVC has no equivalent for. Key the matrix on toolchain rather than OS, since the two Windows entries are genuinely different configurations, and add macOS for the Mach-O object path. Three tests are excluded on macOS as known Darwin gaps rather than regressions, so the remaining 29 can gate rather than the job being permanently red. Each is named in a comment with what it would take to enable it. macOS also runs serially: those tests share artifacts in the build directory and report an inconsistent subset of failures under -j10. Verified locally on all four configurations.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The LLVM backend had no CI coverage on macOS at all, and on Windows only under MSYS2/UCRT64 mingw GCC. The MSVC job builds the repo but configures without
DOLRECOMP_ENABLE_LLVM, sosrc/backend/llvmis never compiled there.An MSVC-only break therefore could not be seen by any job, and one duly landed on
main:mingw GCC has that builtin, so the one job that does enable the LLVM backend on Windows compiles it happily. MSVC plus the LLVM backend is the configuration a local Windows toolchain actually uses, and it was the one combination nothing built. (#31 fixes that break; this PR is what would have caught it.)
macOS was worse — nothing anywhere built the LLVM backend for Mach-O, which is how the invalid cold-section name in #26 went unnoticed.
What changed
The
llvmmatrix is now keyed on toolchain rather than OS, because the two Windows entries are genuinely different configurations:llvm@20, Mach-O object pathmacOS: 29 of 32 tests gate, three are excluded
Rather than let the job sit permanently red, three tests are excluded as known Darwin gaps, each named in a comment with what enabling it would take:
llvm_pipeline—is_native_object()knows COFF and ELF only. On macOS the pipeline emits both native Mach-O and cross-target ELF objects in the same run, so the check has to know which object is which target before it can be meaningful here. Adding a Mach-O branch fixes two of its three call sites but not the third, which reads a cross-target ELF object.modern_codegen— the wide return struct has a different element count under the arm64 Darwin ABI (getNumElements() == 3does not hold).llvm_codegen— AArch64 disassembly assertions; symbol naming differs on Mach-O.None of these is a regression; all three fail on
maintoday once the build gets far enough to run them.macOS also runs
ctest -j1. Those tests share artifacts in the build directory and report an inconsistent subset of failures under-j10— worth knowing for anyone reproducing locally.Verification
Built and tested all four configurations locally before opening this:
Expected state of this PR
The two new jobs will be red on
mainuntil #31 and #26 land — MSVC on the popcount break, macOS on the Mach-O cold-section name. That is the point: both are real, both are already fixed in open PRs, and neither was visible to CI before. Merge those two first and this goes green.