Repository navigation
Conversation
The compile sample was every 32nd entry of the run's live clean list, so one spec counted clean that the baseline did not hold shifted every later pick by one. specs/tri/phi_utils_multi.tri is at baseline index 447, one before the slot at 448, and its output does not compile. All nine codegen-corpus reds on main from 09-24 to 10-04 name it, and e6eac09 was red on push and green on schedule. - Slot k is baseline entry k * stride, so the sample is a function of the commit's baseline only. - Clean now needs the generator to exit 0 and leave a non-empty regular file. vibee_gen prints "Behaviors: N" before generating and exits 0 when it cannot write or produced 0 bytes; zig ast-check on a missing file says "error: unable to open file", which has no ": error: ", so such a spec counted as clean. - ast-check must also exit 0. - The output file is deleted before each generation, and its path mirrors the spec path: flattening '/' to '_' sent specs/storm/main.tri and specs/storm_main.tri to one file. - The clean count, regressed, new-clean and no-output specs are printed on both paths, by name. - codegen.yml records the runner's CPU model; vibee_gen is built for the native CPU. Fixes #885. Refs #851 (W15). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
X Brain Health CheckScore: 100.0/100 X Brain is above merge threshold |
🧪 Brain Stress Test ResultsScore: not measured (no stress test prints a Score: line) X Stress test passed |
The first CI run of the strict tool (run 37242677263) reported 769 of 1033 specs clean against a baseline of 788: 19 regressed, 0 new clean, and all 19 "reported behaviours and left no file". They were in the baseline only because the old tool ran `zig ast-check` on the missing output, and "unable to open file" has no ": error: " in it. 18 of the 19 declare `language: varlog`. Reading vibee_gen.zig (not running it), those go to the Verilog backend; the run measured that it then exits non-zero or leaves no file at the .zig destination, but not which. The 19th, specs/tri/long_context_system.vibee, declares `language: zig` and also leaves nothing. That log cannot say why, so NO OUTPUT now prints the exit status and the generator's last error line instead of "exited non-zero or left no file". The baseline becomes the old one minus exactly those 19, in order: 769 entries, which is the clean set the strict run measured. 15 of the 19 sort before specs/tri/phi_utils_multi.tri, so it moves from index 447 to 432; with stride 32 the slots near it are 416 and 448, so it is still not sampled. describeFailure has a unit test; a mutant that prefers the last stderr line over the last error line fails it. Refs #885, #886. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The first CI run of the strict tool (run 37242677263) reported 769 of 1033 specs clean against a baseline of 788: 19 regressed, 0 new clean, and all 19 "reported behaviours and left no file". They were in the baseline only because the old tool ran `zig ast-check` on the missing output, and "unable to open file" has no ": error: " in it. 18 of the 19 declare `language: varlog`. Reading vibee_gen.zig (not running it), those go to the Verilog backend; the run measured that it then exits non-zero or leaves no file at the .zig destination, but not which. The 19th, specs/tri/long_context_system.vibee, declares `language: zig` and also leaves nothing. That log cannot say why, so NO OUTPUT now prints the exit status and the generator's last error line instead of "exited non-zero or left no file". The baseline becomes the old one minus exactly those 19, in order: 769 entries, which is the clean set the strict run measured. 15 of the 19 sort before specs/tri/phi_utils_multi.tri, so it moves from index 447 to 432; with stride 32 the slots near it are 416 and 448, so it is still not sampled. describeFailure has a unit test; a mutant that prefers the last stderr line over the last error line fails it. Refs #885, #886. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The fix arm now carries 02b9958: the strict tool, which names why a spec left no file, and the baseline without the 19 entries that never wrote a .zig. The main arm keeps main's tool and main's 788. nonbase-dir skipped nothing that already wrote no file, so on the new baseline it would have picked specs/fpga/blink.tri, which leaves no file unblocked; arm 3 would then have equalled arm 1. It now requires a non-empty file from an unblocked probe, and both arms pick the same spec: the 19 are in main's baseline and are skipped on the fix side. Not for merge. Refs #885, #886. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
tools/codegen_ab_pick.py and the workflow are byte-identical to exp/corpus-ab-fix again. nonbase-dir now requires a non-empty file from an unblocked probe, so the spec it blocks is one whose output the block actually removes. Main's tool and main's 788-entry baseline are unchanged on this branch. Not for merge. Refs #885, #886. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
#886's own run on 02b9958 (37243448031) printed the reason for all 19 NO OUTPUT specs as "signal 6, no file, ???:?:?: 0x1571044 in ??? (???)": the generator aborts, and the last stderr line of a Zig panic is a frame with no symbols. describeFailure now prefers the last line holding "panic: ", then an error line, then the last line. A mutant that ranks error lines above the panic fails the new test case. Correction to 02b9958's message. It said the 19 were in the baseline because the old tool ran `zig ast-check` on the missing output, and that the tool could not tell a non-zero exit from a missing file. Both parts are wrong or out of date: * All 19 end in SIGABRT (signal 6): measured in probe run 37242067946 and again in 37243448031 above. * 18 of them -- specs/fpga/*, specs/tri/bitnet_mac, specs/tri/fpga/*, specs/tri/trinity_ai_core, specs/tri/trit_alu, specs/uart/* -- leave an EMPTY file, not a missing one. `zig ast-check` passes an empty file with exit 0, so the old tool counted them clean through the empty file. Only specs/tri/long_context_system.vibee leaves no file, and it does so in 59 of 60 runs, not always. The 18 empty-file specs are the Verilog-target ones. Why they abort is read from the generator's source, not measured, and is filed separately as a compiler change. Refs #885, #886. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
#886's own run on 02b9958 (37243448031) printed the reason for all 19 NO OUTPUT specs as "signal 6, no file, ???:?:?: 0x1571044 in ??? (???)": the generator aborts, and the last stderr line of a Zig panic is a frame with no symbols. describeFailure now prefers the last line holding "panic: ", then an error line, then the last line. A mutant that ranks error lines above the panic fails the new test case. Correction to 02b9958's message. It said the 19 were in the baseline because the old tool ran `zig ast-check` on the missing output, and that the tool could not tell a non-zero exit from a missing file. Both parts are wrong or out of date: * All 19 end in SIGABRT (signal 6): measured in probe run 37242067946 and again in 37243448031 above. * 18 of them -- specs/fpga/*, specs/tri/bitnet_mac, specs/tri/fpga/*, specs/tri/trinity_ai_core, specs/tri/trit_alu, specs/uart/* -- leave an EMPTY file, not a missing one. `zig ast-check` passes an empty file with exit 0, so the old tool counted them clean through the empty file. Only specs/tri/long_context_system.vibee leaves no file, and it does so in 59 of 60 runs, not always. The 18 empty-file specs are the Verilog-target ones. Why they abort is read from the generator's source, not measured, and is filed separately as a compiler change. Refs #885, #886. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… lines (#885) Run 37243963781 on d959eb7 printed the panic line for 18 of the 19 aborting specs: signal 6, no file, thread 2978 panic: programmer bug caused syscall error: FAULT That confirms #887's inference: the Verilog path writes freed memory, the write gets EFAULT, and the standard library panics. It also showed two defects in what this gate prints: - "no file" was printed for any file that was not non-empty. The probe (37242067946) found that 18 of the 19 leave an EMPTY file, which is a different failure: the file was created and the write then died. The gate's own wording repeated the mistake 02b9958's message made. The generator's result is now one of none / empty / nonempty, and the reason says "no file" or "empty file". The summary line says "wrote no usable file" instead of "left no file". - specs/tri/long_context_system.vibee still printed only a stack frame, so its stderr has no "panic: " line. Zig 0.16's segfault handler prints "Segmentation fault at address 0x..." (std/debug.zig), then aborts. Lines starting with any of the handler names now count as crash lines. Which line long_context_system prints is not known yet; the next run says. The describeFailure test now uses the measured panic line, checks that an empty file is named as such, and adds a crash-handler case. Two mutants, each caught by exactly one assertion: - ignoring crash-handler lines: picks the earlier error line; - naming an empty file "no file". Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
#873 and #886 conflict with each other in How it was found: a trial merge of the 20 open loop PRs onto main 57de4a1, in the proposed order, done in git's object store only ( A tested resolution is on
Verified:
Not verified: no COULD NOT RUN or DOES NOT COMPILE line fired in that run, so the merged failure messages have run only in the unit tests, not in CI. When the first of the two merges, the second can take 3d94723's 🤖 Generated with Claude Code |
…baseline sample #873's d02f21e replayed onto #886 (fix/codegen-corpus-sample b937408). The two PRs edit the same three places in tools/codegen_corpus.zig; this is the resolved tree, so whichever merges second has a tested resolution. Resolution: - sample and stride come from #886 (the committed baseline), and could_not_run from #873 is declared next to them; - the failure message keeps #873's four counts, with #886's denominator: picked.items.len, the slots that were still clean and were compiled; - the COULD NOT RUN message uses picked.items.len as its denominator too (#873 used sample, which counts slots dropped as regressed). Local, Zig 0.16.0 with the shim modules from main: zig test 7/7 (both PRs' tests, including the positive and negative controls), zig build-exe links, zig fmt --check clean. Refs #871, #885, #851. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
b937408 to
728130a
Compare
Dispatch-only. Four arms of zig build codegen-corpus on one runner: plain, one extra clean spec before phi_utils_multi, a non-baseline spec that cannot write its output, and a baseline spec at an unsampled index that cannot write its output. exp/corpus-ab-main and exp/corpus-ab-fix carry this workflow and tools/codegen_ab_pick.py unchanged and differ only in tools/codegen_corpus.zig. Not for merge. Refs #885, #886. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The fix arm now carries 02b9958: the strict tool, which names why a spec left no file, and the baseline without the 19 entries that never wrote a .zig. The main arm keeps main's tool and main's 788. nonbase-dir skipped nothing that already wrote no file, so on the new baseline it would have picked specs/fpga/blink.tri, which leaves no file unblocked; arm 3 would then have equalled arm 1. It now requires a non-empty file from an unblocked probe, and both arms pick the same spec: the 19 are in main's baseline and are skipped on the fix side. Not for merge. Refs #885, #886. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Dispatch-only. Four arms of zig build codegen-corpus on one runner: plain, one extra clean spec before phi_utils_multi, a non-baseline spec that cannot write its output, and a baseline spec at an unsampled index that cannot write its output. exp/corpus-ab-main and exp/corpus-ab-fix carry this workflow and tools/codegen_ab_pick.py unchanged and differ only in tools/codegen_corpus.zig. Not for merge. Refs #885, #886. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
tools/codegen_ab_pick.py and the workflow are byte-identical to exp/corpus-ab-fix again. nonbase-dir now requires a non-empty file from an unblocked probe, so the spec it blocks is one whose output the block actually removes. Main's tool and main's 788-entry baseline are unchanged on this branch. Not for merge. Refs #885, #886. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Summary by t27-beesThe PR fixes a flaky Worth a look
Read: 3 files, +288 -48, the whole diff. Head |
Fixes #885. Part of #851, weak point W15. The generator crash it uncovered is #887.
Why
codegen-corpuson branchmainwas red 6 times from 09-24 to 10-04. Five of those failed onDOES NOT COMPILE: specs/tri/phi_utils_multi.triwith0 spec(s) regressed:main's head57de4a1f5.The sixth, 36515512024, was the
vsa_simdbenchmark test.Correction: an earlier version of this description said
mainwas red 9 times. #885's table of 9 counts every ref: 5 onmainand 4 on PR branches, all onphi_utils_multi. On branchmainalone the API count (codegen.yml,branch=main) is the 6 above.The compile sample was every 32nd entry of the run's clean list.
phi_utils_multisits at index 447, one before the slot at 448. Any one extra spec counted clean before it moves it into the sample, and its output genuinely does not compile.Main's tool could count a spec clean without clean output in two ways:
zig ast-checkprintserror: unable to open file …and exits 1. That line has no: error:, and that string was allastCheckOklooked for.zig ast-checkpasses a 0-byte file with exit 0, and so doeszig test.What changes
tools/codegen_corpus.zig:k * stride, with the stride computed from the baseline length, so the sample depends on the commit and nothing else. A regressed entry is skipped, because it has already failed the gate.zig ast-checkexits 0 and prints no: error:./to_sentspecs/storm/main.triandspecs/storm_main.trito the same file.REGRESSED,NEW CLEANandNO OUTPUTspec by name.NO OUTPUTsays why: the exit status or signal,no fileorempty file, and the generator's crash line (apanic:line or a crash handler'sSegmentation fault …), else its last error line, else its last line.parseBehaviours;outPathForis one-to-one;describeFailure.tools/codegen_corpus_baseline.txt, 788 → 769. The 19 entries removed never wrote a usable.zig:language: varlogspecs. The generator aborts with SIGABRT after creating the file, leaving 0 bytes, and main's tool passed them through the empty file.specs/tri/long_context_system.vibeeaborts and leaves no file in 59 of 60 runs.phi_utils_multimoves from index 447 to 432. The slots are multiples of 32, so it is still not sampled..github/workflows/codegen.ymlprints the runner's CPU model.Every added
iftests a named bool.Measured
A/B, same four arms on one runner per tool (the
exp/corpus-ab-*branches carry an identical helper and workflow):phi_utils_multiDOES NOT COMPILE phi_utils_multiNEW CLEANnames itspecs/algo/adam.tri) cannot writeREGRESSED: specs/algo/adam.triThe earlier main-arm run 37242996093 gave the same four results.
Probe 37242067946 (
exp/codegen-flake-ab): 60 passes over all 1033 specs with behaviours, removing the destination before each generation.All 19 removed entries end in signal 6. The 18 Verilog specs leave an empty file every time.
Two specs vary between passes:
specs/tri/long_context_system.vibeespecs/tri/hdc_stream_classifier.vibeeCompile-all: 13 of the 769 written outputs pass
ast-checkand failzig test. 9 of them lack thevsamodule. None falls in the sample; the details are in vibee_gen aborts (SIGABRT) on 18 Verilog specs and intermittently on 2 Zig specs #887.This PR's CI:
02b9958de(run 37243448031):769 of 1033 specs with behaviours clean, baseline 769,0 regressed, 0 new clean, 19 reported behaviours and left no file, and the sample compiled 24 of 24. EveryNO OUTPUTreadsignal 6, no file, ???:?:?: 0x1571044 in ??? (???): a stack frame with no symbols, which says nothing.d959eb722makes the panic line win.d959eb722(run 37243963781): the same counts. All 18 Verilog specs readpanic: programmer bug caused syscall error: FAULT, still labelledno file.long_context_systemprinted no panic line, so it still showed a frame.b937408ce(run 37244594555): the same counts, 0 regressed, and the sample is clean. The 18 now readsignal 6, empty file, thread … panic: programmer bug caused syscall error: FAULT.long_context_systemreadssignal 6, no file, Segmentation fault at address 0x7fee7103b2a2.orphan-artefactsanddoc-refsare red here. They fail on gft_mul: the product wire is 32 bits and GF-T32 needs 52 #510'sresearch/arxiv_gftfiles and gft references, and are red onmainat57de4a1f5as well (37225448159, 37225448197); fix(gates): green doc-refs and orphan-artefacts on main after #510 #872 fixes them. Of the 64 checks onb937408ceat about 23:48Z on 2026-10-04, those 3 failed (orphan-artefactsran twice), 55 passed, 5 were skipped and📊 Export Brain Metricswas still running.Likely natural trigger on main (inference, not proven)
hdc_stream_classifieris not in the baseline, reports behaviours, and sorts beforephi_utils_multi. When it aborts without a file, main's tool counts it clean. That shiftsphi_utils_multionto slot 448, which is arm 3 above, occurring naturally.An abort rate of 3 in 60 is consistent with 5 phi-red runs out of 66. But main's tool printed no names on red, so no past run can confirm it. This PR removes the mechanism whatever the trigger was.
Not measured
EFAULTpanic in the write, vibee_gen aborts (SIGABRT) on 18 Verilog specs and intermittently on 2 Zig specs #887).long_context_systemsegfaults (run 37244594555), but where is not known;hdc_stream_classifierdid not abort in any of this PR's 4 codegen runs (19NO OUTPUTlines each).Checked locally
zig fmt --checkpasses.zig testpasses 3/3 againsttri_io/tri_proc/tri_envfromorigin/main.describeFailure, each caught by its own failing assertion:no file.🤖 Generated with Claude Code