Commit Graph

3 Commits

Author SHA1 Message Date
29a8ebea85 tests/semantic: run the LDS read/write, direct, alloc and atomic add/min/max/xchg tests through the translator
test_lds_{read_write,direct,basic_alloc,atomic_add,atomic_minmax,atomic_xchg}.py built their own LDS interpreter
and only checked the shape of Gen's output, so a wrong ds_* lowering could not fail them. They now translate
hand-written compute listings with tools/rdna2spirv.py and run them in spirv_mini_interp, with hand-written
expected words and a plain-Python LDS model for seeded random sequences. basic_alloc also pins the current
allocation rule (offsets past the declared size bound-check instead of growing the array); the old file modelled
the earlier rule.
2026-11-22 15:49:36 -05:00
9d731bc11e Merge origin/main into shader-309-wave64-lds-limit
Conflict in tools/rdna2spirv.py: both sides added a module function
before cs_dispatch_state (ds_const_extent, check_printed_encodings);
both kept. main's new ds_mskor path now goes through lds_access, so it
is bounds-checked like the other LDS accesses (test added), and the
mock Gen in main's new test_lds_atomic_minmax/xchg tests gains
lds_bound/lds_access/lds_atomic.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 17:59:04 +01:00
93d0a14066 test(semantic): add interpreter tests for LDS atomic min/max ds_min/ds_max 2026-11-22 16:17:02 +01:00