docs/shader_validation.md: document tools/d16_image_probe.py and tools/semantic_mutants.py (DOC-SHADER-VAL-D16-MUTANTS) #1782
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
missing claim
needs rebase
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/ubiquitarianism--leonida!1782
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/1782/head"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@ShotTechOp on GitHub · 2026-11-25 12:03 UTC · original
ShotTechOp:docs/shader-validation-d16-and-mutants→main· +44 −0 · 1 files · 1 commits · merged 2026-11-25 21:27 UTCSummary
Claimed in #1608 as
DOC-SHADER-VAL-D16-MUTANTS: #1608Documents two existing shader-validation tools in
docs/shader_validation.mdthat were not yet mentioned anywhere indocs/:tools/d16_image_probe.py(placed right after its buffer-load counterparttools/d16_format_probe.py):image_load, pointimage_sample_lz, and bilinearimage_sample_lz(--frac) paths acrossunorm8,snorm8,unorm16,snorm16,float16, andfloat32(f16 halfway ties).--formats,--waves,--frac,--json,--hw-arch,--self-test), exit codes (0/1/2/77), and its unit test suitetests/test_d16_image_probe.py.tools/semantic_mutants.py(placed right before## Coverage plan and cost):tools/rdna2spirv.pyagainst atests/semantictest file viaLEONIDA_TOOLS_DIR(same hook astests/semantic/test_mutations.py).tests/semantic/test_alu_sad.pywith--op v_sad_u8(no stale hardcoded--linesrange), lists selectors (--op,--function,--lines),--list,--timeout, exit codes (0/1/2), andtests/test_semantic_mutants.py.Zero line overlap with open
#1605(which deduplicates lines 1998–2184).Testing
Environment: Windows 11 x64, Python 3.12.10, CPU-only (no GPU or game files; based on
0d80bc5).python -I tools/d16_image_probe.py --self-test->self-test okpython -I tools/semantic_mutants.py tests/semantic/test_alu_sad.py --op v_sad_u8 --list-> lists 31 mutants cleanly (exit 0)python -m unittest discover -s tests -p "test_docs_*.py"-> all doc-integrity suites passpython -I scripts/check_no_game_data.py docs/shader_validation.md-> exit 0git diff --check-> cleanAI-assisted: yes (Antigravity). Docs-only; no game data.
@PierreEbele on GitHub · 2026-11-25 19:04 UTC · original
Reviewed
7ea654f9a: ran on both trees tests/test_d16_image_probe.py (Ran 13, OK, 2 GPU tests skipped), tests/test_semantic_mutants.py (21/23; the 2 failures are the SourceOption tests needinggit ls-files, which is not available here - identical on main), the documented commands d16_image_probe.py --self-test (ok), --hw-arch gfx1031 --json (exit 77, no GPU here), semantic_mutants.py --op v_sad_u8 --list (31 mutants) plus the full run (30 of 31 caught, 1 SURVIVED, matching the doc's equivalence caveat), the 12 docs linters (all OK) and check_no_game_data on the page (clean). One accuracy fix: the new section enumerates the compared rules as rte, f32_rte and their toward-zero and denormal-flushing variants, but classify() compares 10 rules including mul_rte/mul_rte_flush (the reciprocal-multiply reading), also present in the JSON report; adding mul_rte would make it exact. Every other claim matches the code.AI-assisted review.
Recommendation: Fix first