run_gpu_tests: sort cs_dump tables one entry per line (TEST-RUN-GPU-SORTED-TABLES) #1726

Merged
leonida/mandy
TanmaySatyam merged 1 commit from refactor/run-gpu-tests-sorted-tables into main 2026-11-30 13:54:15 +00:00

Pull request successfully merged and closed

TanmaySatyam commented 2026-11-25 09:48:49 +00:00

Claimed in the coordination issue as: TEST-RUN-GPU-SORTED-TABLES (https://github.com/ubiquitarianism/leonida/issues/1608#issuecomment-7158772853)

What and why

scripts/run_gpu_tests.py had three multi-entry horizontal tuples (elif name in ("cs_...", ...) duplicating every key of cs_dump_wants, wave64 = name not in (...), and hexwords=name in (...)) that caused recurring 3-way merge conflicts whenever two GPU-test PRs touched the runner.

This lifts those lists to module-level, alphabetically sorted, one-entry-per-line tables:

  • CS_DUMP_WANTS (dispatch now checks elif name in CS_DUMP_WANTS: directly, removing the duplicate 74-entry tuple)
  • CS_DUMP_NON_WAVE64 (frozenset[str], 42 entries)
  • CS_DUMP_HEXWORDS (frozenset[str], 9 entries)

Every fixture set has identical membership to main; tests/test_run_gpu_tests_tables.py enforces alphabetical sorting, one-entry-per-line formatting, and subset parity going forward.

Tested

  • python -m compileall -q scripts/run_gpu_tests.py tests/test_run_gpu_tests_tables.py -> pass
  • python -I tests/test_run_gpu_tests_tables.py -> 4/4 passed
  • python -I tests/test_run_gpu_tests.py -> 68/68 passed
  • python -I tests/test_run_gpu_tests_paths.py -> 21/21 passed
  • python -I scripts/run_gpu_tests.py --build runtime/build --filter cs_store --require-pass (LEONIDA_VK_VALIDATION=1) -> 1/1 passed
  • python -I scripts/run_gpu_tests.py --build runtime/build --filter cs_w32_fcmpswap --require-pass (LEONIDA_VK_VALIDATION=1) -> 1/1 passed
  • LEONIDA_W64_EMULATE=1 python -I scripts/run_gpu_tests.py --build runtime/build --filter cs_smem_vcc_base --require-pass (LEONIDA_VK_VALIDATION=1) -> 1/1 passed (and skips natively on 32-wide as before)
  • python -I scripts/check_no_game_data.py scripts/run_gpu_tests.py tests/test_run_gpu_tests_tables.py -> exit 0

GPUs tested: NVIDIA GeForce RTX 5070 (Windows 11, Vulkan validation enabled, 0 VUIDs)

AI-assisted: yes

Checklist

  • Based on current main and merges cleanly (a conflicting pull request is labeled needs rebase).
  • One topic; follow-up work goes in a new pull request.
  • 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)
Claimed in the coordination issue as: TEST-RUN-GPU-SORTED-TABLES (https://github.com/ubiquitarianism/leonida/issues/1608#issuecomment-7158772853) ### What and why `scripts/run_gpu_tests.py` had three multi-entry horizontal tuples (`elif name in ("cs_...", ...)` duplicating every key of `cs_dump_wants`, `wave64 = name not in (...)`, and `hexwords=name in (...)`) that caused recurring 3-way merge conflicts whenever two GPU-test PRs touched the runner. This lifts those lists to module-level, alphabetically sorted, one-entry-per-line tables: - `CS_DUMP_WANTS` (dispatch now checks `elif name in CS_DUMP_WANTS:` directly, removing the duplicate 74-entry tuple) - `CS_DUMP_NON_WAVE64` (`frozenset[str]`, 42 entries) - `CS_DUMP_HEXWORDS` (`frozenset[str]`, 9 entries) Every fixture set has identical membership to `main`; `tests/test_run_gpu_tests_tables.py` enforces alphabetical sorting, one-entry-per-line formatting, and subset parity going forward. ### Tested - `python -m compileall -q scripts/run_gpu_tests.py tests/test_run_gpu_tests_tables.py` -> pass - `python -I tests/test_run_gpu_tests_tables.py` -> 4/4 passed - `python -I tests/test_run_gpu_tests.py` -> 68/68 passed - `python -I tests/test_run_gpu_tests_paths.py` -> 21/21 passed - `python -I scripts/run_gpu_tests.py --build runtime/build --filter cs_store --require-pass` (`LEONIDA_VK_VALIDATION=1`) -> 1/1 passed - `python -I scripts/run_gpu_tests.py --build runtime/build --filter cs_w32_fcmpswap --require-pass` (`LEONIDA_VK_VALIDATION=1`) -> 1/1 passed - `LEONIDA_W64_EMULATE=1 python -I scripts/run_gpu_tests.py --build runtime/build --filter cs_smem_vcc_base --require-pass` (`LEONIDA_VK_VALIDATION=1`) -> 1/1 passed (and skips natively on 32-wide as before) - `python -I scripts/check_no_game_data.py scripts/run_gpu_tests.py tests/test_run_gpu_tests_tables.py` -> exit 0 GPUs tested: NVIDIA GeForce RTX 5070 (Windows 11, Vulkan validation enabled, 0 VUIDs) AI-assisted: yes ### Checklist - [x] Based on current `main` and merges cleanly (a conflicting pull request is labeled `needs rebase`). - [x] One topic; follow-up work goes in a new pull request. - [x] 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)
lixonik reviewed 2026-11-25 10:23:51 +00:00
lixonik left a comment
No description provided.
Independent native Windows verification at `df7cf56d` against `3de22a19`. I extracted the old table and dispatch membership from the base AST and compared them with the PR's loaded constants: all 74 fixture names and expected word sequences are identical, as are the 42 non-wave64 and 9 hex-output memberships. The three runner test files passed (4 table, 68 runner, 21 path tests). AI-assisted review. CPU-only comparison and synthetic tests.
MoonEyes commented 2026-11-28 02:59:05 +00:00

Hi @TanmaySatyam, thanks for this pull request. It currently conflicts with main (conflicting file(s): scripts/run_gpu_tests.py), so it carries the needs rebase label. CONTRIBUTING.md asks authors to rebase their branch on main; once it merges cleanly the label goes within the hour, and reviews start with the pull requests that do. Could you update the branch when you have a moment? If you no longer plan to continue with it, please say so here.

AI-assisted (Claude Code, Claude Opus 5.5).

Hi @TanmaySatyam, thanks for this pull request. It currently conflicts with `main` (conflicting file(s): `scripts/run_gpu_tests.py`), so it carries the `needs rebase` label. CONTRIBUTING.md asks authors to rebase their branch on `main`; once it merges cleanly the label goes within the hour, and reviews start with the pull requests that do. Could you update the branch when you have a moment? If you no longer plan to continue with it, please say so here. AI-assisted (Claude Code, Claude Opus 5.5).
enlight3d commented 2026-11-29 04:38:12 +00:00

RUN: #1726 (tests only, python -I, no build, no game, GPU not used)

Tested heads: PR head df7cf56d1 (merge base 3de22a190), main b6bf3aa0b (fetched 2026-11-29).

Commands (from each worktree root, CPython 3.13.12):

  • python -I tests/test_run_gpu_tests_tables.py (new file, 4 tests)
  • python -I tests/test_run_gpu_tests.py
  • python -I tests/test_run_gpu_tests_paths.py
  • python -I tests/test_build_runtime_fallback.py (imports run_gpu_tests)
  • python -I scripts/run_semantic_tests.py tests/semantic -j 4 (24 semantic files mention run_gpu_tests.py; test_rule_gpu_fixtures.py reads its source)

Red: PR head with scripts/run_gpu_tests.py reverted to the merge-base version (tests kept): test_run_gpu_tests_tables.py fails 4 of 4 (tables missing, dispatch still uses the inline tuple). This is a refactor, so the red is structural: the new test pins the sorted one-entry-per-line tables. The existing runner tests (68) still pass with the old runner, as expected for a no-behaviour-change refactor.
Green at head: tables 4 OK, runner 68 OK, paths 21 OK, build_runtime_fallback 10 OK; semantic suite 487 files, 6279 tests, 0 files failed (1043 s, 4 jobs).
Green merged into main: NOT RUNNABLE. git merge pr-1726 into main b6bf3aa0b conflicts in scripts/run_gpu_tests.py (2 hunks, the inline cs_dump tuples that the PR replaces were edited on main by later PRs); GitHub also reports CONFLICTING (needs rebase). Plain main for reference: test_run_gpu_tests.py 75 OK, paths 23 OK, tables test fails on main as expected (no tables there).
Pre-existing on plain main, unrelated to this PR: tests/test_build_runtime_fallback.py fails 1 test (test_the_loader_gets_the_stack_reserve_cmake_gives_it, a CMake regex about /STACK). It passes at the PR head only because the PR's base predates the CMake change.

So: green at head, red verified (structural), needs a rebase on main before a merged run is possible.

Machine: Windows 11 Pro 10.0.26300, CPython 3.13.12, GPU not used.

RUN: #1726 (tests only, python -I, no build, no game, GPU not used) Tested heads: PR head df7cf56d1 (merge base 3de22a190), main b6bf3aa0b (fetched 2026-11-29). Commands (from each worktree root, CPython 3.13.12): - python -I tests/test_run_gpu_tests_tables.py (new file, 4 tests) - python -I tests/test_run_gpu_tests.py - python -I tests/test_run_gpu_tests_paths.py - python -I tests/test_build_runtime_fallback.py (imports run_gpu_tests) - python -I scripts/run_semantic_tests.py tests/semantic -j 4 (24 semantic files mention run_gpu_tests.py; test_rule_gpu_fixtures.py reads its source) Red: PR head with scripts/run_gpu_tests.py reverted to the merge-base version (tests kept): test_run_gpu_tests_tables.py fails 4 of 4 (tables missing, dispatch still uses the inline tuple). This is a refactor, so the red is structural: the new test pins the sorted one-entry-per-line tables. The existing runner tests (68) still pass with the old runner, as expected for a no-behaviour-change refactor. Green at head: tables 4 OK, runner 68 OK, paths 21 OK, build_runtime_fallback 10 OK; semantic suite 487 files, 6279 tests, 0 files failed (1043 s, 4 jobs). Green merged into main: NOT RUNNABLE. `git merge pr-1726` into main b6bf3aa0b conflicts in scripts/run_gpu_tests.py (2 hunks, the inline cs_dump tuples that the PR replaces were edited on main by later PRs); GitHub also reports CONFLICTING (needs rebase). Plain main for reference: test_run_gpu_tests.py 75 OK, paths 23 OK, tables test fails on main as expected (no tables there). Pre-existing on plain main, unrelated to this PR: tests/test_build_runtime_fallback.py fails 1 test (test_the_loader_gets_the_stack_reserve_cmake_gives_it, a CMake regex about /STACK). It passes at the PR head only because the PR's base predates the CMake change. So: green at head, red verified (structural), needs a rebase on main before a merged run is possible. Machine: Windows 11 Pro 10.0.26300, CPython 3.13.12, GPU not used.
OreoFR commented 2026-11-29 08:33:48 +00:00

@TanmaySatyam this PR now conflicts with main (scripts/run_gpu_tests.py). Could you merge main into your branch (no force-push needed)? It was verified before the conflict: https://github.com/ProjectLeonida/mandy/pull/1726#issuecomment-7250771073. If there's no update within 24 h, OreoFR may carry it in a new PR that keeps you as co-author (per the maintainers' plan). — OreoFR's agent (AI-assisted)

@TanmaySatyam this PR now conflicts with `main` (`scripts/run_gpu_tests.py`). Could you merge `main` into your branch (no force-push needed)? It was verified before the conflict: https://github.com/ProjectLeonida/mandy/pull/1726#issuecomment-7250771073. If there's no update within 24 h, OreoFR may carry it in a new PR that keeps you as co-author (per the maintainers' plan). — OreoFR's agent (AI-assisted)
OreoFR commented 2026-11-30 13:24:51 +00:00

Carried as #2718 because of the conflict with main after #2566; @TanmaySatyam, if you come back, say so and the carry is dropped.

Carried as #2718 because of the conflict with main after #2566; @TanmaySatyam, if you come back, say so and the carry is dropped.
Sign in to join this conversation.
No description provided.