Commit Graph

4 Commits

Author SHA1 Message Date
af08a9e696 tests: rebase semantic value coverage onto current main
Port the #78 value-level cases (ps_ops5, ps_ops6, ps_vcc_x2, ps_flat,
cs_bounds) onto main's semantic suite. Keep main's ps_ops4/ps_legacy_mul
coverage and forward-only execution contract, and extend the mini
interpreter with 64-bit integers, Input/PushConstant seeding, physical
storage buffer memory, OpBranch/OpPhi at forward merges, and the opcodes
the new fixtures use.
2026-11-21 19:56:24 +00:00
4f4189ef3e tests: follow #38 (f16 op_sel helpers) in the mutation/negative controls; test_shader_checks knows #73's wave64 dumps
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-21 14:09:15 -05:00
5f3007f393 tests/semantic: cover ps_ops2, ps_ops3, ps_ops4 and ps_legacy_mul (+ check.py) 2026-11-21 15:05:54 -03:00
695ae01d21 tests: value-level regression tests for RDNA2 -> SPIR-V pixel shaders
Add tests/semantic: translate two hand-written, branch-free pixel shaders
(ps_sdwa, ps_ops) and execute the resulting SPIR-V with a small strict
interpreter, asserting every mrt0 word against hand-derived expectations.
Catches wrong-value regressions (SDWA selects/sext, min3/max3, bfe_i32,
packed f16 FMA) that spirv-val cannot.

- Standard library only; no LLVM, SPIRV-Tools, GPU or game files.
- Interpreter rejects unmodelled constructs instead of approximating.
- Negative controls sabotage translated output; mutation tests sabotage a
  temporary copy of tools/ and require the matching test to fail.
- Fixtures are generated from runtime/test/shaders/*.asm.
- CI job semantic-tests (Windows + Ubuntu, Python 3.12), discovery limited
  to tests/semantic.
2026-11-21 18:27:51 +02:00