Cruller: a production-focused Bun runtime ported to Zig 0.16

Cruller is a fork of the last Zig-based Bun release, reduced to the parts needed to run already-built production JavaScript servers and ported to vanilla Zig 0.16.

Repository: GitHub - solenopsys/cruller: fork of Bun · GitHub

The project keeps JavaScriptCore, Bun.serve, HTTP/1-3, WebSockets, fetch, streams, Blob, Request/Response, static serving, and the module resolver for pre-built JavaScript. It removes the package manager, bundler/transpiler, shell, test runner, most CLI dispatch, N-API, SQL clients, archive support, and other development-oriented subsystems.

The interesting part of the port was separating the runtime from Bun’s old patched Zig build integration. Cruller now has a vanilla Zig 0.16 build graph, compatibility shims for APIs changed since Zig 0.15, and a generated-code embedding module so release builds remain portable instead of loading generated JS from the build directory at runtime.

The main design decision is to treat this as a runtime, not a general-purpose Bun replacement. A minimal launcher loads a pre-built entrypoint; features that require package installation, bundling, TypeScript transformation, or bun test are intentionally outside the scope.

Current measurements on Linux x64, compared with the official Bun 1.3.14 binary:

  • Cruller ReleaseFast stripped runtime: 73.0 MiB
  • Official Bun runtime: 88.5 MiB
  • Size reduction: about 18%
  • V8 Crypto pure-JS benchmark: performance parity; Cruller’s median was about 2% higher, within normal run-to-run variance

The runtime is still work in progress, but Zig semantic checks, release builds, CJS/ESM entrypoints, Node path tests, and an HTTP Bun.serve plus built-in fetch() smoke test currently pass.

Supported Zig versions

  • Zig 0.16.0
  • Linux x64 is the currently supported build target

Suggested topic tags: showcase, zig-0-16, llm

AI / LLM usage disclosure

AI was used as an engineering assistant for parts of the Zig 0.16 migration, build/debug investigation, and focused test work. The project scope, architecture decisions, review of changes, and build/test verification remain maintainer-directed. This is not a purely AI-generated project.