Skip to content

arm64 backend is a stub — native compilation broken on Apple Silicon #5

@glennmichael123

Description

@glennmichael123

Context

README sells "compiles to native x64 code." In practice every Mac shipped since late 2020 is Apple Silicon (arm64), so home build on the most common contributor laptop has no working native target.

Backend LOC
packages/codegen/src/x64.zig 2,665
packages/codegen/src/arm64.zig 259
packages/codegen/src/wasm.zig 360
packages/codegen/src/llvm_codegen.zig 619

This is the #1 blocker for adoption. New contributors zig build, run hello world, and find their machine isn't supported.

Scope

  • Bring arm64.zig to feature parity with x64.zig for the language subset that has codegen tests today
  • Pass the existing codegen test suite on aarch64-macos and aarch64-linux
  • Update README to honestly describe backend coverage (or, once parity lands, drop the x64-only language)
  • Add CI matrix entries for aarch64-macos (GitHub-hosted M1 runners) and aarch64-linux

Notes

  • LLVM backend (619 LOC) is also stub-grade. If parity via direct codegen is too much, an alternative path is "finish the LLVM backend and let it cover all non-x64 targets." Worth deciding upfront.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingenhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions