diff options
| author | Vonsek <45567075+Vonsek@users.noreply.github.com> | 2026-11-22 18:10:07 +0100 |
|---|---|---|
| committer | Vonsek <45567075+Vonsek@users.noreply.github.com> | 2026-11-22 19:20:09 +0100 |
| commit | 0d938dedd8dd8910a2d081dd90bc245d627fd65e (patch) | |
| tree | 02b7c371c0ce77e8527e7c87198fcabdc81cef32 /docs/embedded_shaders.md | |
| parent | ec8ec4c9a46c6623f1a9c125afd3566da97f1e0c (diff) | |
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>
Diffstat (limited to 'docs/embedded_shaders.md')
| -rw-r--r-- | docs/embedded_shaders.md | 32 |
1 files changed, 19 insertions, 13 deletions
diff --git a/docs/embedded_shaders.md b/docs/embedded_shaders.md index cfd316094..62a488961 100644 --- a/docs/embedded_shaders.md +++ b/docs/embedded_shaders.md | |||
| @@ -79,16 +79,21 @@ that expands to `FSSM` ([fssm_crosscheck.md](fssm_crosscheck.md)). On all 52 con | |||
| 79 | |---|---| | 79 | |---|---| |
| 80 | | `tools/fssm_unpack.py` | **52/52** decompress to a valid `FSSM` blob (716 B to 101,320 B, median 2,200 B) | | 80 | | `tools/fssm_unpack.py` | **52/52** decompress to a valid `FSSM` blob (716 B to 101,320 B, median 2,200 B) | |
| 81 | | `tools/shader_disasm.py --mcpu gfx1013` | **52/52** disassemble; 42 with no invalid word, 10 with invalid words in the code | | 81 | | `tools/shader_disasm.py --mcpu gfx1013` | **52/52** disassemble; 42 with no invalid word, 10 with invalid words in the code | |
| 82 | | `tools/rdna2spirv.py` | **42** translate and pass `spirv-val` | | 82 | | `tools/rdna2spirv.py` | **51** translate and pass `spirv-val` (`main` `49475796`) | |
| 83 | 83 | ||
| 84 | The 10 untranslated programs stop at four rules: | 84 | When this page was first written, 42 translated and 10 stopped at four rules. Three of those rules have landed since |
| 85 | (`427c1376`, from #1968), and one program still waits on a fifth rule: | ||
| 85 | 86 | ||
| 86 | | module(s) | blocker | | 87 | | module(s) | blocker then | now | |
| 87 | |---|---| | 88 | |---|---|---| |
| 88 | | `BuildKDOP`, `LoadInstances`, `ReloadProcedurals`, `LoadProceduralGeometry`, `LoadTriangles` | `global_atomic_fmax` | | 89 | | `BuildKDOP`, `LoadInstances`, `ReloadProcedurals`, `LoadProceduralGeometry`, `LoadTriangles` | `global_atomic_fmax` | translate | |
| 89 | | `PT_LoadInstances` | `global_atomic_fmin` | | 90 | | `PT_LoadInstances` | `global_atomic_fmin` | translates | |
| 90 | | `Box16Rehydration`, `Box32Rehydration`, `ReloadTriangles` | `buffer_load_ushort` | | 91 | | `Box32Rehydration`, `ReloadTriangles` | `buffer_load_ushort` | translate | |
| 91 | | `LeafRehydration` | `tbuffer_load_format_x GFX10_FORMAT_8_UINT` | | 92 | | `LeafRehydration` | `tbuffer_load_format_x GFX10_FORMAT_8_UINT` | translates | |
| 93 | | `Box16Rehydration` | `buffer_load_ushort` | stops at `buffer_store_short` (#1864, open) | | ||
| 94 | |||
| 95 | The disassembly count is unchanged: the same 42 programs have no invalid word, and 10 have invalid words in the | ||
| 96 | code. All 10 of those translate; `Box16Rehydration` is one of the 42 clean ones. | ||
| 92 | 97 | ||
| 93 | Reproduction, after `--extract` above: | 98 | Reproduction, after `--extract` above: |
| 94 | 99 | ||
| @@ -100,16 +105,17 @@ python -I tools/rdna2spirv.py <work>/embedded/dxbc/disasm --out <work>/embedded/ | |||
| 100 | 105 | ||
| 101 | ## 5. What this changes | 106 | ## 5. What this changes |
| 102 | 107 | ||
| 103 | * **The RT builder does not need a DXIL path for the console code.** Its programs are RDNA2 `FSSM`, and 41 of | 108 | * **The RT builder does not need a DXIL path for the console code.** Its programs are RDNA2 `FSSM`, and 51 of |
| 104 | 52 already pass `spirv-val` with the translator the project uses for the game's 26,503 shaders. The bitcode in | 109 | 52 already pass `spirv-val` with the translator the project uses for the game's 26,503 shaders. The bitcode in |
| 105 | the same container is a second representation (the one the PC-compiler experiment measured); it is not what | 110 | the same container is a second representation (the one the PC-compiler experiment measured); it is not what |
| 106 | the console runtime executes. | 111 | the console runtime executes. |
| 107 | * **The four missing rules are small and have real fixtures.** `global_atomic_fmax`/`fmin` cover 6 programs, | 112 | * **The missing rules were small, and only one is left.** `global_atomic_fmax`/`fmin` (6 programs), |
| 108 | `buffer_load_ushort` 3 and `tbuffer_load_format_x` with format 8 one. They are ordinary translator rules, not | 113 | `buffer_load_ushort` (3) and `tbuffer_load_format_x` with format 8 (1) were ordinary translator rules, not a new |
| 109 | a new compiler backend. | 114 | compiler backend, and they are on `main`. The one left is `buffer_store_short`, for `Box16Rehydration`. |
| 110 | * **The rehydration programs are the ones closest to the shipped data.** `Box16Rehydration`, | 115 | * **The rehydration programs are the ones closest to the shipped data.** `Box16Rehydration`, |
| 111 | `Box32Rehydration` and `LeafRehydration` are exactly the programs that would turn the dehydrated BVH packs | 116 | `Box32Rehydration` and `LeafRehydration` are exactly the programs that would turn the dehydrated BVH packs |
| 112 | into runtime trees ([bvh.md](bvh.md) §3.1). Two of the four rules stand between them and translation. | 117 | into runtime trees ([bvh.md](bvh.md) §3.1). `Box32Rehydration` and `LeafRehydration` translate; |
| 118 | `Box16Rehydration` needs `buffer_store_short`. | ||
| 113 | * **What is still open.** None of the 52 has been executed on a GPU; translation and `spirv-val` do not prove the | 119 | * **What is still open.** None of the 52 has been executed on a GPU; translation and `spirv-val` do not prove the |
| 114 | output. Which of them the game actually creates is a call-site question (RT-5). The module-to-pipeline order | 120 | output. Which of them the game actually creates is a call-site question (RT-5). The module-to-pipeline order |
| 115 | above comes from `ILDN`, not from a runtime trace. The `STAT` bitcode and the `0x07 NOBC` record are not | 121 | above comes from `ILDN`, not from a runtime trace. The `STAT` bitcode and the `0x07 NOBC` record are not |