Cold vs. warm boot
bb bench changes the function's memory size, which makes the next invoke start in a fresh execution environment. It takes one cold sample there, then five warm samples back to back, and prints a table from CloudWatch's REPORT line. The parser in script/bench.clj is shared by every lambda-mvp-* sibling.
This project's numbers
Measured on 2026-11-14 in ap-southeast-2, arm64, provided.al2023, Glojure v0.7.24, built with Go 1.25.6. bb bench ran three times, and the table gives the median of those runs with the Cold Init range next to it.
| Metric | 2048 MB | 3008 MB |
|---|---|---|
| Cold Init Duration (median of 3) | 102.1 ms | 103.0 ms |
| Cold Init Duration (range of 3) | 80-103 ms | 83-104 ms |
| Cold Duration (median of 3) | 3.6 ms | 3.8 ms |
| Warm Duration (median of the 3 medians) | 1.2 ms | 1.2 ms |
| Max Memory Used | 28 MB | 28 MB |
The first invoke after the deploy was cold too, with 103.45 ms of Init and 3.84 ms of Duration. dist/bootstrap is 15,073,464 bytes and the zip 4,727,122.
Next to the siblings, same day
Three siblings were benched in the same account and region within about an hour of this run, with the same methodology:
| At 2048 MB | glj (Glojure) | cljs (shadow-cljs) | cljrfc (Clojurific) | jlt (Jolt 0.8.27) |
|---|---|---|---|---|
| Cold Init Duration | 102.1 ms | 134.7 ms | 184.4 ms | 477.1 ms |
| Cold Duration | 3.6 ms | 4.9 ms | 3.4 ms | 2.2 ms |
| Warm Duration | 1.2 ms | 1.8 ms | 1.8 ms | 2.0 ms |
| Max Memory Used | 28 MB | 77 MB | 81 MB | 128 MB |
| Deployed zip | 4.7 MB | 23 KB | 77 KB | 15.3 MB |
| At 3008 MB | glj (Glojure) | cljs (shadow-cljs) | cljrfc (Clojurific) | jlt (Jolt 0.8.27) |
|---|---|---|---|---|
| Cold Init Duration | 103.0 ms | 135.3 ms | 149.5 ms | 349.3 ms |
| Cold Duration | 3.8 ms | 5.0 ms | 3.8 ms | 1.9 ms |
| Warm Duration | 1.2 ms | 1.9 ms | 1.6 ms | 1.7 ms |
| Max Memory Used | 28 MB | 77 MB | 82 MB | 128 MB |
Every figure is a median of three bench runs. The siblings' own guides have the ranges. cljs and cljrfc run on AWS's managed nodejs24.x runtime, while jlt and this project are custom runtimes on provided.al2023, so the columns differ in deployment model as well as language.
Glojure had the lowest Cold Init and the least memory of the four, at both tiers. Its slowest cold sample (103.8 ms) still came in under shadow-cljs's slowest (135.4 ms), so the ranges don't overlap. The memory figure stayed at 28 MB on every sample, close to the 26 MB the jank sibling measured for its native binary in September. A static Go binary starts without a VM to boot or a runtime image to load, which fits these numbers, but nothing here separates Go's startup from Glojure's own namespace loading.
Jolt's handler was the fastest once it was running, at about 2 ms on a cold invoke against Glojure's 3.6 to 3.8 ms. Glojure's warm calls were the quickest, at 1.2 ms.
Reproducing a run
export AWS_PROFILE=... AWS_REGION=...
bb build
bb deploy
bb bench
bb teardown # when you're done
BENCH_MEMORY_TIERS (default 2048,3008) and BENCH_WARM_SAMPLES (default 5) are overridable. bb bench leaves the function at its last tier, so tear it down afterwards. Your numbers will differ by account, region and day, and Cold Init moves the most: shadow-cljs's medians in this account were 20 to 30 ms higher today than in September, with identical code.