upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorubiquitarianism <283527159+ubiquitarianism@users.noreply.github.com>2026-11-24 11:39:04 -0500
committerGitHub <noreply@github.com>2026-11-24 11:39:04 -0500
commit6ff4d2805a59e8ad00ee64bc13a09d3f4ba0114d (patch)
tree97350eac5f9d62914b4a7cd0b31b629abc35cb23 /docs
parent714aaa3dbb3f669e4be9b2f075403d6eeb3f2a73 (diff)
parentca0c243471a1b7880ef88df7fddfb6dd06504edd (diff)
Merge pull request #790 from aslan2142/asset374-corpus-counts
OLD-7783: restore old upstream PR 7783 - docs/design.md: whole-corpus disassembly and translation counts (ASSET-374)
Diffstat (limited to 'docs')
-rw-r--r--docs/design.md10
1 files changed, 8 insertions, 2 deletions
diff --git a/docs/design.md b/docs/design.md
index 774cc6fad..289c4cd59 100644
--- a/docs/design.md
+++ b/docs/design.md
@@ -585,8 +585,14 @@ LLVM_MC=/usr/lib/llvm-21/bin/llvm-mc python3 -I <repo>/tools/shader_disasm.py <w
585``` 585```
586 586
587Code starts at the u32 at FSSM offset 0xC0 (the code-section offset) plus 0x28 bytes into that section, and ends at the 587Code starts at the u32 at FSSM offset 0xC0 (the code-section offset) plus 0x28 bytes into that section, and ends at the
588last `s_endpgm`. Use `--mcpu gfx1013`. On 300 random shaders it decoded 284 cleanly (134 invalid words in total), 588last `s_endpgm`. Use `--mcpu gfx1013`. Over the whole 26,503-blob 1.0.2.1 corpus (`shader_disasm.py` at `d90444f2`,
589against 201 clean and 6,560 invalid for gfx1030 and 283 clean for gfx1010–1012. 589llvm-mc 23.1.5, data blocks excluded as below) gfx1013 decodes all 26,503 blobs with no invalid word; gfx1010, gfx1011
590and gfx1012 decode 26,439 (64 blobs with invalid words: 2,481, 2,438 and 2,438 words) and gfx1030 17,875 (8,628 blobs,
591440,225 words). An earlier sample of 300 random shaders gave 284 clean for gfx1013, 201 for gfx1030 and 283 for
592gfx1010–1012. Translating those 26,503 listings at the same commit (`rdna2spirv.py <disasm> --out <out> --shard i/16`,
593then `--merge`, default options) gives 26,503 translated and 26,503 passing `spirv-val`: 2,236 VS, 12,101 PS, 195 GS,
5942,689 CS and 9,282 mesh. The index equals the `4beffda8` run's in every field but `src_sha256`, which differs for the
5951,473 listings the data-block cut below shortened.
590 596
591Some blobs end with a constant-data block after the real code: `s_endpgm`, a dword count N, N dwords of data, a 597Some blobs end with a constant-data block after the real code: `s_endpgm`, a dword count N, N dwords of data, a
592closing `s_endpgm`, then `s_code_end` padding. The data is not code, so the tool ends the range at the count 598closing `s_endpgm`, then `s_code_end` padding. The data is not code, so the tool ends the range at the count