Circuit simulation benchmarks
Compare sampling, detector sampling and DEM sampling within each recorded workload.
Compare the surface-code sampling paths
Pinned release measurements for named fixtures; these results are case-scoped and are not a general performance claim.
Five surface-code sampling paths
One-time precompilation is shown separately. Sample + output is the worker-local Sample phase plus b8 output and excludes both precompilation and pipe transport. Precompiled rows reuse a sampler; direct rows include their per-batch setup in the Sample column. Samples/s is calculated from Sample + output.
| Implementation | Precompile once | Sample | b8 output | Sample + output | Samples/s |
|---|---|---|---|---|---|
| rstim precompiled | 2.925 ms | 4.208 ms | 0.273 ms | 4.481 ms | 228,545 |
| Stim precompiled | 1.115 ms | 16.093 ms | 0.035 ms | 16.128 ms | 63,493 |
| rstim interpreted | — | 7.330 ms | 0.199 ms | 7.529 ms | 136,015 |
| Stim direct | — | 16.775 ms | 0.040 ms | 16.815 ms | 60,896 |
| rstim precompiled + atom loss | 2.979 ms | 4.002 ms | 0.264 ms | 4.266 ms | 240,053 |
All rows use the surface d=11, r=100 fixture with 1,024 shots. Each phase is the breakdown of the same median-total call selected from 7 calls after 2 warmups; precompile is one observed setup. Stim produces an already bit-packed array inside sample, so its packing work appears under “Sample” and its b8 step is only byte serialization. In this recorded run, rstim is 3.60× faster in the precompiled comparison. The precompiled atom-loss path is in the same 4 ms range as rstim precompiled; its small lead is within run-to-run variation and is not treated as an atom-loss speedup claim.
For the atom-loss case, one depolarization event and two independent per-atom loss events after each two-qubit gate all use p = 1 - 0.999^(1/3) ≈ 0.0003334445062, keeping the probability of at least one error at 0.001.
Checked simulator results
Inspect checked runs, limitations, and reproduction commands
Loading simulator evidence.
Historical measurements and CI regression checks
Detection and DEM sampling
These are separate, recorded workloads. Compare implementations only within the same workload and metric; reproduction details and limits are below.
| Workload | Implementation | Metric | Result |
|---|---|---|---|
| Surface d=13, r=13 detect | rstim compiled | Elapsed time · lower is better | 34.339 ms |
| Surface d=13, r=13 detect | Stim CLI | Elapsed time · lower is better | 266.172 ms |
| Surface d=11, r=100 DEM sample | rstim | Throughput · higher is better | 329 shots/s |
| Surface d=11, r=100 DEM sample | Stim | Throughput · higher is better | 2,669 shots/s |
Checked DEM results
Loading detector-model evidence.