Commit Graph

26 Commits

Author SHA1 Message Date
d040db9876 Merge pull request #3857 from TreXito
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 23:08:57 -05:00
53eeea4170 Remove three blocks the round-42 merges left in twice
docs/testing.md had the whole "GPUs with 128 bytes of push constants"
section twice in a row (identical), and the first copy had no blank line
before its heading. docs/embedded_shaders.md section 4 repeated the
"blocker then / now" table and the "disassembly count is unchanged"
paragraph after the remaining-blocker table. tests/test_skinned_glb.py
defined SkinnedGlbTest.test_full_export_without_numpy twice (identical),
so the first definition was dead.

The second copy of each goes; nothing else changes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 22:06:06 +00:00
5db70430de Merge pull request #3618 from Dominik
# Conflicts:
#	docs/embedded_shaders.md
2026-11-22 17:03:01 -05:00
4affe0d629 Merge pull request #3562 from FIocker
# Conflicts:
#	docs/embedded_shaders.md
2026-11-22 17:02:43 -05:00
cc902bd8f9 Merge pull request #2473 from Vonsek
# Conflicts:
#	docs/embedded_shaders.md
2026-11-22 16:59:19 -05:00
f574359675 bvh_gpu_smoke: check PrefixSum64's exclusive scan and block total
One group scans 64 words in place through five ds_swizzle_b32 broadcast steps;
the check feeds input that wraps past 2^32 and compares every element and the
total. Passes on an RX 9070; with ds_swizzle_b32 skipped it fails from element 2.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 21:23:01 +00:00
3169652e94 bvh_gpu_smoke: --checked compares five programs' output byte for byte
RadixReset, ResetKDOP, ResetToIndexBuffer, CopyCounters and ResetCounterValues
take an address, a count and a value or source from the root table and write
that many entries; --checked gives them those fields and compares every entry
and the untouched bytes after them. All five match on an RX 9070; with the
translator made to skip v_add_nc_u32, ResetToIndexBuffer fails the check.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 21:21:02 +00:00
dac28e6b19 Fix what the round-42 merges broke (tests and docs)
- shader_disasm: prune stale listings against every input, not the --skip-existing remainder (a resumed run
  deleted every listing it had just reused).
- progress_dashboard: a drive-letter path is never inside the repository off Windows (it printed user names);
  its own read_text helper is read_utf8, so the encoding check does not take it for pathlib's.
- Translator tests follow this round's rules: desc_lookup's BroadcastFirst in the typed-load condition walker;
  resinfo sizes are 0 past the last level and a 2D depth word is 0 (SHADER-388); SHADER-315 constant folding in
  the perm and i16 tests; #2089's structured wave64 emulation.
- test_semantic_translator_use: 57 oracle-only files merged before it are DEBT; test_spirv_tools_required is
  allowed (CI meta-test).
- Test fixes: image_fuzz fake writes the programs, preflight follows c506d00c's loader hint rule, feature_scan
  reads the first line of a pytest-decorated message, w64_graphics wording.
- docs: rows merged again in design.md, README.md, d3d12_vulkan.md; GameInput table rebuilt from #3172's rows;
  orphan rows in models.md and embedded_shaders.md; repeated bullets; anchors; a flag not on main.
- Repo rules: stdout guard on 14 programs; LF writes; csv lineterminator in bink_play.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 16:14:54 -05:00
6d458e4b05 bvh_gpu_smoke: run XboxBvhBuilder's translated programs on the GPU (TEST-594)
tools/bvh_gpu_smoke.py translates the 52 embedded programs from the package
(the pipeline docs/embedded_shaders.md documents) and runs each through
vk_compute_test twice, with a root table seeded by VKC_HEAP_INIT whose words
point past it into zeros. A run passes when it exits 0, the validation layer
reports nothing and both runs write the same heap bytes. On an RX 9070 all 49
non-rehydration programs pass; seven change heap words with these inputs.

The wave64 bitonic sorts need --max-shared-memory set to the device's 32 KiB;
docs/embedded_shaders.md records the run and what it does and doesn't show.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 21:07:38 +00:00
66c53d04d9 RT-182: the BVH builder container created twice is GetBVHCompactedSize
bvh_builder_test measures 53 PSO creations over XboxBvhBuilder.dll's 52 containers.
With LEONIDA_BVH_RECORD62=1 the test now prints each container's ILDN module name and the
first bytes of its digest, which answers the open question in docs/embedded_shaders.md:
creations 1-51 are 51 distinct containers (GetBVHCompactedSize at 47), 52 is
CopyAndCompactBVH (0x1134 bytes) and 53 is GetBVHCompactedSize again (0x14a4 bytes, same
digest): the container FUN_18001d400 passes for "XDXR PostBuildInfoQuery".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 21:55:54 +01:00
bfe65cb90f embedded_shaders.md: one section 4 again after both PROC-120 PRs landed; the M6 row's count
The merge round took this PR's first commit and #2503, which say the same thing,
so section 4 carried both: the then/now table and, after a stray table row, the
bullet list and a second blocker table. Keep the table (now without 'open' after
#1864) and drop the repeat. d3d12_vulkan.md's M6 milestone row still said 42
pass and four rules left.
2026-11-22 21:35:25 +01:00
37be808200 Merge pull request #2826 from caua-an 2026-11-22 15:12:23 -05:00
21846e3444 Merge pull request #2503 from adriaespii
# Conflicts:
#	docs/d3d12_vulkan.md
#	docs/embedded_shaders.md
2026-11-22 15:10:57 -05:00
bcfedd79ee Merge pull request #2473 from Vonsek
# Conflicts:
#	docs/README.md
#	docs/d3d12_vulkan.md
#	docs/embedded_shaders.md
2026-11-22 15:10:53 -05:00
961e97c1d9 docs: update embedded shader translation count to 51/52 (PROC-120)
Update docs/embedded_shaders.md §4 and §5 and related references in
docs/d3d12_vulkan.md to reflect current main: 51 of 52 XboxBvhBuilder.dll
compute shaders now translate and pass spirv-val since #1871
(GFX10_FORMAT_8_UINT) and #1968 (427c1376: global_atomic_fmax/fmin and
buffer_load_ushort) landed.

Only Box16Rehydration remains blocked, awaiting buffer_store_short (#1864).

Claim: https://github.com/ItsNotRexed/Leonida/issues/2300#issuecomment-7082579530
2026-11-22 20:40:58 +01:00
15f5b2fbc0 Fix what the round-41 merges broke
- tests/semantic: BaseVertex/BaseInstance read 0 in the wave interpreter; the LDS MockGens follow
  SHADER-309 (lds_bound, lds_access, lds_atomic); abs emission tests load their operand, since
  SHADER-315 folds scalar ALU on constants.
- test_translate: the dynamic gather sampler is a loaded word, not s16 + 0 (SHADER-315 folds it).
- test_world_build: DDS downscale weights colours by alpha (62804d0d).
- test_fspx_shaders_stage: the fake disassembler writes the listing make_game now checks.
- xgameruntime_test: re-read the package id after clearing the LEONIDA_PACKAGE_ID override.
- docs: one row per topic again in design.md (72 topics) and README.md; one Other languages line;
  embedded_shaders.md keeps one copy of each bullet; animation.md links the heading anchor.
- tools/scripts: character_textures uses report_paths.same_report_path; stdout guard on six programs;
  LF write in vs_input_survey; the cl.exe fallback compiles winhttp_offline.cpp.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 14:30:33 -05:00
bb4aa15323 embedded_shaders.md: drop 'open' after #1864 so the row doesn't go stale (review nit)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 20:10:08 +01:00
dfde07df6d Docs: describe embedded DXIL reflection parts 2026-11-22 15:21:01 -03:00
0d938dedd8 Docs: 51 of the BVH builder's 52 FSSM programs translate on main; one rule (buffer_store_short) left (PROC-120)
Recounted with main 49475796 on the 1.0.2.1 package (counts only): 52/52 unpack,
42 clean and 10 with invalid words in the disassembly, 51 translate and pass
spirv-val. The four rules embedded_shaders.md listed are three since 427c1376
(#1968); Box16Rehydration stops at buffer_store_short (#1864). d3d12_vulkan.md
and the docs index quoted 41/42 and four rules in seven places.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 19:20:09 +01:00
3a40f5a539 Merge pull request #2702 from Sc4ros 2026-11-22 13:17:12 -05:00
da3779d23c Merge pull request #2503 from adriaespii
# Conflicts:
#	docs/d3d12_vulkan.md
#	docs/embedded_shaders.md
2026-11-22 13:15:47 -05:00
5b5b69aed3 bvh_builder_test: name the container behind each PSO creation (RT-182)
LEONIDA_BVH_RECORD62=1 now prints the module of each CreateComputePipelineState
call (the file name in the container's ILDN part) and says when a creation passes
a container byte-identical to an earlier one. The constructor makes 53 creations
over 52 containers; the repeat is GetBVHCompactedSize (5,284 bytes = 0x14a4):
creations #47 and #53. The test prints a summary and checks that the repeated
container names the same module both times.

docs/embedded_shaders.md answers the open question and lists the creation order.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-22 18:55:53 +01:00
7834593b51 docs: update embedded shader translation count to 51/52 (PROC-120)
Update docs/embedded_shaders.md §4 and §5 and related references in
docs/d3d12_vulkan.md to reflect current main: 51 of 52 XboxBvhBuilder.dll
compute shaders now translate and pass spirv-val since #1871
(GFX10_FORMAT_8_UINT) and #1968 (427c1376: global_atomic_fmax/fmin and
buffer_load_ushort) landed.

Only Box16Rehydration remains blocked, awaiting buffer_store_short (#1864).

Claim: https://github.com/ItsNotRexed/Leonida/issues/2300#issuecomment-7082579530
2026-11-22 18:16:21 +01:00
1a22106ac6 Docs: 51 of the BVH builder's 52 FSSM programs translate on main; one rule (buffer_store_short) left (PROC-120)
Recounted with main 49475796 on the 1.0.2.1 package (counts only): 52/52 unpack,
42 clean and 10 with invalid words in the disassembly, 51 translate and pass
spirv-val. The four rules embedded_shaders.md listed are three since 427c1376
(#1968); Box16Rehydration stops at buffer_store_short (#1864). d3d12_vulkan.md
and the docs index quoted 41/42 and four rules in seven places.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 18:10:07 +01:00
96d0b2455f docs: 42/52 after main's global-atomics fix
003e7812 loads EXEC before OpSelectionMerge in global_atomic and global_atomic_x2,
so FindTreelets assembles and validates. The 10 left are still the four rules.
2026-11-22 11:34:56 -03:00
5ecb637a02 Docs: the embedded shader containers; the BVH builder's programs are console FSSM
The 52 containers in XboxBvhBuilder.dll carry an LLVM bitcode blob and an
XDAT/XBCH record. The console record decompresses to FSSM: 52/52 unpack, 42
translate, 41 pass spirv-val with the existing translator. The 10 left need
global_atomic_fmax/fmin, buffer_load_ushort and tbuffer_load_format_x (format
8), plus one OpSelectionMerge emission bug. Correct the DXIL-front-end premise
in d3d12_vulkan.md (4.8, 7.1, 7.2, M6, Q7, Q20, A.2) and index the new note.
2026-11-22 11:34:05 -03:00