Repository navigation
Shaders: descriptors joined by nested control flow - #1012
ThiagoAlexsander wants to merge 1 commit into
Conversation
A descriptor every lane shares, chosen by an if/else nested in another, reaches the outer join with an edge that is itself a join. Such an edge was refused with "a descriptor chosen by control flow": each edge had to be a heap load. The heap index is now computed recursively: a load's index, or a phi at the join of what each predecessor computes at its end. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Independent validation of
For the missing GPU check, I temporarily extended the new regression to construct a Full workspace unit/integration suite, all features, all 14 generated Windows MSVC test executables, Rust 1.98.1:
All five failures match baseline: empty pipeline library (#347), missing Wine Winsock export (#217), the shader-checksum rejection expectation, the nested Cargo fixture build, and Windows xtask attempting to launch host Git. Native Linux xtask separately passes all 4 tests. Windows-target workspace Clippy, all targets/features with Tests ran offline and offscreen, with native AI-assisted testing with Codex. |
The validator module is Windows-only, so the test upstream Marvisak#1012 added did not compile on Linux (lint and test (ubuntu-latest)). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Independent verification at
Aggregate counts only; no game data posted. AI-assisted; all builds and tests executed on my machine. |
Head 0ba5b99 (ThiagoAlexsander). Conflict in lower.rs: the join arm of handle takes #1012's uniform_heap_index, which now gathers the loads it reaches so #568's table views are still recorded for each of them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…table names Brings #193's runtime stride table (#155) with #704's raw view pool. Conflicts and fitting it to this tree: - Heap layout is title slots, dynamic slots, the guard slot, then the raw view pool (alias_base = count + extra + 1). A heap capped at PORTABLE_VIEWS takes a pool of 2^14 (ALIASES_CAPPED), not 2^16, since each pool slot is a mirrored title slot less. - Stride entries follow every slot write of ours: mirror, make_at, the bindless buffer and placed-texture slots, typed nulls, null kinds, raw_at, bindless CBVs and unmapped nulls. - viewed_bytes cuts the raw view to its host copy as make does (cut_to_copy), so the host never refuses it. - stride_entry gets the slot through our uniform_heap_index (#1012); #704's heap_slot is dropped. handles keeps our props key. - Our cut_to_copy clamps stay in buffer_srv/uav; #704's are dropped. - The tests pass the heap guard in its user-data dword, take our make_at and emit signatures, and count the guard slot. - Shader cache MAGIC VSH3, KeySpec version 3 (stride_table encoded). - Formatting-only hunks from #704 left out. translate --host-lanes 32-32: compute 2285 -> 2487, vertex/geometry/pixel 14186 -> 14256 (with #1073, #1084, #416 before it), mesh 8381 -> 8383; "a structured buffer of unknown stride" 206 -> 0. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Indirect lighting's CS_ScreenProbes_ActivateRays picks a descriptor in nested branches. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> # Conflicts: # crates/victory-shader/src/emit/lower.rs
…xel shader A refused pixel shader dropped every draw of its mesh or vertex pipeline, geometry included. The stand-in (emit::host::stub_ps: reads nothing, writes zeros to target 0) keeps the geometry drawing: depth and shape, a flat placeholder in target 0. On by default; VICTORY_NO_STAND_IN_PIXEL=1 turns it off. Also gates Marvisak#1012's validator test to Windows (the validator module is Windows-only), so the native test run builds. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit 18701e55fbc9065eea6d7fa67ef1819335d40d72)
|
Automated triage for the maintainers. Needs rebase. This PR does not merge cleanly into current The content has not been reviewed yet; it will be once the branch is rebased onto Generated by Claude Code |
A descriptor every lane shares, chosen by an if/else nested in another, reaches the outer join with one edge that is itself a join (
Source::PhiinsideSource::Phi).handletook only heap loads on a join's edges and refused this witha descriptor chosen by control flow. In the title this stopsindirect_diffuse_lighting:CS_ScreenProbes_ActivateRays.Change
uniform_heap_index: a load's heap index, or, for a join, a phi of the index each predecessor computes at its end, recursively. It is the old loop of theSource::Phiarm with the edge's source traced instead of required to be a load.handle'sSource::Phiarm calls it. A join whose edges are all loads emits the same DXIL as before.Results
victory translate --validateover the title's files (mainffe310eagainst this branch, Windows SDKdxil.dll10.0.26100), compared program by program: compute validated goes from 1,417 to 1,418 (CS_ScreenProbes_ActivateRays). No other program changes.Testing
descriptors_joined_by_nested_control_flow_lower_to_one_uniform_handleinemit/lower.rs: hand-written words choosing between two texture descriptors of the view table through nested if/else on a root constant. It lowers to one uniform image handle and passesdxil.dll. Onmainit fails withUnsupported { "a descriptor chosen by control flow" }.cargo test --workspace --locked: 343 passed, 0 failed, 6 ignored (342 onmainplus the new test).cargo clippy --workspace --all-targets --locked -- -D warnings, with and without--all-features: clean.rustfmt --edition 2024 --check emit/lower.rs: no new hunks (the three in thev_permtest are onmaintoo).cargo xtask policy: 154 files ok.Independent of #1008, which handles immediate samplers chosen by control flow; the two touch different arms of
handle.AI use: Claude Code (Claude Opus 5.5) found the case with the census, wrote the change and the test, and ran everything above. I reviewed the diff and the results.
🤖 Generated with Claude Code