Repository navigation
startup: accept entry-prefix DPP broadcasts when a later loop exists - #2657
Conversation
A later uniform loop used to refuse every DPP16 quad broadcast in the same pixel stage via has_branches, even when the broadcast still ran in the entry prefix under s_wqm with EXEC unchanged (M200-01/003). Keep the blocks/exec/wqm gates so a broadcast after a branch target or with divergent EXEC stays refused. Extend the broadcast fixture with a loop case, divergent control, and the same CPU lane reference for draws. Refs R0Y00#2618, R0Y00#2125 Co-authored-by: SimSalabimse <SimSalabimse@users.noreply.github.com>
Split the non-ps check from the entry-prefix gate so startup_gfx2hlsl_cvt_off_f32_i4_check still matches "straight-line pixel stage" while later loops stay accepted. Refs R0Y00#2618 Co-authored-by: SimSalabimse <SimSalabimse@users.noreply.github.com>
|
I kept your vertex diagnostic fix in |
tedin7
left a comment
There was a problem hiding this comment.
Review of head f84124e (main merged in), comment only.
Checked:
Stage.dpp_broadcastnow gates onpast_entry(set at gfx2hlsl.py:2731 fromblocksor a branch to offset 0) plusexec_knownandwqm_exec, instead ofhas_branches. This keeps the proof: the broadcast must sit in the entry prefix, with EXEC equal to thes_wqm exec, execmask. A later loop or forward branch cannot reach back to the prefix, so the whole quad is still active. Vertex stage stays refused.- Sibling gates (the fi:1 form near line 3462 and the other
has_branchesusers) are unchanged and still conservative. - No other open or merged PR covers this slice (searched DPP broadcast / quad_perm: #2140, #2143, #2483 are the earlier forms this extends).
- Test: the new loop fixture runs the same four-lane integer program with a two-trip scalar loop against an independent CPU lane reference, with wrong-lane and own-lane mutations, plus refusals for broadcast after a branch target, branch back to the entry block, and divergent EXEC.
Commands run (Linux, on the head):
python3 -B tests/startup_gfx2hlsl_dpp_quad_broadcast_check.py-> all okpython3 -B tests/docs_links_check.py,python3 -B tests/bidi_controls_check.py,python3 -B tests/startup_gfx2hlsl_handler_arity_check.py-> okgit diff --check origin/main...HEAD-> clean- Mutation: replacing the
past_entrygate withFalsemakes the check FAIL ("broadcast after a branch target", "branch back to the broadcast entry block" refusals), so the new refusals guard the behavior. - CI on this head: all required jobs green.
Scope note: this is fixture and code review only. The PR refers to the M200-01/003 shape but does not claim a verified startup advance; no executable result is claimed here. Win2025 WARP receipt follows in a separate comment.
AI-assisted; commands listed were executed locally.
Change
Refs #2618 (batch M200-01, ticket M200-01/003) and #2125 item A.
The pixel translator refused every DPP16
quad_perm:[k,k,k,k]broadcast once the stage contained any branch, including a later uniform loop that never touches EXEC. That matches the M200-01/003 shape (broadcast early, loop later).Stage.dpp_broadcastno longer gates onhas_branchesalone.blocks,exec_known,wqm_execafters_wqm exec, exec.loopkind.AI-assisted.
Verification
Commit under test: this PR head.
python3 -B tests/startup_gfx2hlsl_dpp_quad_broadcast_check.py # all ok (includes loop fixture + divergent refusal) python3 -B tests/docs_links_check.py python3 -B tests/startup_gfx2hlsl_handler_arity_check.pyAll passed on Linux. This agent could not run DXC / WARP / hardware draws.
Windows verification:
Expect: controls pass;
startup_gfx2hlsl_dpp_quad_broadcast_warpmatches all 256 pixels for integer, float and loop (wrong-lane / own-lane mutations fail the reference); hardware may pass or skip 77.Evidence and follow-up
Checklist