| Age | Commit message (Collapse) | Author |
|
CCS serves both v_cmp (VOPC, where v_cmp_ne_* exists) and the sif shape's
s_cmp, but SOPC has no 'ne' encoding: rdna2spirv correctly refuses
s_cmp_ne_u32 (tests/semantic/test_sopc_validation.py lists it as a
nonexistent mnemonic). One of the six seeded programs then came back as
'translator unsupported: s_cmp_ne_u32' and test_small_fixed_seed_run_is_clean[structured-32]
failed with pass 5 != 6 (dispatch-loop-32 likewise). Map 'ne' to the
real encoding 'lg' at the scalar emission site only; the vector compares
keep v_cmp_ne_*.
(cherry picked from commit 9ccfea42211aa7268ddd5a91ff2b9f0eb20adb1a)
|
|
(EGEN-FUZZ-LAZY-IMPORT)
Both tools set sys.dont_write_bytecode and imported rdna2spirv at the
top, so on a checkout without __pycache__ every start compiled the
translator before parsing the arguments: about 20 s to print a usage
line, which made test_no_arguments_prints_usage time out (5 s) in
tests/test_f32_fuzz.py and tests/test_cf_diff.py. They now import it in
the functions that use it.
Also removes the second, identical CliTests class in
tests/test_f32_fuzz.py, which replaced the first one at import.
Supersedes #5056, which conflicts with main.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
|
Squash-merged after diff review of PR #6659
|
|
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
|
(review)
|
|
skipped
|
|
|
|
|
|
|
|
|
|
|
|
open(path, "w") without newline= turns each \n into \r\n on Windows, so the same JSON report, manifest or assembly
listing was CRLF there and LF elsewhere. 91 text-mode writes (open, os.fdopen, Path.write_text) under tools/, scripts/,
make_game.py and runtime/test/shaders/ now pass newline="\n". tests/test_text_write_line_endings.py reads the source
with ast and fails for a writer that forgets it; CONTRIBUTING.md names the convention.
AI-assisted (Claude), on behalf of dev-ewann.
|
|
On Windows a redirected stdout uses the console's ANSI code page, and python -I ignores PYTHONUTF8 and
PYTHONIOENCODING, so a caller path with a character outside that code page ended a run with
UnicodeEncodeError as soon as a tool printed it. #1406 fixed make_game.py; every CLI tool in tools/ now starts
its __main__ block the same way (stdout errors="replace").
tests/test_tool_stdout_encoding.py checks every tool's __main__ block and reruns two measured crashes
(analyze_4240_full.py, meshlet_page.py) with a private-use-named input. Found by @abilliontokens.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
|
wave-wide
tools/cf_diff.py generates seeded wave32/wave64 pixel shaders from the
control-flow shapes compilers emit (saveexec if/else, v_cmpx, VCC- and
SCC-voted branches, uniform and per-lane loops, two-entry cycles) and
compares every lane's export between:
* tools/cf_ref.py: cpu_ref's Machine plus branches, compares, v_cmpx,
saveexec and 64-bit masks (the ISA model, one wave)
* rdna2spirv + tests/semantic/spirv_wave_interp.py: every invocation of
one subgroup in lockstep, split at selections and rejoined at merges,
with the subgroup operations the translator emits
in both the structured and the dispatch-loop form; --spirv-val also
validates each module, --minimize reduces a mismatch.
Finding (fixed here): in a wave32 program s_and/or/xor/andn2/orn2/nand/
nor/xnor_b32 on lane masks set SCC from the lane's own bit instead of the
whole mask, so `s_and_b32 s0, vcc_lo, exec_lo; s_cbranch_scc0` and loops
closed by `s_andn2_b32 exec_lo, ...; s_cbranch_scc1` split the wave. SCC
is now the same subgroup vote as for the _b64 forms. GPU test
ps_scc_mask32 (not run on a GPU yet).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|