Skip to content

feat(t27b): per-test reference verdicts, reference_disagree apart from jit/interp mismatch - #6530

Merged
gHashTag merged 1 commit into
masterfrom
t27b-refdiff-20261005T1500
Oct 5, 2026
Merged

gHashTag merged 1 commit into
masterfrom
t27b-refdiff-20261005T1500

Conversation

@gHashTag

@gHashTag gHashTag commented Oct 5, 2026

Copy link
Copy Markdown
Owner

Closes #6441
Refs #6063

Problem

t27b's mismatch compares t27b's JIT with t27b's own interpreter. Both run lower.rs's IR, so a lowering defect they share agrees with itself. The only comparison with the reference (t27c + zig) was per file: a file both sides failed counted as agreement even when different tests failed.

Change

  • cli/t27b/src/blockers.rs:
    • parse_test_verdicts reads t27c test-report --verbose per test.
    • t27b_verdicts names repeated tests the way t27c does (__dupN).
    • disagreements lists the differences.
    • Reference cache rows carry a tests= field. Old rows are re-run.
  • cli/t27b/src/main.rs, corpus --reference:
    • JSON totals: jit_interp_mismatch (same value as mismatch, kept for back-compat), reference_disagree (files), reference_disagree_tests and reference_compared.
    • Per record: test_verdicts, reference_tests and reference_disagree.
    • Exit 4 when either count is non-zero.
  • specs/tri/t27b/steward.t27:
    • is_alarm_tests: a shared fail is no alarm only when the same tests fail.
    • lanes_stop: a jit/interp mismatch or a reference disagreement stops the lanes.
    • 9 new tests and 1 invariant, 120 tests in all.
    • gen/c/tri/t27b/steward.c regenerated. tri t27b gen-check on the t27c lab: SAME 904af7fc1f22.
  • tri t27b:
    • status shows jit/interp mismatch and reference disagree on their own line.
    • doctor raises LAB-REF-DISAGREE.
    • New tri t27b diff SPEC [--run R] prints both verdict lists side by side.
  • contrib/railway/t27b-lab/lab.py does the same per-test merge. It takes effect after a lab redeploy.
  • scripts/ci/test_the_t27b_steward_decides_in_t27.py no longer pins "N tests passed". It counts the spec's test blocks, so a spec-only PR that adds tests cannot break it.

Measurement

Branch build on the Railway t27b lab, 2026-10-05 15:39-15:47Z: qemu-aarch64 t27b corpus specs --blockers --reference t27c --jobs 12, exit 0.

  • reference_disagree: 0 files, 0 tests, over 668 files and 2466 tests compared. jit_interp_mismatch: 0.
  • All 7 files that fail on both sides fail the same single test on both sides. gen_vector2d.t27 fails Vec2_length on both.
  • specs/ui/viewport.t27 was not compared: the reference is blocked on it.

No disagreement was found, so no root-cause issues were filed.

Owner exception

Hand-written Rust/Python allowed by the owner on 2026-10-05 (chat: fix it, do what is best). Debt to be replaced by t27-generated code under #6198.

Kind Files
t27 specs/tri/t27b/steward.t27
Generated gen/c/tri/t27b/steward.c (t27c gen-c, from the t27c lab)
Hand-written Rust cli/t27b/src/blockers.rs, cli/t27b/src/main.rs, cli/t27b/tests/blockers.rs, cli/t27b/tests/refcache.rs
Hand-written Python contrib/railway/t27b-lab/lab.py, scripts/tri_loop/t27b.py, scripts/tri_loop/t27b_rules.py, scripts/ci/test_the_t27b_steward_decides_in_t27.py, scripts/ci/test_a_t27b_tick_reads_before_it_acts.py
Prose docs/now/2026-10-05-t27b-reference-disagree.md

Verification

  • t27b blockers 10/10 and refcache 5/5, run locally and on the lab under qemu.
  • All five scripts/ci/test_*t27b*.py pass.
  • check_now_entry_shape OK.

Not in this PR: issue item 4 (an interpreter Fuel/Depth stop reported as unknown).

🤖 Generated with Claude Code

…m jit/interp mismatch

t27b's `mismatch` compares t27b's JIT with t27b's own interpreter. Both
run lower.rs's IR, so a lowering defect they share agrees with itself.
The reference comparison was per file: a file both sides failed counted
as agreement even when different tests failed.

- blockers.rs: parse_test_verdicts reads t27c test-report --verbose per
  test; t27b_verdicts names repeats like t27c's __dupN; disagreements;
  the reference cache rows carry a tests= field (old rows re-run).
- corpus --reference: reference_disagree (files) and _tests, counted
  apart; JSON totals add jit_interp_mismatch, reference_disagree,
  reference_disagree_tests, reference_compared; records carry
  test_verdicts, reference_tests, reference_disagree. Exit 4 on either.
- steward.t27: is_alarm_tests and lanes_stop with tests; gen/c steward.c
  regenerated (tri t27b gen-check on the t27c lab: SAME 904af7fc1f22).
- tri t27b status/doctor: honest line and LAB-REF-DISAGREE; tri t27b diff.
- steward CI test counts the spec's test blocks instead of pinning a number.
- lab.py mirrors the per-test merge (takes effect on the next redeploy).

Closes #6441
Refs #6063

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@gHashTag gHashTag added the owner-approved-foreign Owner-approved exception to the only-t27 rule: hand-written foreign code allowed in this PR label Oct 5, 2026
@gHashTag
gHashTag enabled auto-merge October 5, 2026 16:03
@gHashTag
gHashTag merged commit 12b49ca into master Oct 5, 2026
30 of 33 checks passed
@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-10-05 16:07:18 UTC

Summary

Status Count
Total Open PRs 50
PRs with Failing Checks 38
PRs with All Checks Green 12
READY 8
FAILING 38
PENDING 0
NO CHECKS YET 0

These columns do not partition: 8 + 38 + 0 + 0 = 46, and there are 50 open PRs. A PR is being counted twice or not at all.

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=9f2c8a4829f6 != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

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

Labels

owner-approved-foreign Owner-approved exception to the only-t27 rule: hand-written foreign code allowed in this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

t27b: per-test reference differential -- mismatch 0 today compares the JIT with an interpreter over the same IR

1 participant