Skip to content

test(analog): 151 asserts on constant table elements now count, 13 specs, seals re-saved (Closes #12166) - #12191

Merged
gHashTag merged 3 commits into
masterfrom
lane/analog-assert-audit-12166
Oct 25, 2026
Merged

gHashTag merged 3 commits into
masterfrom
lane/analog-assert-audit-12166

Conversation

@gHashTag

Copy link
Copy Markdown
Collaborator

What

An assert on a module-constant table element, assert_eq(TABLE[i], K), is folded at compile time and tri test does not count it. This PR reads each such element into a var first, so the assert runs and is counted.

  • 13 analog specs edited, 151 asserts rewritten. Counted asserts across specs/analog: 86128 to 86279 (+151).
  • Audit note: docs/analog/assert-count-audit-2026-10-25.md.
  • 13 spec seals re-saved with a t27c built from master. Strict coverage of specs/analog/*.t27 reads gaps 0, coverage 130/130, tests 26/26, vacuous 0.

Anomaly found on the way

The first seal job used a t27c older than master's gen-zig and gen-rust commits: it moved 20 seals and strict coverage showed sar_logic (untouched here) as seal NO-MATCH. A master-equivalent t27c was built in a T27 OS pane (CARGO_TARGET_DIR=/Users/playra/t27-build/target-m2), the seals were restored and re-saved, and this time exactly the 13 spec seals moved and every importer check passed. The lesson is in PR #12189.

Not done

  • Only 13 of the 151 rewritten asserts (one per spec) were driven red by a negative control; the other 138 are shown live by the rise of the counted total only.
  • The scan for such asserts is a grep superset and misses asserts split over several lines or tables named in lower case; asserts on scalar constants were left alone on purpose.
  • No mutation re-run for sar_cdac and sar_comparator_psp; their accepted-file lines still name the same code, the edits sit below them.

Closes #12166

🤖 Generated with Claude Code

gHashTag and others added 3 commits October 25, 2026 10:07
…ecs, counted total 86128 to 86279 (Refs #12166)

An assert on a constant table element is folded by the compiler and tri test
counts it as no assert at all (found in sar_kick, fixed there by #12153).
Each such assert in the 13 other analog specs now reads the element into a
var and asserts on the var, with the expected value unchanged.

Measured with tri test per spec: the counted total of every spec rose by
exactly the number of asserts rewritten (151 in all), every spec passes, and
vacuous passes stay 0. Two negative controls per spec on scratch copies: one
wrong table element turns the holding test red, one wrong expected value turns
exactly the one test that holds it red. The note lists what is not claimed:
seals are not re-saved here, strict coverage and the mutation census are not
re-run, and the grep that found the candidates is a superset that misses
lower-case and multi-line forms.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
…aster-built t27c (Refs #12166)

Seals saved with a t27c built from master (CARGO_TARGET_DIR target-m2); strict coverage of
specs/analog reads gaps 0, 130/130. The first save used a t27c older than master's gen-zig
and gen-rust commits and moved 20 seals; this one moves exactly the 13 spec seals.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
…run (Refs #12166)

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-10-25 03:26:13 UTC

Summary

Status Count
Total Open PRs 49
PRs with Failing Checks 43
PRs with All Checks Green 6
READY 4
FAILING 43
PENDING 0
NO CHECKS YET 0

These columns do not partition: 4 + 43 + 0 + 0 = 47, and there are 49 open PRs. A PR is being counted twice or not at all.

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=55c0f1b1b32d != 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).

@gHashTag
gHashTag merged commit bf66e45 into master Oct 25, 2026
37 checks passed
@gHashTag
gHashTag deleted the lane/analog-assert-audit-12166 branch October 26, 2026 03:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

analog specs: count the constant-element asserts that tri test does not count (13 specs)

1 participant