Skip to content

crosslane_fuzz: a program the GPU harness hangs or crashes on no long… - #1231

Merged
ItsNotRexed merged 1 commit into
ItsNotRexed:mainfrom
Urban225:crosslane-fuzz-harness-timeout
Nov 22, 2026
Merged

ItsNotRexed merged 1 commit into
ItsNotRexed:mainfrom
Urban225:crosslane-fuzz-harness-timeout

Conversation

@Urban225

Copy link
Copy Markdown
Contributor

Claimed in the coordination issue as: new FUZZ item (crosslane_fuzz harness timeout), see my claim in #1218

What and why

When vk_compute_test timed out on one program, subprocess.TimeoutExpired escaped main(): the run
stopped with a traceback, every result before it was lost and the summary never printed. A missing dump
did the same through RuntimeError. Both are now a HarnessError for that one program: it is listed
with the other failures (and kept with --keep), counted as harness_errors in the summary, and the
run goes on. Exit code 2 when harness errors are the only failures, as in valu_fuzz.py and
lds_fuzz.py; 1 still means a mismatch or an untranslated program. --minimize treats a reduction
that hangs as "does not reproduce".

Found on an RX 7900 XTX (AMD proprietary 26.10.1, Windows 11, commit c63773d):
crosslane_fuzz.py --programs 200 --seed 7900 --w64-native --dpp timed out on cs_xl32_790023712
(wave32 native). Whether that hang is reproducible is a separate finding I am checking with this fix.

Tested

AI-assisted (Claude). Linux, Python 3.13, no GPU for the tests.

  • python -I tests/test_crosslane_fuzz.py: 23 tests pass. The 4 new ones fail on main.
  • python -m compileall -q tools tests
  • Not yet run against the real hang; I will post that result here.

Checklist

  • No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here.
  • A new translator rule is in the contract table of docs/design.md, with how it was confirmed. (n/a)

🤖 Generated with Claude Code

@kapitche

Copy link
Copy Markdown
Contributor

Tested b4d539b on Linux (WSL2 Ubuntu), Python 3.12, CPU only: pass.

  • pytest tests/test_crosslane_fuzz.py: 23 passed, 4 subtests. With tools/crosslane_fuzz.py from main, the 4 HarnessErrors tests fail.
  • A timeout or missing dump is now a HarnessError, recorded and skipped, and --minimize treats it as "doesn't reproduce". Exit codes: 1 on mismatch or untranslated, 2 when only harness errors, 0 otherwise. That matches valu_fuzz/lds_fuzz.

I didn't trigger a real GPU hang.

@Urban225

Copy link
Copy Markdown
Contributor Author

Follow-up on the real run, as promised. RX 7900 XTX, AMD 26.10.1, Windows 11, runtime rebuilt at this branch:

crosslane_fuzz.py --programs 200 --seed 7900 --w64-native --dpp now runs to the end and prints the summary, harness_errors 0 in all three modes. The timeout did not reproduce: cs_xl32_790023712 ran and matched this time, so the 60 s hang was transient (one occurrence in two runs of the same program), not a translated program that never ends.

So this PR is not demonstrated against a live hang, only by the unit tests. What it changes is still what the first run needed: that one timeout cost the whole run its results.

The mismatches in this run are the expected ones: every one involves either masks read as data (#293) or DPP ops (#238), none outside those two.

…er ends the run

vk_compute_test timing out on one program raised subprocess.TimeoutExpired out
of main(): the run stopped with a traceback and every result before it was
lost, as was the name of the program in the summary. A missing dump did the
same through RuntimeError. Both are now a HarnessError for that program: it is
listed with the other failures (and kept with --keep), counted as
harness_errors in the summary, and the run goes on. The exit code is 2 when
harness errors are the only failures, as in valu_fuzz.py and lds_fuzz.py; 1
still means a mismatch or an untranslated program.

Seen on an RX 7900 XTX (AMD 26.10.1): --seed 7900 --dpp, wave32 native,
cs_xl32_790023712 timed out after 60 s.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RcPmkK8w6mToPwmoiLYPZt
@Urban225
Urban225 force-pushed the crosslane-fuzz-harness-timeout branch from b4d539b to d296e34 Compare November 22, 2026 09:01
@Urban225

Copy link
Copy Markdown
Contributor Author

Rebased onto current main (426023a) to resolve the conflict with #1202, which moved the run loop into run_translator(). Same behaviour, now applied there; the exit-code change is in main() and reads harness_errors with .get() because the hardware-oracle stats have no such key.

python -I tests/test_crosslane_fuzz.py: 29 tests, 28 pass, 1 skipped (test_on_hardware, no oracle tools here). Linux, Python 3.13. Not rerun on the GPU after the rebase.

@ItsNotRexed
ItsNotRexed merged commit 505e084 into ItsNotRexed:main Nov 22, 2026
11 checks passed
@Urban225
Urban225 deleted the crosslane-fuzz-harness-timeout branch November 22, 2026 09:24
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.

3 participants