test: count the s_mul_hi templates in the scalar arity control #2696
No reviewers
Labels
No labels
accessibility
awaiting author
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
priority: P0
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/R0Y00--Xbox2Windows!2696
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/2696/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?
@tedin7 on GitHub · 2026-11-26 02:22 UTC · original
tedin7:fix/scalar-arity-control-mul-hi→main· +10 −8 · 1 files · 1 commits · closed without mergingPart of #1723
What this unblocks:
mainpassesstartup_gfx2hlsl_scalar_table_arity_checkagain, so Win2025 runs for every shader PR stop failing on this check.What
#2405 gave
s_mul_hi_u32ands_mul_hi_i32their own operand-count refusal (... expected 3). The negative control intests/startup_gfx2hlsl_scalar_table_arity_check.py(from #2515) removes the genericlen(srcs) < neededguard and expects every two-source template except one (s_bfm_b32) to raiseIndexError. Now three templates refuse by themselves, so onmainthe control reportsMISMATCH 37 of 40and the check exits 1.This PR names the templates that keep their own arity check (
OWN_ARITY = {s_bfm_b32, s_mul_hi_u32, s_mul_hi_i32}). The control now asserts that exactly the other templates raiseIndexError, and that the named ones still refuse with their own message. Only the test changes.tools/startup/gfx2hlsl.pyis untouched.Verification
Linux:
git checkout origin/main(e76f8acd5):python3 tests/startup_gfx2hlsl_scalar_table_arity_check.pygives 1 failed (control ... MISMATCH 37 of 40). The same check passes onf27737c36(the commit before #2405) and fails on6d92f2a8f(#2405).python3 tests/startup_gfx2hlsl_scalar_table_arity_check.pygives 0 failed.if base in ('s_mul_hi_u32', 's_mul_hi_i32') and len(srcs) != 2:withif False:intools/startup/gfx2hlsl.py. The check then fails 2 (extra ['s_mul_hi_i32', 's_mul_hi_u32']). The change was reverted afterwards.python3 tests/startup_gfx2hlsl_mul_hi_i32_check.py: ok.git diff --check: clean.Win2025: not run yet (Draft). This is a pure-Python check with no arguments, so it runs in the Windows Python-check step.
AI-assisted; commands listed were executed locally.
@tedin7 on GitHub · 2026-11-26 02:26 UTC · original
Superseded: #2659 (merged as
ad1ad194a) carries the same arity-control fix (c8e05375).python3 tests/startup_gfx2hlsl_scalar_table_arity_check.pyon mainad1ad194a: 0 failed. Closing this draft.AI-assisted; commands listed were executed locally.
Pull request closed