Commit Graph

18350 Commits

Author SHA1 Message Date
369a062595 Merge main and preserve clip fixtures alongside updated GPU test tooling 2026-11-21 13:26:15 -08:00
6f6ffffa8d make_game.py: --wave64-emulate auto|on|off, on for GPUs without 64-wide subgroups (SHADER-11)
#152 added rdna2spirv.py --wave64-emulate (wave64 compute and mesh shaders exact on any
subgroup size), but the build never passed it, so 32-wide GPUs (NVIDIA, Intel) got the
native translation.

- auto (default) reads the smallest maxSubgroupSize from vulkaninfo and turns emulation on
  below 64, or when vulkaninfo is missing or tells nothing (the emulated output is exact
  everywhere). on and off are taken as given.
- The mode used is written to spirv/wave64_emulate.txt; a change translates again. A folder
  without the file counts as off, which is how it was made.
- translate() passes the flag to every shard.
- Tests: tests/test_make_game_wave64.py (new), resume and argparse tests extended.

AI-assisted (Claude Code).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 08:24:30 +11:00
57544ab7a9 Docs: note the full tree JSON size 2026-11-21 21:23:50 +00:00
084cf31b82 rbf0_tree: record the XML error status 2026-11-21 21:23:50 +00:00
37ab207e58 Docs: correct the UIScreen sample nesting 2026-11-21 21:23:50 +00:00
c42377b758 Docs: clarify the compact skip rows after the rule 2026-11-21 21:23:49 +00:00
bd7cd27e56 rbf0_tree: keep string bytes, overwrite XML on rerun
Preserve a trailing NUL byte in a length-prefixed string instead of treating it as a terminator, overwrite per-resource XML files on a rerun rather than adding -0000 duplicates, and reject a source with no RBF0 start. Add tests for trailing NUL strings, non-finite floats and XML reruns.
2026-11-21 21:23:49 +00:00
ddd49a818f Textures: count every gated compact record in the scan total 2026-11-21 21:23:48 +00:00
ea80364306 Textures: name the compact rule in the tex_headers module doc 2026-11-21 21:23:48 +00:00
9a713d29c8 Textures: point the carve exporter at the compact layout owner 2026-11-21 21:23:48 +00:00
0589fb5a37 Textures: share the compact layout and record the after split 2026-11-21 21:23:48 +00:00
91db8ec6e1 Tests: cover stereo streamed-music manifest fields 2026-11-21 21:23:30 +00:00
bb4fc2e286 rdna2spirv: seed mesh v5 as groupIndex * NumThreads + lane
The game's mesh entry reads v5 on the first active lane and shifts it right
by 7 to get the meshlet/group index. Seeding v5 with the bare linear group
index made that resolve to groupIndex >> 7, so every group below 128 mapped
to meshlet 0. Seed v5 per invocation as linearGroupIndex * NumThreads (PSV0,
128 in this corpus) + LocalInvocationIndex, matching the NGG vertex-ID slot
and TomBox's mesh ABI (gid.x * numThreads + gi).

Not verified on Xbox hardware.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-21 13:21:04 -08:00
8d8ebee384 Loader: resolve forwarders to shimmed modules through the shim registry
A forwarder target is resolved through game_dir and System32, but not through shims::find, so a forwarder to xmem or d3d12_xs became an unimplemented thunk. Check the normalized module name against the shim registry first, as a direct import already does. A synthetic shim table and a forwarder-to-shim test cover it.
2026-11-21 13:20:30 -08:00
4e390e0871 run_gpu_tests: --filter ps_flat also builds vs_ids, which ps_flat is drawn with (fixes #192)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-21 16:19:54 -05:00
531f778a27 tests: test_shader_checks' fake harness answers #186's cs_workgroup_yz
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-21 16:19:11 -05:00
f348eb9be0 GPU tests: skip pixel tests without barycentrics and narrow subgroups 2026-11-21 21:17:07 +00:00
21cef25b4a Translator: wave64 ds_bpermute reads 0 from lanes missing from a partial wave
On a 64-wide subgroup, ds_bpermute_b32 is a subgroup shuffle with EXEC-off sources set to 0. The missing lanes
of a partial wave (a 40-thread group) aren't running at all, and SPIR-V leaves a shuffle from them undefined:
RADV returned stale registers that changed between runs, so cs_w64x_partial failed natively on an RX 6700 XT.
The shuffle result is now kept only where a ballot of the running invocations has the source lane.
2026-11-21 23:16:30 +02:00
e18daf7a3d tools: reject PSIN records without a first section 2026-11-21 23:15:39 +02:00
d2afb6f480 Report Vulkan atlas capabilities only after a successful device probe 2026-11-21 14:14:52 -07:00
4cf04e2a18 Index Bink streams with fractional NTSC frame rates 2026-11-21 14:14:14 -07:00
6220fd078c Translator: keep v_perm_b32 and v_alignbit_b32 shifts below 32, and test both
Both handlers emitted shifts of 32 or more on the side of an OpSelect that is
discarded (v_perm_b32 for every selector byte; v_alignbit_b32 when the shift
is 0). SPIR-V leaves those results undefined, and the semantic interpreter
rejects them, so neither op had a value test. The shifts are now masked; the
selected result is the same for every input.

tests/semantic/test_alu_perm_alignbit.py runs both ops against plain-Python
references: every defined v_perm_b32 selector (0-7, 0x0c, above 0x0c, per
LLVM's AMDGPUISD::PERM known-bits) in every byte, and every v_alignbit_b32
shift including masking above 31. Selectors 8-11 are left untested. The
interpreter gains OpUGreaterThanEqual, which v_perm_b32 uses.

AI-assisted (Claude Code).
2026-11-21 16:13:17 -05:00
f6bfb13c53 Write valid JSON for shader profiles with no memory operations 2026-11-21 14:11:21 -07:00
d4ab78ffd7 World builder: preserve unrelated GLBs during chunk cleanup 2026-11-21 14:10:17 -07:00
c45309e29f Integrate #188 and guard maintenance8 by its Vulkan header macro 2026-11-21 22:10:07 +01:00
f238f66a97 Merge pull request #186 from imnotdiesel
# Conflicts:
#	runtime/test/shaders/build.py
#	scripts/run_gpu_tests.py
2026-11-21 16:08:57 -05:00
f35db03d8e CI: byte-compile tests/ too, as CONTRIBUTING.md says
CONTRIBUTING.md lists the tool check as `compileall make_game.py tools tests`, but the CI step and
AGENTS.md left out tests/. The pytest-based files are skipped by the Windows test loop, so a syntax
error in them only showed up in the Linux job.
2026-11-21 15:08:50 -06:00
f3da088e56 Merge pull request #171 from shelbykb2
# Conflicts:
#	runtime/test/shaders/check.py
#	scripts/run_gpu_tests.py
#	tests/test_shader_checks.py
2026-11-21 16:08:48 -05:00
b36252415a Merge pull request #185 from Kam471
# Conflicts:
#	docs/design.md
2026-11-21 16:08:26 -05:00
63537ec435 Merge pull request #138 from SuarezPM 2026-11-21 16:08:10 -05:00
1261c082e8 Merge pull request #167 from 0xTehuti 2026-11-21 16:08:09 -05:00
233e2452e4 Merge pull request #188 from Kam471 2026-11-21 16:08:08 -05:00
b957eb71ab Merge pull request #170 from adrbn 2026-11-21 16:08:08 -05:00
b63a6454bc Merge pull request #189 from eIBart0 2026-11-21 16:08:08 -05:00
5026d36f9c Merge pull request #184 from Mokbul Miah 2026-11-21 16:08:07 -05:00
a0611c9fef Merge pull request #177 from simonbronk 2026-11-21 16:08:07 -05:00
0f3383b72c Merge pull request #190 from Kam471 2026-11-21 16:08:07 -05:00
070d697a46 Merge pull request #187 from Ayinaki 2026-11-21 16:08:07 -05:00
16240a1405 Merge pull request #183 from Kam471 2026-11-21 16:08:06 -05:00
72b25c1611 Merge pull request #182 from Eng-Meshari 2026-11-21 16:08:06 -05:00
548b445961 Merge pull request #181 from Kam471 2026-11-21 16:08:06 -05:00
b2acfa7205 Merge pull request #178 from Kam471 2026-11-21 16:08:06 -05:00
d0fc6104c1 Merge pull request #175 from Ayinaki 2026-11-21 16:08:06 -05:00
fd8e2f8f93 Merge pull request #174 from bbareth 2026-11-21 16:08:06 -05:00
0980b157b7 Merge pull request #173 from shelbykb2 2026-11-21 16:08:05 -05:00
70ec7660ad Merge pull request #169 from NWX10 2026-11-21 16:08:05 -05:00
380cca48d2 Merge pull request #168 from Ayinaki 2026-11-21 16:08:05 -05:00
3452ebee0f Merge pull request #162 from NWX10 2026-11-21 16:08:05 -05:00
13092ba302 Merge pull request #153 from NWX10 2026-11-21 16:08:05 -05:00
485d1de5a8 Merge pull request #148 from Kam471 2026-11-21 16:08:05 -05:00