Race -L and the file list in the benchmark suite

The numbers for -L and for a long file list lived in a scratch harness,
so nothing in the repository would fail if either regressed. The lines
suite now races -L at 1M and 10M lines against every oracle, and ends
with 128 files holding 12.8M lines counted in one invocation, which is
where the worker pool lives.

The file-list check compares the row count and the total row's numbers
rather than the whole output: busybox and toybox pad their columns
differently, and an exact string compare would fail on their formatting
instead of on our arithmetic.
This commit is contained in:
2026-11-15 13:58:13 -05:00
parent 47188fbef1
commit 9b68ad4c6c
4 changed files with 66 additions and 3 deletions
+5
View File
@@ -287,6 +287,11 @@ make bench # build release + run every suite
./benchmarks/test-all.sh # words, lines (monsters included), stdin
```
The lines suite races `-L` as well as `-l`, and ends by counting 128
files of about 1.1 MB each, which is the worker pool's case: both sides
finish in well over a second's worth of work, so the row is a race and
not a startup measurement.
`test-all.sh` compiles its two helper tools on the spot
(`tools/genfile` for the test data, `tools/timeit` for microsecond
timing) — no separate setup. The suites live in