Skip to content

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

Closed

Description

@gHashTag

Refs #6434
Refs #6063

Problem

"mismatch 0" on the t27b lab is not a comparison with the reference path.

  • In cli/t27b/src/main.rs (the --check block), MISMATCH means the JIT disagrees with eval.rs::Interp. Both read the same IR from lower.rs. If lower.rs mistranslates t27 semantics (wrap vs trap, promotion, float rounding, layout), both sides compute the same wrong thing and agree.
  • The only comparison with the reference is per file. blockers.rs::parse_test_report keeps only the tests and FAIL totals of t27c test-report, even though t27c already prints each test's outcome (bootstrap/src/test_report.rs, Report.outcomes).
  • steward.t27 is_alarm(fail, fail) is false, so the 7 files where both fail (lab run 03362c1) count as agreement without checking that the same test failed. Example: specs/port/trinity/src/tri/gen_vector2d.t27: t27b fails Vec2_length with assert_eq left 4627730092099942521 vs right 4627730092099895296 (one f64 ulp). The reference says only "1 of 4 tests fail".
  • Stop::Fuel and Stop::Depth are also counted as agreement whatever the JIT did.

Change

  1. parse_test_report returns the per-test outcome list. The reference cache stores it (new row format; old rows are read as file-level only).
  2. t27b corpus --reference compares test by test. A test whose t27b verdict differs from the reference verdict is ref_mismatch, a new verdict counted in summary.ref_mismatch and treated by the doctor as LAB-MISMATCH.
  3. steward.t27 is_alarm judges per test when per-test data exists.
  4. Interpreter Fuel/Depth stops report unknown, not agreement.

Done when

  • The lab JSON carries ref_mismatch per file and in the summary, and the 7 fail/fail files show which tests disagree, if any.
  • steward.t27 has tests for the per-test is_alarm.
  • New subcommand tri t27b diff <spec> prints both verdict lists side by side.

🤖 Generated with Claude Code

Activity

  1. gHashTag commented on Oct 5, 2026

    @gHashTag
    OwnerAuthor

    First measured reference_disagree on master, from branch t27b-refdiff-20261005T1500 (de50cbd = master 36ad787 plus this change). Run by hand on the Railway t27b lab container at 2026-10-05 15:39-15:47Z: qemu-aarch64 t27b corpus specs --blockers --reference t27c --jobs 12 --timeout-ms 60000. Corpus exit 0.

    • reference_disagree 0 files, 0 tests, of 668 files compared test by test. That is 2466 tests per side, and both sides have the same test names.
    • jit_interp_mismatch (old mismatch) 0.
    • Reference: 722 pass, 25 fail, 509 blocked, 4 timeout. t27b: 380 pass, 281 pass_vacuous, 8 fail, 552 blocked, 37 frontend.
    • All 7 files that fail on both sides fail the same single test. gen_vector2d.t27 fails Vec2_length on both, so the file-level agreement was right this time. The others are timing_tb, build_verify, gf16_dot4, check-first-party-doc-language, gen_w392 and search/pattern.
    • Not compared: specs/ui/viewport.t27. t27b fails rail_capacity_follows_the_css_budget, but the reference is blocked, so there is no reference verdict to compare it with.

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

    The branch is pushed and has no PR. The owner's rule from 2026-10-05 ~15:45Z forbids hand-written non-t27 code in new PRs. The branch contains the following:

    • The steward's decision, in t27: is_alarm_tests and lanes_stop in specs/tri/t27b/steward.t27. gen/c/tri/t27b/steward.c was regenerated, and tri t27b gen-check on the t27c lab says SAME 904af7fc1f22.
    • Hand-written glue in Rust (cli/t27b/src/{blockers,main}.rs and tests) and Python (lab.py, t27b.py, t27b_rules.py, CI tests).

    Refs #6063

  2. added a commit that references this issue on Oct 5, 2026
    1c09750
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

    priority/highMust fix before next milestone

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions