Repository navigation
Description
Summary
We already render the benchmark chart JPG and publish it to the benchmark-stats branch, but the run itself is quiet: the numeric performance stats are never printed in the job, and the step that force-pushes the benchmark-stats branch does so with almost no logging. Make the benchmark job print the per-OS performance stats to the log (and step summary), and make the branch-population verbose about what it's doing.
Context (benchmark-stats.yml / ci/benchmark_stats.py)
Per target (x86_64-linux, x86_64-pc-windows-msvc, aarch64-apple-darwin) we generate benchmark-link.jpg, index.html (a scenario × linker seconds table), latest.json, and history.jsonl, then the aggregate job's Publish benchmark-stats branch step git push --forcees them to the benchmark-stats branch. To see the actual numbers today you must open latest.json/index.html on that branch — the Actions run shows nothing, and the publish step just runs git commands with no narration of what branch is being (re)populated with what.
Proposal
- Print the stats in the job. After running the benchmark (and in
aggregate), print a per-OS stats table to stdout and to$GITHUB_STEP_SUMMARY— median link time per scenario per linker (bfd/lld/mold/wild/reld), reld's speedup vs the reference (orn/a), plus the run metadata already inlatest.json(timestamp, runner platform, pinned linker versions). Reuse the numbersci/benchmark_stats.pyalready computes; add a--print/stdout rendering so the data is visible in the run, not only on the branch. - Be verbose about populating the branch. The publish step should clearly log: which branch it targets (
benchmark-stats), that it is a force-push of generated content, the list of per-target directories/files being published, the sourcegit_sha, and a one-line "published N targets to ()" summary. Guard messaging should also state plainly when publish is skipped (e.g. on a PR / non-default branch) rather than silently doing nothing.
Acceptance criteria
- Each benchmark run prints a readable per-OS performance-stats table to the job log and
$GITHUB_STEP_SUMMARY(numbers visible without opening the branch). - Stats are rendered from
latest.json/ the existingbenchmark_stats.pydata (no new measurement) and include run metadata +n/afor unavailable linkers. - The publish step logs the target branch, that it is force-pushing generated content, the files/targets published, the source SHA, and a final summary line — and logs an explicit "skipping publish (not default branch)" when guarded off.
- RED -> GREEN: a
ci/testscheck over the stats-printing path (e.g.benchmark_stats.pygains a stdout/summary renderer) that currently emits nothing, then prints the per-OS table from samplelatest.json.
Decisions
- Priority: P3. Observability improvement; the data and image publishing already work.
- Source of truth is
latest.json— pure rendering/logging change, no measurement changes. - No behavior change to what's published, only to what's printed and how loudly the publish is narrated.
Activity
zackees commentedon Aug 23, 2026
Completed by #69 and proven in Benchmark Stats run 32668402943 at
58066f9.Each target now prints its performance table and metadata to the log and step summary. The aggregate reports the source SHA, generated files/targets, force-publish operation, destination, and final publish outcome; the non-default-branch path reports an explicit skip. The rendering/reporting path is covered by the benchmark-stats tests, and the production run published successfully.