@@ -266,10 +266,40 @@ project on a memory-constrained machine. All job counts produced
266266identical findings (verified via ` diff ` ), including on the demo project
267267run directly on this VM.
268268
269- This is still closer to "two honest data points" than a real benchmark
270- suite -- see [ ` docs/spec.md ` ] ( docs/spec.md ) §14 for what a full suite
271- (synthetic corpus, cold/warm, scaling * and* memory as first-class
272- dimensions, regression gating) would still need to add.
269+ ### Synthetic corpus: cold vs. warm cache
270+
271+ The spdlog and scaling numbers above are real projects, but both are
272+ external dependencies -- reproducing them means cloning something else
273+ first. [ ` benchmarks/synthetic-corpus/ ` ] ( benchmarks/synthetic-corpus/ ) is
274+ a self-contained alternative generated entirely from templates at CMake
275+ configure time: 30 independent unit pairs (60 TUs), each reproducing the
276+ same seven-rule bug pattern as ` tests/projects/multi-rule ` , for an exact,
277+ predictable 210 total findings (30 per rule) -- a built-in correctness
278+ check on the run, not just a timing number.
279+
280+ Measured on the same 8-core Apple M3, ` --jobs 1 ` (isolating the cache
281+ effect from parallelism), average of 3 runs each, fresh ` --cache-dir ` per
282+ cold run vs. one warm cache reused across all three warm runs:
283+
284+ | | Wall clock | Peak RSS |
285+ | ---| ---| ---|
286+ | Cold (no cache) | 12.68 s | ~ 171 MiB |
287+ | Warm (full cache hit, 60/60 TUs) | 0.87 s | ~ 34 MiB |
288+
289+ ~ 14.6x speedup. All six runs (3 cold + 3 warm) produced byte-for-byte
290+ identical findings (verified via ` diff ` ), and every run reported exactly
291+ 210 findings, confirming the corpus's own self-check. Cold-run peak RSS
292+ varied more than expected across repetitions (128-213 MiB) -- likely
293+ ordinary background load on a shared dev laptop rather than anything
294+ corpus-specific, included here rather than smoothed over.
295+
296+ This is now three real, reproducible data points (one external project,
297+ one scaling study, one fully self-contained corpus) rather than "two
298+ honest data points" -- what's still missing from a complete benchmark
299+ suite is CI-enforced regression gating (fail a run if wall-clock or peak
300+ RSS regresses past some threshold), which folds naturally into the CI
301+ matrix work in [ ` docs/spec.md ` ] ( docs/spec.md ) §14's next item rather than
302+ being its own benchmark-only milestone.
273303
274304## Known limitations
275305
0 commit comments