← board

uforth's ANS word-set suite: 13 of 13 identical, and gated

uforth ships the Forth 2012 test suite (tests/, from forth2012-test-suite 0.15.0) — the John Hayes ANS tester plus per-word-set programs. tests/runtests.fth is its master runner. This is far more thorough than the _drv_*.fth files, and it was NOT being measured: the drivers reach only 9 of the suite's files, and core.fr is not among them.

Measured 2026-08-08, each word set run under a generated driver (prelimtest + tester.fr + utilities + errorreport + the suite), pxx's binary against CPython running the same uforth.py:

word set verdict
core.fr (Hayes ANS core) IDENTICAL
coreplustest.fth IDENTICAL
doubletest.fth IDENTICAL
exceptiontest.fth IDENTICAL
facilitytest.fth IDENTICAL
localstest.fth IDENTICAL
memorytest.fth IDENTICAL
searchordertest.fth IDENTICAL
stringtest.fth IDENTICAL
coreexttest.fth IDENTICAL — was SEGFAULT, fixed 2026-08-08
blocktest.fth IDENTICAL — was SEGFAULT, fixed 2026-08-08
toolstest.fth IDENTICAL — was HANG, fixed 2026-08-08
filetest.fth IDENTICAL — was wrong output, fixed 2026-08-08

runtests.fth end to end: pxx dies at line 71 of CPython's 253, inside coreexttest — after correctly printing "End of Core word set tests" and "End of additional Core tests". The core word set really does pass.

Three distinct failures, not one — confirmed, and they really were three

The guess in the original filing was that coreext and block shared a cause because both died at output line 43. They did not. Each was bisected to its own minimal repro:

Swept end to end after all four fixes: every one of the 13 is byte-identical. The gating gap below is closed too: test-uforth now generates a driver per word set into the uforth checkout, runs all 13 differentially, and cleans up — 17/17 corpora, measured end to end. Drivers are generated rather than committed so the corpus can never again depend on files that exist on one box.

blocktest costs ~240s under pxx against CPython's ~80s and is essentially the entire ~6 minutes this adds; that belongs to whoever places test-uforth in a tier.

Four failures, four unrelated causes. The original filing guessed coreext and block shared one because they died at the same output line, and guessed file's two symptoms were two bugs. Both guesses were wrong in the same direction: where the failures group is not evidence about where the causes group.

The gating gap this exposes

make test-uforth now runs 10 corpora differentially, but they are the _drv_*.fth drivers plus the RC4 .for files — core.fr and the other ANS word sets are not among them, because uforth ships no driver for them. So the single most valuable suite in the tree passes and is ungated.

Adding them needs a driver per word set. Generating one into a scratch dir does not work as-is: INCLUDED resolves relative paths through uforth's own resolve_path, so a driver outside the uforth tree cannot reach prelimtest.fth. Either generate the drivers INTO the uforth checkout (and clean up), or ask uforth for permanent _drv_core.fth-style files — the latter is cheap and is how the existing seven got there.

Pairs with [[feature-t-enroll-uforth-in-the-tiers]]: enrolling a corpus that omits the core word set would lock in a flattering number.

Gate

All 13 word sets byte-identical to the CPython run, runtests.fth end to end identical, and the passing ones added to UFORTH_CORPUS so they stay that way.

Log