Notes

Kiri vs OrbStack for local Go development

Kiri ran the two import-heavy PostgreSQL test groups faster and used less memory. At the original settings, those tests took 34% and 43% less time on Kiri, saving about a quarter of a second each. Its peak memory footprint was 58–59% lower, about 1 GiB less in both cases.

OrbStack used less CPU with ten idle containers. At matched VM limits, it also finished a cold Go image build in 10% less time and handled 8% more read-only PostgreSQL transactions per second. In the local development workflow, make run compiles Go on macOS, so the database results are the ones that apply directly.

The benchmarks ran on an M1 Ultra with 20 logical CPUs and 64 GiB of RAM. The tables and charts use two configurations.

  • Original uses each VM’s existing limits. Kiri could use up to 2 vCPUs and 8 GiB of RAM, and OrbStack up to 20 vCPUs and 16 GiB.
  • Matched gives both VMs the same limits of 2 vCPUs and 8 GiB. This compares the engines with the same CPU and memory allowance. Actual usage can be lower.

Lower is better for elapsed time, memory footprint, and idle CPU. Higher is better for throughput (requests or transactions per second). Each percentage uses the other engine’s unrounded median as its baseline. Bar lengths share a scale within each chart panel.

Container benchmarks

The startup, command execution, and three-layer build tests used alpine:3.22. The file tests used the same image to read and write a directory mounted from the Mac. For HTTP, busybox:1.37.0 served a small file over a published port.

At matched limits, Kiri took less time to start and remove a container. OrbStack served more HTTP requests per second.

OperationKiriOrbStack
Warm docker run --rm39 ms (−81%)203 ms
docker exec true in a running container31 ms (−30%)44 ms
Uncached image build, three trivial RUN layers334 ms (−62%)875 ms
Bind mount, 256 MiB write and fsync244 ms176 ms (−28%)
Bind mount, 256 MiB cached read152 ms55 ms (−64%)
HTTP over a new localhost connection per request1,140 req/s1,638 req/s (+44%)

With ten idle containers, Kiri used 73% less memory (326 vs 1,192 MiB). OrbStack used 75% less idle CPU (1.6% vs 6.3% of one core).

Go builds inside Docker

The deployment build compiled a Go service in golang:1.27-bookworm and copied the binary into gcr.io/distroless/static-debian12:nonroot. The rebuild tests used a running Go container with a bind mount for the source and named volumes for the Go caches.

At matched limits, OrbStack took less time for both the cold image build and the rebuild after a source edit.

Build at matched limitsKiriOrbStack
Deployment image, cold Go compiler cache37.65 s33.96 s (−10%)
Deployment image, warm Go cache, new revision3.14 s2.81 s (−11%)
Deployment image, all layers cached0.95 s (−7%)1.03 s
Rebuild one service, no changes0.24 s0.23 s (−3%)
Rebuild one service after a source edit3.56 s2.93 s (−18%)
Bind-mounted module, warm go build ./...6.45 s5.48 s (−15%)

OrbStack finished the cold image build 3.7 seconds sooner at matched limits. The fully cached and unchanged rebuilds had overlapping timing ranges. With its original 20 vCPUs and 16 GiB, it finished in 12.04 seconds in a single run. Both deployment images connected to PostgreSQL and served the expected HTML page.

PostgreSQL with a native Go client

Each engine ran a postgres:16 container. The same precompiled Go tests ran on macOS and connected through the published localhost port. Timings include cloning a database from a migrated template, exercising the service code, and dropping the database afterward.

At original limits, both import-heavy test groups took less time on Kiri and had a smaller runtime memory footprint.

Database workloadKiri, originalOrbStack, originalKiri, matchedOrbStack, matched
Reject fields that are invalid for a record type129 ms (−12%)146 ms132 ms129 ms (−3%)
Sync changes, paginate results, import updates479 ms (−34%)729 ms463 ms (−30%)664 ms
Manage records over HTTP, repeat imports, check data isolation and search304 ms (−43%)536 ms355 ms (−35%)547 ms

The validation test differed by just 3–17 ms and changed direction between configurations. On fresh VMs at the original limits, Kiri’s median sampled peak footprint was 59% lower during sync (764 vs 1,842 MiB) and 58% lower during the HTTP, isolation, and search tests (786 vs 1,884 MiB).

The pgbench client ran inside the PostgreSQL container, using generated data and bypassing host port forwarding. The read-only tests used warm data.

Kiri completed more read/write transactions per second under both configurations. OrbStack led on warm read-only throughput, with a smaller lead at matched limits.

Transactions per secondKiri, originalOrbStack, originalKiri, matchedOrbStack, matched
Read/write6,282 (+95%)3,2175,927 (+82%)3,255
Read-only57,50295,905 (+67%)56,79361,570 (+8%)

Reproducing the comparison

  • Environment. macOS 26.6.2, Kiri 0.2.2, OrbStack 2.2.5, Docker CLI 29.8.2. Both engines used the same arm64 images and source revision (fe9c3c0ca4224a879d04dbcf175f45260bf94719).
  • Timings. Tables show medians. Startup and exec had 30 samples after five warmups. Most builds had three samples, with five for file I/O, fully cached images, and single-app rebuilds. HTTP used five batches of 1,000 verified requests.
  • Builds. Each engine used its own BuildKit 0.35.1 builder and the repository’s deploy/Dockerfile with Go 1.27.4. Base images and modules were already downloaded. Cold runs cleared the compiler cache. Changing GIT_SHA forced a relink. Source edits used an archived copy.
  • Fixtures and memory. Go 1.27.1 compiled the test binaries with the race detector off. All eight selected tests passed without skips in one warmup and three timed runs per group. Memory figures cover the app, daemon, and VM, including database caches. Sampling on fresh VMs took place at the start and end of each run and every half-second in between.
  • PostgreSQL. Each pgbench sample started with two million account rows (scale 20), eight clients, two threads, a five-second warmup, and a 15-second measurement. All transactions succeeded. PostgreSQL 16.16 used fsync=on, synchronous_commit=on, full_page_writes=on, and shared_buffers=128MB. These local runs used small app fixtures and generated data.