run_gpu_tests: run cs_fmt_all, which has a check.py check but no GPU test row (GPU-ROW-FMT-ALL) #800

Open
github-bot wants to merge 2 commits from github-bot/gh-800 into main AGit
Owner

@⁠s0las16 on GitHub · 2026-11-24 13:59 UTC · original
s0las16:devin/1795518363-gpu-row-fmt-all → main · +49 −3 · 3 files · 2 commits · open

claiming: GPU-ROW-FMT-ALL - scripts/run_gpu_tests.py has no row for cs_fmt_all, though runtime/test/shaders/check.py checks it with fmt_all_test. So --filter cs_fmt_all stops with "selected cs_fmt_all but no runnable GPU test cases", and a full run never exercises the fixture.

This PR adds the row, which calls the existing fmt_all_test (SCALED, SINT, small-float and 10:10:10:2 typed loads and stores). It changes only the test runner: no translator change and no new fixture.

Tested: python -I scripts/run_gpu_tests.py --filter cs_fmt_all gives PASS (dumped words exact) on llvmpipe, Mesa 23.2.1 (Ubuntu 22.04). Before the change, the same command errored as described above.

No game files, nothing online. AI-assisted (Devin)

**@⁠s0las16** on GitHub · 2026-11-24 13:59 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/800) `s0las16:devin/1795518363-gpu-row-fmt-all` → `main` · +49 −3 · 3 files · 2 commits · open claiming: GPU-ROW-FMT-ALL - `scripts/run_gpu_tests.py` has no row for `cs_fmt_all`, though `runtime/test/shaders/check.py` checks it with `fmt_all_test`. So `--filter cs_fmt_all` stops with "selected cs_fmt_all but no runnable GPU test cases", and a full run never exercises the fixture. This PR adds the row, which calls the existing `fmt_all_test` (SCALED, SINT, small-float and 10:10:10:2 typed loads and stores). It changes only the test runner: no translator change and no new fixture. Tested: `python -I scripts/run_gpu_tests.py --filter cs_fmt_all` gives PASS (dumped words exact) on llvmpipe, Mesa 23.2.1 (Ubuntu 22.04). Before the change, the same command errored as described above. No game files, nothing online. AI-assisted (Devin)
Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
MoonEyes's review on #800: add a test that exercises the row itself
(mocked fmt_all_test), report "336/336 dumped words exact" like the
other cs_fmt_* rows (from len(FMT_ALL_WORDS)), and fix the fmt_all_test
docstring that said 316 words.

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 09:21:54 +00:00
Author
Owner

@⁠GeorgiyDemo on GitHub · 2026-11-24 14:11 UTC · original

Tested 8fe14d247 on Apple M5 Pro (16-core GPU), macOS 26.7.3 (25G342), binaries from main d42773d07:

  • On main, --filter cs_fmt_all translates the shader and then has no GPU row to run (the "no runnable GPU test cases" path); with this PR it runs.
  • MoltenVK 1.4.2: cs_fmt_all PASS ("dumped words exact"), 1/1.
  • KosmicKrisp (Mesa 26.3.1): cs_fmt_all FAIL, word 293: expected 0x80007c01, got 0x80007e00, 0/1. This is the same mismatch check.py's cs_fmt_all shows on KosmicKrisp here, so it is a driver-side difference the new row now exposes rather than something this PR introduces.

So the row is worth having, but the macOS/KosmicKrisp run will need a known-failure entry or its own issue for word 293. AI-assisted; synthetic fixtures only, no game data.

**@⁠GeorgiyDemo** on GitHub · 2026-11-24 14:11 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/800#issuecomment-7133982853) Tested `8fe14d247` on Apple M5 Pro (16-core GPU), macOS 26.7.3 (25G342), binaries from `main` `d42773d07`: - On `main`, `--filter cs_fmt_all` translates the shader and then has no GPU row to run (the "no runnable GPU test cases" path); with this PR it runs. - **MoltenVK 1.4.2**: `cs_fmt_all` PASS ("dumped words exact"), 1/1. - **KosmicKrisp** (Mesa 26.3.1): `cs_fmt_all` FAIL, `word 293: expected 0x80007c01, got 0x80007e00`, 0/1. This is the same mismatch `check.py`'s `cs_fmt_all` shows on KosmicKrisp here, so it is a driver-side difference the new row now exposes rather than something this PR introduces. So the row is worth having, but the macOS/KosmicKrisp run will need a known-failure entry or its own issue for word 293. AI-assisted; synthetic fixtures only, no game data.
Author
Owner

@⁠MoonEyes on GitHub · 2026-11-24 14:37 UTC · original

Checked locally, LGTM.

  • The new row (scripts/run_gpu_tests.py:1056-1059) has the same form as the other cs_fmt_* rows: same call signature, same (name, not problem, problem or ...) result.
  • Probed run_suite with fmt_all_test mocked: a mismatch gives FAIL and rc 1, a check.Skip gives SKIP and rc 0 ("0/1 passed, 1 skipped"), an empty string gives PASS. On main the same filter exits 2 with "no runnable GPU test cases", as described.
  • fmt_all_test compares the whole 336-word heap, and a missing dump or wrong size is a failure. The fixture does not overlap the other cs_fmt_* rows.
  • tests/test_run_gpu_tests.py passes (64 tests). It also merges cleanly with #609 (git merge-tree, 67 tests pass on the merged tree).

Two small points:

  1. Nothing tests the row itself: deleting it keeps the suite green. A case like PackedFormatFixture with --filter cs_fmt_all and fmt_all_test mocked to return a problem would cover it.
  2. The other rows report a count ("64/64 dumped words exact"). "336/336 dumped words exact" (or len(FMT_ALL_WORDS)) would match. Separately, the fmt_all_test docstring says 316 words, but FMT_ALL_WORDS has 336.

AI-assisted review (Claude Code).

**@⁠MoonEyes** on GitHub · 2026-11-24 14:37 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/800#issuecomment-7134681037) Checked locally, LGTM. - The new row (scripts/run_gpu_tests.py:1056-1059) has the same form as the other cs_fmt_* rows: same call signature, same (name, not problem, problem or ...) result. - Probed run_suite with fmt_all_test mocked: a mismatch gives FAIL and rc 1, a check.Skip gives SKIP and rc 0 ("0/1 passed, 1 skipped"), an empty string gives PASS. On main the same filter exits 2 with "no runnable GPU test cases", as described. - fmt_all_test compares the whole 336-word heap, and a missing dump or wrong size is a failure. The fixture does not overlap the other cs_fmt_* rows. - tests/test_run_gpu_tests.py passes (64 tests). It also merges cleanly with #609 (git merge-tree, 67 tests pass on the merged tree). Two small points: 1. Nothing tests the row itself: deleting it keeps the suite green. A case like PackedFormatFixture with --filter cs_fmt_all and fmt_all_test mocked to return a problem would cover it. 2. The other rows report a count ("64/64 dumped words exact"). "336/336 dumped words exact" (or len(FMT_ALL_WORDS)) would match. Separately, the fmt_all_test docstring says 316 words, but FMT_ALL_WORDS has 336. AI-assisted review (Claude Code).
This pull request has changes conflicting with the target branch.
  • scripts/run_gpu_tests.py
View command line instructions

Manual merge helper

Use this merge commit message when completing the merge manually.

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/800/head:github-bot/gh-800'
git switch 'github-bot/gh-800'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-800'
git switch 'github-bot/gh-800'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-800'
git switch 'github-bot/gh-800'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-800'
git switch 'main'
git merge --squash 'github-bot/gh-800'
git switch 'main'
git merge --ff-only 'github-bot/gh-800'
git switch 'main'
git merge 'github-bot/gh-800'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.