diff --git a/docs/benchmarks.md b/docs/benchmarks.md index 3e733a9..6542b3c 100644 --- a/docs/benchmarks.md +++ b/docs/benchmarks.md @@ -113,15 +113,20 @@ Same machine, same afternoon: `zig build bench -Doptimize=ReleaseSafe` here, Context that keeps these honest: -- Upstream jetstream V2 vendors its own decode — no indigo dependency — so - the atproto-bench indigo numbers say nothing about it. The zat-vs-their-Go - comparison on *format* work is the block-decode row (2.4x) via the same - sealed-segment shape (`atproto-bench/go-jss` uses their `segment` package). +- Upstream jetstream V2 ingests through atmos (`jcalabro/atmos v0.2.14`), + which atproto-bench measures directly against zat. The SDK gap is + path-dependent: CID-verified decode is zat 249K vs atmos 91K frames/s + (~2.7x), but the combined relay hot path — decode + CID verify + commit + signature verify — is zat 19.7K vs atmos 18.1K (~1.1x), because ECDSA is + ~95% of the frame budget and every implementation pays it. On the + signature-verifying ingest path the language advantage mostly washes out; + it survives on the sig-free paths (format work, serving, scans), which is + what the table above measures — the zat-vs-their-Go format comparison is + the block-decode row (2.4x), via `atproto-bench/go-jss` driving their + `segment` package on the same sealed-segment shape. - The live network runs ~200-450 events/s. Every row above is in the millions/s: CPU is not the live tail's bottleneck for either - implementation. Where the margin actually pays: bootstrap decode+verify - (SDK-level: zat 249K frames/s CID-verified vs 91K for the fastest Go SDK - measured in atproto-bench), replay serving, compaction/rebuild scans, and - box size for the same workload. + implementation. Where the margin actually pays: replay serving, cold + fan-out, compaction/rebuild scans, and box size for the same workload. - Nothing here is a promotion gate; parity rows marked NOT clean need a matched-shape bench before being quoted as a ratio.