OLD-7783: restore old upstream PR 7783 - docs/design.md: whole-corpus disassembly and translation counts (ASSET-374) #790

Manually merged
github merged 1 commit from gh-pr/790/head into gh-pr/790/base 2026-11-26 09:21:30 +00:00
Owner

@⁠aslan2142 on GitHub · 2026-11-24 13:51 UTC · original
aslan2142:asset374-corpus-counts → main · +8 −2 · 1 files · 1 commits · merged 2026-11-24 16:39 UTC

Claimed in the coordination issue as: OLD-7783 #14

Restoration of my original pull request, old upstream PR 7783 in ItsNotRexed/Leonida, which was closed unmerged when that repository went private on 2026-11-23 (old numbers link nowhere now). Rebased onto main at d0da7dade; the commit cherry-picks cleanly and is unchanged. Its counts match the README's current whole-corpus figures (26,503 / 26,503 translated and passing spirv-val, same per-stage split), so no count needed updating.

#649 and #653 also touch docs/design.md, but in other places; this merges cleanly with both.

What and why

  • The disassembly note in docs/design.md ("Use --mcpu gfx1013") still cited a sample of 300 random shaders. It now gives counts over the whole 26,503-blob 1.0.2.1 corpus (shader_disasm.py at d90444f2, llvm-mc 23.1.5, data blocks excluded).
  • gfx1013 decodes all 26,503 blobs with no invalid word.
  • gfx1010, gfx1011 and gfx1012 decode 26,439 cleanly. The other 64 blobs have 2,481, 2,438 and 2,438 invalid words.
  • gfx1030 decodes 17,875 cleanly. The other 8,628 blobs have 440,225 invalid words.
  • Translating those listings at the same commit (16 shards, then --merge, default options) gives 26,503 translated and 26,503 passing spirv-val: 2,236 VS, 12,101 PS, 195 GS, 2,689 CS and 9,282 mesh.
  • The resulting index matches the 4beffda8 run in every field except src_sha256. That field differs only for the 1,473 listings that the data-block cut shortened.
  • The 300-shader figures stay in the note as the earlier sample.

Tested

  • tests/test_docs_*.py: all 12 pass on the rebased branch.
  • git diff --check: clean.
  • python -I scripts/check_no_game_data.py docs/design.md: passes.
  • The counts come from the original whole-corpus run; this rebase changes no text. The note gives counts only: no shader names, disassembly or bytes.

GPUs tested: n/a

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: docs only, no new rule)

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

**@⁠aslan2142** on GitHub · 2026-11-24 13:51 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/790) `aslan2142:asset374-corpus-counts` → `main` · +8 −2 · 1 files · 1 commits · merged 2026-11-24 16:39 UTC Claimed in the coordination issue as: OLD-7783 https://git.gtahub.st/github/ubiquitarianism--leonida/issues/14 Restoration of my original pull request, old upstream PR 7783 in `ItsNotRexed/Leonida`, which was closed unmerged when that repository went private on 2026-11-23 (old numbers link nowhere now). Rebased onto main at `d0da7dade`; the commit cherry-picks cleanly and is unchanged. Its counts match the README's current whole-corpus figures (26,503 / 26,503 translated and passing `spirv-val`, same per-stage split), so no count needed updating. #649 and #653 also touch `docs/design.md`, but in other places; this merges cleanly with both. ### What and why - The disassembly note in `docs/design.md` ("Use `--mcpu gfx1013`") still cited a sample of 300 random shaders. It now gives counts over the whole 26,503-blob 1.0.2.1 corpus (`shader_disasm.py` at `d90444f2`, llvm-mc 23.1.5, data blocks excluded). - gfx1013 decodes all 26,503 blobs with no invalid word. - gfx1010, gfx1011 and gfx1012 decode 26,439 cleanly. The other 64 blobs have 2,481, 2,438 and 2,438 invalid words. - gfx1030 decodes 17,875 cleanly. The other 8,628 blobs have 440,225 invalid words. - Translating those listings at the same commit (16 shards, then `--merge`, default options) gives 26,503 translated and 26,503 passing `spirv-val`: 2,236 VS, 12,101 PS, 195 GS, 2,689 CS and 9,282 mesh. - The resulting index matches the `4beffda8` run in every field except `src_sha256`. That field differs only for the 1,473 listings that the data-block cut shortened. - The 300-shader figures stay in the note as the earlier sample. ### Tested - `tests/test_docs_*.py`: all 12 pass on the rebased branch. - `git diff --check`: clean. - `python -I scripts/check_no_game_data.py docs/design.md`: passes. - The counts come from the original whole-corpus run; this rebase changes no text. The note gives counts only: no shader names, disassembly or bytes. GPUs tested: n/a 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: docs only, no new rule) AI-assisted (Claude Code, Claude Opus 5.5).
The disassembly note cited a 300-shader sample. Over all 26,503 blobs of the
1.0.2.1 corpus at d90444f2 with llvm-mc 23.1.5: gfx1013 decodes all 26,503 with
no invalid word; gfx1010/1011/1012 26,439 (64 with invalid words), gfx1030
17,875 (8,628). Translating the fresh listings: 26,503 translated, 26,503 pass
spirv-val, and the index matches the 4beffda8 run except src_sha256 for the
1,473 listings the data-block cut shortened.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 09:21:29 +00:00
github manually merged commit ca0c243471 into gh-pr/790/base 2026-11-26 09:21:30 +00:00
This discussion has been locked. Commenting is limited to contributors.
No description provided.