Repository navigation
Conversation
|
Test report for Tested
Not tested
Re-run on the new head AI use
|
|
Update: the head is now Test report with the title itself on a 32-lane host, which the earlier reports did not cover. This PR's head Tested
Not tested
AI use
|
fabe8bc to
a5ba4a4
Compare
|
Thank you for running the title, and for the per-program comparison: "nothing that ran on Two things changed since
Next, from your counts and that one: the programs that stop with The unchanged device removal is what I would expect: nothing in this stack touches #71. No game data used on my side. AI-assisted. |
On top of integrate/shaders2. Conflicts: - lower.rs: Marvisak#265's scratch() stays; flat() takes Marvisak#294's root SRV/UAV doc. - valu_tests.rs: the shader side's test helpers (emit with a Target) stay; Marvisak#294's two root UAV tests are appended. - shader_cache.rs: both new tests kept (Marvisak#320 wave-size key, Marvisak#358 cache that cannot keep an entry). - HostShader initialisers in scratch_tests.rs and valu_tests.rs get root_uavs; emit() calls in tests get Target::ANY. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AZ9pSB4ZoXYUifuXg8gm66
|
Rerun on
(Claude Code, Claude Opus 5.5: ran the build and the title, compared the two logs program by program.) |
…erently run in the console flow Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
The follow-up I mentioned is up as #439 (head If you rerun, the numbers that would tell the most are the count per reason on No game data used on my side. AI-assisted. |
|
Tested
On the real title path, this removed the host-pipeline refusals seen on Only aggregate counts and error classes shared, no game data or raw game logs. AI-assisted (Kimi Code). |
The validator's message for an operation the stage or the entry's
properties do not allow ("Entry function performs some operation that
is incompatible with the shader stage or other entry properties") names
neither the operation nor the property, and it is the only message when
the call is in the entry function itself.
`victory translate --validate` now adds to each validator failure what
our own module declares and calls: its thread-group size, its wave size
and its dx.op operations (`emit::last_module_summary`, kept per thread
when a module is finished). Nothing of the console program is in it, so
a report of counts per reason is enough to see what the refused modules
have in common.
Prompted by a report on Marvisak#233: modules that fail validation with that
message and still create pipelines, 20 of them new with Marvisak#320, which I
cannot reproduce with hand-assembled programs.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
|
@miniongk thank you for the run on the title. Two counts would make it usable as evidence, if you still have the logs:
Also, if you can run Counts and messages only, please. AI-assisted. |
|
Corpus-wide numbers for what was seen on one shader above:
So nearly all of what this PR unlocks goes through that phi case, which matches the #320 combination results above. AI-assisted. |
|
@EduAzevedo thank you. I think this was meant for #307: For whoever merges #307 and this PR together, since that combination was tested: I checked the merge of From reading the merge only; I did not build or run the combination. No game data used. AI-assisted. |
Im sorry, getting a little crazy here 😂 |
80f5663 took SGPR spills out of the lane reads that ask for the console's wave size, so a compute program whose only lane reads and writes are spills lost WaveSize on every host, Target::ANY included, where main gives the console's wave size and emulates the lane writes. Keep main's per-lane form there: on a host that runs the console's wave size, any v_readlane/v_writelane still asks for it. On a 32-lane host spills stay per-lane with no wave size, and the console flow still skips them. The test now wants WaveSize(64) on ANY and none on 32-32, both from the first (per-lane) pass. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Brings d5f8f2c (SGPR spills keep main's wave size where the host runs it). `whole` keeps this branch's ds_bpermute_b32 exception beside Marvisak#320's named_lane. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Pushed Verified locally: clippy AI-assisted |
…console flow for lane reads where lanes branch differently) into the integration Kept both sides in Lower::new: the instructions that decide the wave size are the live ones (dead SGPR spills through VGPR lanes do not ask for the console flow), quad derivatives count as in-half reads and numeric selects as whole-wave reads. The console and split forms of a mask ballot moved into our mask_ballot; a waterfall loop's first-lane read stays the lane's own before the console flow's arm; the wave-size checks open lower_ir; emit's threading retry passes the target on. Our tests name Target::ANY. Outside the shader crate the PR needs victory-gpu's host.rs (target()), pipeline.rs and shader_cache.rs (cache key by wave range), apps/victory main.rs and translate.rs (--host-lanes) and docs/wave64-on-wave32.md. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AZ9pSB4ZoXYUifuXg8gm66
…and Marvisak#320) Conflicts in crates/victory-shader/src/emit/lower.rs, both sides kept: - main's scalar_def/sgpr_operand/scalar_constant helpers beside Marvisak#439's numeric(); - Marvisak#439's console_read_lane beside main's helper-lane doc of helpers_read; - main's uniform_join beside Marvisak#439's never_taken (false in the console flow); - the lane-mask phi: main's number-at-a-uniform-join and no-lane-on-edge arms, with Marvisak#439's console-flow `other` masks as a fallback for the tracked mask; lane_bit now returns a Result (Marvisak#439), refused in a split program outside the console flow. Tests main added since Marvisak#439's base get Marvisak#439's new Parts fields and emit's Target argument (memory_tests heap test, mod.rs pixel-input test). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The one conflict was in apps/victory/src/main.rs, where main's `--jobs` became a `NonZeroUsize` and the branch added `--host-lanes`: `translate::run` takes both, `jobs.map(NonZeroUsize::get)` as main passes it and the branch's `host_lanes` after it. The `emit` and `lower::Parts` call sites main added in tests (census, crosslane, memory, synthetic, `emit::tests`, `resource` and lower.rs's own) pass `Target::ANY`, as the earlier merge did for the ones before them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A pure move, so that the merge of main (63bcca4) keeps emit/lower.rs under the asset policy's 512 KiB limit: the inline `mod tests` becomes `mod tests;` beside `mod bvh;`, and its body, one indent level less and otherwise unchanged, is emit/lower/tests.rs. Its `super::` paths still name `lower`. Moving the tests out of lower.rs is desplmfao's idea (Marvisak#2309). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… flow Conflicts, resolved with kawaii-shakal's notes on Marvisak#439: - emit/host.rs: main's process-wide WARP device (`SharedDevice`, `WARP_LOCK`, `lock_warp`, `from_device`) is kept, and its `create_device` takes an optional adapter for the branch's `VICTORY_ADAPTER` and `Host::on`. - emit/lower.rs: `console_read_lane` stays beside main's new `helpers_read` doc; main's `uniform_join` sits above `never_taken`, which keeps the branch's console-flow note. - Lane-mask joins: main's path for data joined with masks at a uniform join (the BVH walks pop masks from memory) stays beside the console flow's masks; `lane_bit` now returns a `Result`, so it takes `?`. `no_mask_lane_on_edge` is kept out of the console flow, whose lanes go along the wave's edges. - emit/lower/tests.rs (lower.rs's tests, moved out before this merge): main's test changes are ported there. Its `lowers` helper calls `lower` directly, so it now lowers a program again in the console flow when the first try asks for it, as `emit_with` does (`a_scalar_result_needs_no_exec`). - The `lower::Parts` sites main added in tests (crosslane, memory, synthetic, lower's) pass `console_cf: false`. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… branch Conflicts: - emit/lower.rs, lane-mask joins: the branch's console-flow masks (constants and masks built from scalars, `st.other`) feed main's `match`, which keeps main's path for data joined with masks at a uniform join (the BVH walks) and keeps `no_mask_lane_on_edge` out of the console flow, after kawaii-shakal's notes on Marvisak#439. - emit/lower.rs's tests now live in emit/lower/tests.rs (moved on the console flow branch): the branch's `per_lane_only: false` lines are ported there, and the `lowers` helper keeps the per-lane form where the console flow cannot lower a program, as `emit_with` does here. - The `lower::Parts` sites main added in tests (crosslane, memory, synthetic, lower's) pass `per_lane_only: false`. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Merged current Synthetic tests only; no title data used. AI-assisted |
Main's view-mark test builds emit::Options by hand; this branch adds a target field to Options, so the test now fills the rest from Default. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Correction to my last comment: CI's clippy failed on the previous head. Main's view-mark draw test ( Verified on #223 AI-assisted |
Main's placed-UAV diagnostics test calls emit::emit with the six arguments it had before this branch added the target. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Second follow-up: CI's diagnostics clippy ( Verified on #223 AI-assisted |
|
This triage reviewed AI-assisted |
Current head
0fa6af4, integrated withmainatffe310e. The lane-read tests use structured resource tracking. The translator retains both the mask information used by console flow and the reach conditions used by the descriptor tracker. Local Windows verification:cargo test --workspace --locked(359 passed, 6 ignored) and all-target, all-feature Clippy with warnings denied. No title run for this update. AI-assisted (Codex).Fixes #225. Stacked on #233 (which is stacked on #223); the last three commits are new here (
36e05dc,c223206,fd8b8fe; before the rebases ontomain(now8e79c80) on 2026-11-24 they were6ec772f,4c197a0,a5ba4a4, the ids testers' reports use; replayed unchanged, except that a new upstream test gets the field this PR adds tolower::Parts; CI's two clippy commands are clean at this head; the lane-read loop test now takes its devices from the SM 6.6 hardware-adapter list and skips when there is none, a fix first made at the top of the stack and folded in here).What
On the console
v_readlaneandv_writelaneignore EXEC, and a wave runs a loop while any of its lanes does. The per-lane form runs branches and loops per lane, so a lane that left a loop or skipped a branch is not there to be read or written, and never sees the scalars set inside. Two measured cases onmain:v_writelaneto lane 40 inside a branch only lanes below 20 take: lane 40 is never written (Radeon).A compute program with
v_readlaneorv_writelaneand at least one branch that is not uniform now runs in the console flow from #233 on every host: every lane of a wave runs every block, EXEC guards the vector instructions, and branches are the console'ss_cbranch_*, taken wave-wide.Parts::per_lane_only), so nothing that translated before is refused.ds_(b)permute.SGPR spills (
v_writelaneto stash an SGPR,v_readlanerestoring it) stay on main's per-lane form, since each restore is proven to be its SGPR: with the console's wave size on a host that runs it (asmain), and with no wave size on a 32..32 host, where each restore is lowered as its SGPR. Spill-only wave64 programs therefore now translate on 32-lane hosts instead of being dropped, and spill + DPP programs run split rather than in the console flow. Test:sgpr_spills_across_a_divergent_branch_stay_per_lane.docs/wave64-on-wave32.mdshows as deleted in this diff: #233 folded that plan intodocs/architecture.md, and the merge carries that up.Small generalisations of #233's helpers:
console_lanemasks with the console wave size (waves of 32 too),console_ballotreturns the host wave's ballot when nothing is split, andv_readfirstlanereads no high EXEC word in waves of 32.The second commit closes a gap in the console flow itself, found through the test report on #233: the loop form compilers emit keeps finished lanes in an exit mask that starts as a constant 0, and the console flow's mask joins took only masks derived from EXEC or a VALU result, so such a loop stopped with
a lane-mask join of an untracked mask.Structured::othersnow gives the lane's bit of constant and scalar-built masks for those joins. The per-lane form is unchanged.How this relates to other open PRs
#269 makes scalars leave divergent loops and branches as the wave left them, with maxima over the host wave. In the console flow scalars are the wave's own by construction: with a local switch sending #269's four test programs through it, all four are exact on both adapters here, where #269's two scalar tests give per-half values on hosts that form 32-lane waves (details). This PR does not select the console flow for those programs.
In compiled shaders, the usual source of
v_writelane/v_readlaneoutside whole-wave sections is SGPR spill slots: a scalar parked in a lane of a VGPR and read back later, whatever EXEC holds. #54 and #189 resolve spills at constant lanes in SSA, so the lane accesses disappear and the control flow stays per lane. Where that applies it is cheaper than this PR, and the two compose: with spills resolved first, fewer programs would ask for the console flow. This PR covers what is left: lanes computed at run time, and reads of another lane's own data.Not verified
No game files and no console hardware were used: the expected values follow the ISA's EXEC and lane-access semantics. I did not measure how many of the title's programs take this path, or its cost on them. A tester's whole-title translate found 21 more compute pipelines than #233, 20 of them in the validation class above. The console flow guards instructions where the per-lane form branches around them, so a divergent program does more work per lane.
The fallback to the per-lane form has no test of its own; I found no hand-assembled program that the console flow refuses and the per-lane form takes.
Vertex, pixel and mesh programs are unchanged.
Tested
Windows 11, an NVIDIA RTX 5070 (32..32) and an AMD Radeon iGPU (RDNA2, 32..64) in one machine, hand-assembled GFX10, every lane checked:
emit/lane_read_loop_tests.rs(the Shaders: v_readlane inside a loop the lanes leave at different iterations reads wrong lanes (wave32 and wave64, every GPU) #225 repro, no longer ignored): exact on both adapters in waves of 32 and of 64 (on the RTX 5070 the wave64 program runs in two halves).split_tests::lane_writes_reach_lanes_outside_the_branch: exact on both. With the new condition switched off it fails on the Radeon (lane 40 keeps 1).split_tests::loops_run_while_any_lane_of_the_console_wave_doesnow checks 64-lane hosts too.split_tests::loops_with_an_exit_mask_grown_from_zero(the compilers' loop form, a lane read in each iteration, the exit mask counted afterwards): refused on the RTX 5070 before the second commit, exact on both adapters now.cargo test --workspace: 281 passed, 0 failed, 4 ignored ata5ba4a4(two testers report the same count; 280 was the head before it).cargo clippy --workspace --all-targets: nothing new.cargo xtask policy: ok.AI-assisted; no game assets were used.
🤖 Generated with Claude Code