A running company world forks in 35 microseconds
How much does it cost to branch a simulated world that has been running? On the company-2026 reference world, after 1,000 actor steps, a fork took 35.0 µs at the median (28,508 a second) and an unmodified branch retained 20.9 KB. The first write in a branch is the expensive part: 8.11 ms and 30.5 MB.




The question
Branching a world is how an agent rehearses a change or a checker explores every action from a state. What does one fork cost, in time and in memory, once the world has accumulated real history?
Method
The benchmark starts the company-2026 reference world, drives an actor through real steps, then measures snapshots and forks in a native release build. The current measurements use three runs of 300 timed forks, with 50 warm-up forks and 200 live forks for the retained-memory measurement, at 0, 1,000 and 4,000 accumulated steps.
Measurements ran on an ARM Cortex-X925 / Cortex-A725 host with 121 GiB of RAM and Ubuntu 24.04, pinned to one performance core. Other workloads were active.
Results
Fork latency grows with the world's history
| Accumulated steps | Median fork latency | Forks / second |
|---|---|---|
| 0 | 15.9 µs | 62,753 |
| 1,000 | 35.0 µs | 28,508 |
| 4,000 | 116.4 µs | 8,511 |
At 1,000 steps, median fork latency across the three runs ranged from 34.8 to 35.0 µs; throughput ranged from 28,412 to 28,659 forks per second.
Forking is cheap; the first write is not
A live fork retains 20,863 bytes: 5,975 bytes of heap plus the 14,888-byte World value. This is the incremental cost of retaining an unmodified branch, not its eventual memory footprint.
At 1,000 steps, the measured first write in a branch allocated 30.5 MB and took 8.11 ms. At 4,000 steps it allocated 88.1 MB. Copy-on-write postpones copying shared state until mutation; the first write is a separate cost.
Limitations
- One host, one pinned core, with other workloads active; the three runs agree to within 0.2 µs, but another machine will give other numbers.
- The retained size is an unmodified branch's. A branch that writes pays the first-write cost above and keeps what it changed.
- The earlier five-run dataset in the repository predates the optimizations and does not contain these current figures. These results come from the subsequent measurements in the benchmark report.
Reproduce it
BENCH_RUNS=3 BENCH_SAMPLES=300 BENCH_WARMUP=50 \
BENCH_LIVE_FORKS=200 BENCH_FORK_STEPS=0,1000,4000 \
cargo run --release -p cw-benchmarks --bin fork_throughput
Performance guide · Full engineering report and history ↗
The benchmark forked the company world. Boot company-2026 and fork it yourself