Skip to content

Analysis: bun15 branch (oven-sh/zig fork) vs official Zig 0.15.2 #19

Description

@cataggar

bun15 branch vs official Zig 0.15.2 — change analysis

bun15 tracks Bun's downstream fork (oven-sh/zig, the upgrade-0.15.2 line), pinned at commit c6df1f40 ("Merge oven-sh/zig#21 — llvm: improve IR attributes and cast flags for better optimization").

It descends cleanly from tag 0.15.2 with 35 commits on top (3 merged PRs: oven-sh/zig#16, oven-sh/zig#17, oven-sh/zig#21), touching ~60 files (+1,641 / −812). The reported compiler version is still 0.15.2 — this is a Bun-tuned 0.15.2, not an upgrade to a newer Zig.

1. LLVM codegen improvements (the headline — oven-sh/zig#21)

2. Target & linker additions

  • New aarch64-windows-gnu build target.
  • MachO: match arm64e TBD targets when linking arm64 (src/link/MachO.zig, src/link/MachO/Dylib.zig).
  • f16 ABI fix on Darwin (CBE + compiler_rt); gate strlen extern off the C backend.

3. Language / tooling tweaks Bun relies on

4. Downstream std patches ("our patches")

Broad edits to lib/std/posix.zig (548 lines churned), fs/Dir.zig, mem.zig, mem/Allocator.zig (+15), os/windows.zig, os/linux.zig, Io/Writer.zig (+43), crypto (argon2, bcrypt), and Build/Module.zig + Build/Step/Compile.zig (a no_link_obj path).

5. Build system / CI / caching

  • Replaces upstream ci.yaml with .github/workflows/bun_build.yaml — Bun's matrix (macos / linux-musl / windows-gnu × {safe, debug}) built via zig-bootstrap, ReleaseSafe vs ReleaseFast variants, releases named by branch (so stable and -fast are distinguishable).
  • LLVM build caching (cache keys, include out/host), several "fix build crash" commits, "skip lf flush when no link is set", CMakeLists.txt, build.zig, and a heavily trimmed README.md.

Net assessment

A Bun-tuned 0.15.2 focused on better LLVM optimization/LTO, extra macOS/Windows target support, compiler introspection / zig fmt conveniences, and a custom multi-target build/CI pipeline — layered on the unchanged 0.15.2 base.


Branch pushed to cataggar/zig as bun15. Comparison base: tag 0.15.2 (e4cbd752c8). Generated from git log/diff 0.15.2..bun15.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions