Skip to content

meta(ci/bench): restore trustworthy publishing and populate reld on every platform #68

Closed

Description

@zackees

Context

The README embeds three charts from the generated benchmark-stats branch and says Linux measures reld natively while Windows/macOS render reld as explicit pending until their bridge measurements land. The repository now has the schema and coverage policy for that distinction (#63), but the public artifact does not reflect it:

  • benchmark-stats was last published on 2026-08-07 from source SHA 4291003; the README images therefore predate meta: benchmark linker-coverage integrity — no silent n/a (gate expected linkers, mark pending explicitly) #63 and still render Windows/macOS reld as n/a rather than pending.
  • The latest twelve scheduled Benchmark Stats runs are red. In the current failure (run 32631733499), Windows measures the small and medium scenarios, but both expected reference linkers fail for large (512 units). The coverage gate correctly rejects the run, so the aggregate job cannot publish any target.
  • The raw Windows benchmark log reports both failures only as spawning linker. reld-bench passes every object path directly through Command::args(objects) in both generated and replay modes (crates/reld-testkit/src/bin/reld-bench.rs, link_once / link_once_replay). Because 16 and 128 objects succeed while 512 objects fail at process spawn on Windows, the leading diagnosis is the Windows command-line-length limit. The current top-level-only error formatting hides the underlying OS error, so the fix must preserve the full cause chain and prove the diagnosis RED -> GREEN.
  • Linux already has real native reld timings in the stale published data. Windows and macOS reld remain intentionally unmeasured: .github/workflows/benchmark-stats.yml builds/installs a reld shim only on Linux and passes --reld-pending on the other hosts. This is the unfinished benchmark slice of Bridge linkers: run + benchmark reld on Windows and macOS now by delegating to lld (rust-lld) per platform #17, not evidence that the bridges cannot link; their end-to-end and self-host jobs are already green.
  • Main CI is independently red after Validate linker modes across Linux, Windows, and macOS #67 (run 32222356951). The focused linker-plugin-lto test passes immediately before the aggregate acceptance suite, then the aggregate suite fails because rustc cannot find temporary LTO objects. verify_linker_plugin_requirements gives every same-architecture invocation the shared output /tmp/rust-{arch}.out, which is unsafe under the parallel acceptance runner. The always-run phase summary then emits a second failure because downstream log files do not exist.

This meta tracks the complete path from red CI and stale/misleading charts to current, continuously published, real reld measurements on all three platforms. It does not weaken the no-silent-n/a policy established by #63.

Proposal

1. Restore a green, diagnosable benchmark pipeline

  • Add a response-file path for large object/input lists in reld-bench; use it in both link_once and link_once_replay so generated and frozen corpora have identical Windows-safe behavior.
  • Implement platform-correct response-file quoting/encoding and keep the output path plus linker-selection arguments outside or inside the response file according to the compiler driver's supported contract.
  • Preserve the full anyhow/source error chain in benchmark failure comments and job logs (for example, formatted with {error:#}), while retaining the existing single-line/length/safety sanitization for HTML comments.
  • Add a focused Windows repro that fails before the change with an oversized link command and turns green with response-file invocation. Add unit coverage for quoting paths containing spaces, quotes, and non-ASCII characters.
  • Keep ci.benchmark_coverage strict: expected linkers must produce every scenario, pending series must be explicit, and a failed expected series must continue blocking publication.
  • Dispatch the real three-host workflow after the fix. Confirm all benchmark matrix jobs and aggregation succeed, benchmark-stats advances from its 2026-08-07 commit, and the README images resolve to the newly generated artifacts.

2. Repair main CI's parallel LTO verifier race

  • Replace /tmp/rust-{arch}.out in verify_linker_plugin_requirements with an invocation-unique temporary directory/output that stays alive through the rustc process and is cleaned afterward.
  • Add a focused concurrent regression test or deterministic stress repro that runs the same-architecture verifier in parallel: RED with the shared output, GREEN with isolated paths.
  • Make ci/phase1_summary.py / its workflow invocation tolerate explicitly absent downstream logs after an earlier step fails, while still failing for malformed or incomplete logs that were expected to exist on a successful path.
  • Rerun the full Linux acceptance job, not only the isolated LTO test, and require the post-merge/default-branch CI result to be green.

3. Publish real Windows/macOS reld bridge measurements

Complete the remaining benchmark work in #17 instead of leaving permanent pending cells:

4. Make the public result observable and drift-resistant

5. Close the tracking loop

Acceptance criteria

  • RED -> GREEN: a focused Windows repro demonstrates the 512-object direct-argv spawn failure, then passes through the response-file implementation for link.exe, lld, and the replay path.
  • Link failures expose the underlying OS/linker cause rather than only spawning linker; HTML/log sanitization remains bounded and safe.
  • The Benchmark Stats workflow is green on Linux, Windows, and macOS, including aggregation and default-branch publication.
  • benchmark-stats contains a new commit sourced from current main, and all three README charts show a current generated timestamp/source SHA.
  • Linux publishes measured native reld timings for every scenario.
  • Windows and macOS publish measured reld bridge timings for every scenario, labeled bridge with the concrete engine; neither platform contains reld pending or bare n/a after the measurement slice lands.
  • Every expected linker produces every scenario; deliberately breaking one expected series makes the coverage gate fail and prevents publication.
  • RED -> GREEN: concurrent same-architecture LTO verifier invocations reproduce the shared-output collision before the fix and pass with unique temporary outputs afterward.
  • The full Linux acceptance job and a post-merge/default-branch CI run are green; the summary path does not emit misleading secondary missing-log failures.
  • Job logs and $GITHUB_STEP_SUMMARY show per-target timings/status, source SHA, generation time, and whether/where artifacts were published.
  • A regression test proves stale generated artifacts or disagreement between README prose/chart/JSON status cannot remain silent.

Decisions

Related issues

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions