Shaders: wave64 compute programs run in 32-lane halves on hosts of 32-lane waves #2631
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/2633"
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?
Imported from Marvisak/VIctory. Originally posted by chippy01 on 2026-11-25T17:15:20Z.
The problem
A console wave64 compute program that needs the console's lanes (cross-lane reads, masks read as numbers, LDS one wave shares) declares
WaveSize(64). NVIDIA and Intel run waves of at most 32 lanes (WaveLaneCountMax32) and refuse it. On an RTX 3070 Ti the debug layer says:and the pipeline is refused with
E_INVALIDARG. A Series S run to the loading screen refused 100 compute pipelines; 95 of them were for this reason.The change
On such a host, a wave64 program that needs the console's lanes is translated for waves of 32 ("halves",
emit::lower::halves, set byemit::Options::host_wave32). The thread relabelling gives each host wave a 32-aligned run of thread ids, so host wave2w + hholds lanes32h..32h + 31of console wavew. What each cross-lane operation needs, and where the halves can meet, is indocs/wave64-on-32-lane-hosts.md.Level 1, exact within a half (the first commits): DPP rows,
ds_swizzle, andds_bpermute_b32, which the console's wave64 permutes within each half on its own (RDNA2 ISA; measured on RDNA2 in #573). A lane's bit of a mask held as a number,v_writelane_b32,v_mbcntand the row a DPP row mask names take the console lane. A first-lane read of a value proven the same in every lane of the console wave (halves::lane_uniform) is the host's. A group of 32 threads or fewer is one host wave, which holds its whole console wave.Level 2, the halves trade where every thread meets (
Lower::trade): each half writes its words to group-shared slots, a group barrier, each half reads both, a second barrier. Only at blocks every thread of the group reaches the same number of times (no lane-dependent branch has them in its region; in groups of several console waves, no branch at all), since a barrier one half skips hangs NVIDIA. Where the program's LDS takes the host's whole 32 KiB and leaves the slots no room, they are its first dwords, borrowed: saved before the trade and given back after, three barriers more for such programs only.v_readlane_b32: the half holding the lane gives it.v_readfirstlane_b32: each half's first lane in EXEC and whether it has one; the low half's if any.Level 3, inside a branch or a loop only some lanes run (the per-lane form turns the console's wave-wide tests,
s_cbranch_execzands_cbranch_vcczon a ballot, into such branches and loops):emit::lower::confine): where a block's entry condition shows that only one half's lanes can run it (tid < 16in an LDS tree step), that half's host wave runs it alone, in the console's order, and nothing crosses.emit::lower::wide): otherwise the region runs wave-wide (the blocks not every thread meets at, entered from one block and left to one or reaching the program's end): every thread runs every block of it, each block acting only in its own lanes (guards take the block's lanes in, join phis pick per lane by the edge it came by), so the halves trade and order LDS there. A branch the whole group takes together (a scalar compare in a group of one console wave, as the title's programs open with to skip their work) may also go around the region to its join, or into it past its head: the group then runs the region from its first block with every lane in the block it went to and none before, and a descriptor chosen by control flow where it goes in is the console wave's scalar, folded as below.Lower::wide_fold,wide_keep_block). A join that reads a scalar whose value differs by the way a lane came, outside such a region, runs its region wave-wide on the next attempt (Lower::scalar_join).First lanes alone bring a program into halves. A wave64 program whose only cross-lane read is the first lane of a value
halves::lane_uniformdoes not prove alike in every lane now runs in halves too (halves::first_across); before, each 32-lane host wave read its own first lane (lane 32's in the upper half). Should every attempt in halves fail, it is lowered as before, each host wave reading its own first lane, which is exact for the compiler's scalarization loops and for values it keeps the same in every lane (one title program, a scalarization loop).Sections the simulation cannot follow run step by step (
halves::Literal): a whole-wave reduction the console compiler expands can leave a value whose lanes hold different things (each half's sum in some lanes, the wave's in others), which a later masked write keeps in the lanes it leaves out. Main keeps such a value as zero there; in halves, where every thread meets and the group is whole console waves, the section now runs instruction by instruction (DPP and the lane permutes within a half, its lane reads across the halves traded), so those lanes hold the console's values. In a block run wave-wide the steps run in every lane of the console wave and the section's lanes are the block's (a reduction there counted lanes that had left the loop), and a section where not every thread meets runs its region wave-wide. 16-bit sums run the same way, each step rounded as the console's.v_permlane16_b32andv_permlanex16_b32are lowered per instruction in compute on every host (before, only inside sections).Still refused, each with a reason naming the host: a cross-half read in a region of neither shape (1), groups of several rows a host may tile (rows 32+ threads wide or not a power of two; measured here and in #2126; 6).
Two fixes to this PR's own earlier commits, found by the random tests: a loop's latch (and a loop of one block) counted as a point where every thread meets, so a trade there put barriers in a loop the two halves may go round different numbers of times, which hangs NVIDIA; and a value written in such a loop counted as the same in every lane after it, though each lane holds its own last round's (a first-lane read after the loop gave the upper half lane 32's value). No program of the title changed outcome.
victory-gpuasks the device once (D3D12_OPTIONS1) and translates for it. The shader cache keys on it, so entries made for 64-lane hosts are never read on a 32-lane one, or the other way round.victory translate --wave32translates for such a host offline; with--pipelinesit follows the GPU that makes them.New code lives in
emit/lower/halves.rs,confine.rsandwide.rs, with a few named hooks inlower.rs;lower.rs's unit tests move tolower/tests.rs(as #233 does), solower.rsis 480,649 bytes, under the policy's 512 KiB cap.Evidence
victory translate --list --wave32 --validateovershaders.rpf, the executable,XboxBvhBuilder.dllandamd_fidelityfx_upscaler_xbox.dll; compute programs emitted (of 2,763), commit by commit, none lost on the way:86a16dc)--pipelineson the RTX 3070 Ti (driver 621.24): 2,727 of 2,727 compute pipelines made, none refused by the driver; vertex/pixel 14,258 and mesh 8,765 (25,750 in all). In the title's own pipeline pack, the compute pipelines skipped because their shader does not translate go from 292 (the stack before Level 3 loops) to 60.e2d3cfd, on the samemain, same inputs): this translates 68 compute programs #439 refuses (44 in groups of more than 64 threads, 11 that reach title memory by address, 11 implicit-derivative samples, 2 lane permutes), and #439 translates 4 this refuses: the tiled group shapes, which in its split form give some threads another thread's id on NVIDIA (measured on the RTX 3070 Ti).Lyrnc's fw64 cases (151 hand-written wave64 programs, gist, results of a gfx1036 running them in wave64 as the oracle; run here with a local harness, not committed), exact / differ / refused in halves, the same on the RTX 3070 Ti and the Radeon iGPU:
b32cef7main's form, native wave64 (Radeon)v_readfirstlanein a branchv_readlanein a branchv_writelanein a branchs_cbranch_scc0)The 20 that still differ also differ in
main's native wave64, in the same words, and halves is never wrong where it is right:v_writelane_b32to a lane outside EXEC (8), thes_cbranch_vcczvote loops (7) and a loop-mask exit block the console runs with the last round's lanes only (5), which the per-lane form decides per lane (the console flow, #320, handles them).Earlier, at the first commits, on the RTX 3070 Ti (driver 32.0.16.2124): main refused 405 compute pipelines (the driver), this PR none; in the title (Series S mode, to the loading screen) no pipeline refused (main: 100).
Tests
emit::halves_testsruns hand-encoded programs on every hardware adapter, in halves everywhere and as one wave64 where the adapter has 64-lane waves, against the console's results: an RTX 3070 Ti (halves) and the Radeon iGPU of a Ryzen 9 7900X (RDNA2, halves and wave64), 0 lanes differ.v_mbcnt,v_writelane, constant masks, DPP row masks, first lanes kept, every thread's id in 4x4x4 to 64x1x4 groups (and tiled shapes refused).bound_ctrlandfi, in groups of 48, 64 and 128.lane_read_loop_tests); the console's wave64 sum run step by step in a wave-wide branch.emit::halves_random_testsgenerates random wave64 programs (cross-lane steps at the top level, in branches one inside another and in loops each lane leaves in its own round, LDS, scalar branches, lanes that end partway, whole-group branches around or into a lane branch) and runs each in halves on both GPUs and as one wave64 on the Radeon, lane by lane: 3,000 seeds, 2,999 compared, none refused in halves, 0 differ (seed 1922, which crashes the Radeon driver's compiler making the one-wave64 reference, is skipped). It found the kept-value bug and the two loop bugs above, each fixed in its own commit, a Radeon compiler fault after a loop with a second way out, which the loops avoid, and two places where a region that could run wave-wide was not asked for.Checks:
cargo clippy --workspace --all-targets --locked -- -D warningsand the same with--all-features: clean.cargo xtask policy: ok.cargo test -p victory-shader --lib -- --test-threads=1: 332 passed, 3 failed, the same 3 as onmainon this NVIDIA machine (stride_tests::a_heap_buffer_read_by_element_takes_the_views_stride,stride_tests::a_heap_buffer_read_where_no_buffer_view_is_reads_zeros,synthetic_tests::gathers_at_a_level_match_the_hardware);memory_tests::heap_direct_texture_reads_mark_their_heap_indexcrashes the test process onmainhere too and is skipped.Related pull requests
This overlaps #189, #192, #233/#320/#439, #1890, #2176, #2214, #2711 and #2925 (wave64 on 32-lane hosts) and #578 (refusing them). It differs in that cross-half reads are refused or traded at the site that makes them, with a reason (programs whose crossing value is unused still translate), the halves meet only where every thread provably does (wave-wide only where needed, instead of the console flow everywhere), and every form is checked against the console's own wave64 on an RDNA2 adapter in the same test. The cache-key idea is #2176's (n-romanovich). It does not change
ds_bpermute_b32for 64-lane hosts, which is #573's.Credits
5f4c3df,set_host_max_wave), which credits the victory-world-runtime line (ZSlayerHQ and contributors). Here it is written anew on main as a translation option.ds_bpermute_b32within halves: #573 (banbanzhige) and the RDNA2 measurements in its thread.halves::lane_uniform), and the first-lane bug report: justrealyme (chippy01/VIctory#1), ported from fxceless/victory-fork (#497 there).lower.rsas in r4tedx's #233.lane_read_loop_tests), ColorMeBoom's run that found the reduction counting lanes that had left a loop, and carlosmegino's and TaynanGT's matched controls. #269 (TheHoracio) gives scalars the same meaning inmain's per-lane form on hosts whose waves are the console's.AI-assisted (Co-authored by Claude Opus 5.5) and measured on my own machine.
Imported from Marvisak/VIctory. Originally posted by Aniseto on 2026-11-25T17:17:28Z.
Ran the new halves tests at
a7e78c1(clean PR head onmain13f91ca):System
rust-toolchain.toml), MSVC 14.44.35207, DXIL validator from the Windows SDK default path (this filter does not print its version), debug buildResults
cargo test --locked -p victory-shader --lib emit::halves_tests -- --test-threads=1 --nocapture: 5 passed, 0 failed, 0 ignored, 273 filtered out (exit 0)wave64_programs_in_halves_match_the_console_on_every_gpuprinted:NVIDIA GeForce RTX 5070 Ti (halves): 0 lanes of 64 differ from the console, andNVIDIA GeForce RTX 5070 Ti (wave64): no pipeline for 64-lane waves; skipped, twice (both adapters in the host list).What this adds
The author's hardware evidence in the thread is an Ampere RTX 3070 Ti plus an RDNA2 iGPU. This adds a Blackwell wave32 part: the GPU parity test ran here and all 64 lanes matched the console's result in the halves form, while the 64-lane form was refused by the adapter as expected. The other four halves tests also pass.
Not tested
The whole
victory-shaderlibrary (the description lists three pre-existing failures on NVIDIA),victory-gpu, the retail shader-pack census, a title run, the console compiler, release profile, Intel GPUs and native-wave64 hardware.AI-assisted (OpenCode), model: DeepSeek V4.1 Flash Free - checked out the PR's head commit in a detached worktree, built it, ran the tests, wrote this report; the worktree was not modified; no game data was used.
Update (25/11, after the head moved to
25db879): relative to the head I tested (a7e78c1), the new commit only changes README.md; no shader code changed. Re-ran the same command at25db879:Same GPU output:
NVIDIA GeForce RTX 5070 Ti (halves): 0 lanes of 64 differ from the console, and the 64-lane form skipped because this adapter has no 64-lane waves.Imported from Marvisak/VIctory. Originally posted by kotekompotek on 2026-11-25T17:49:44Z.
Heads-up: the README hunk contains a committed merge conflict —
<<<<<<< HEAD/=======/>>>>>>> a7e78c1markers are in the diff (GPU: world + Shaders table rows). The branch needs a rebase resolving that hunk (keep the new wave64-halves text), otherwise the table renders the raw markers.The actual change —
--wave32translate flag conflicting with--cache, wave64 split halves on 32-lane hosts — looks right otherwise; CI green.Imported from Marvisak/VIctory. Originally posted by chippy01 on 2026-11-25T17:56:10Z.
My bad, I just fixed it
Imported from Marvisak/VIctory. Originally posted by sergiocr06 on 2026-11-25T18:01:49Z.
Ran the halves tests on a machine that has both kinds of host, a 32-lane NVIDIA dGPU and an RDNA3 iGPU with native wave64, so
wave64_programs_in_halves_match_the_console_on_every_gpuchecks all three paths on one box. PR head25db879onmain13f91ca.System: RTX 5060 Laptop GPU 8 GB (Blackwell, driver 610.47) + Radeon 780M (RDNA3 iGPU, driver 32.0.31018.1), Ryzen 7 260, 32 GB, Windows 11 build 26300, Rust 1.98.1, debug build, validator from Windows SDK 10.0.26100.
Full
victory-shader --lib:13f91ca--skip heap_direct_texture_reads_mark_their_heap_index, #2571)The 3 are the known NVIDIA failures (#1835):
stride_tests::a_heap_buffer_read_by_element_takes_the_views_stride,stride_tests::a_heap_buffer_read_where_no_buffer_view_is_reads_zeros,synthetic_tests::gathers_at_a_level_match_the_hardware. No regression on either GPU.Note for hybrid-laptop testers:
Host::newin the test host takes the first adapter with dedicated memory. On this laptop that is the 780M (it reports a 417 MB carve-out), so a plaincargo testruns the single-adapter hardware tests on the iGPU, not the NVIDIA card. I forced the dGPU with a per-exe GPU preference (HKCU\Software\Microsoft\DirectX\UserGpuPreferences,GpuPreference=2;) and confirmed withnvidia-smithat the test process was on it.AI-assisted (Claude Code); the runs were done on my machine.
Imported from Marvisak/VIctory. Originally posted by justrealyme on 2026-11-25T18:09:38Z.
Tested this on an RTX 5070 Ti (driver 621.40, Windows 11). The halves tests pass here too. I found one wrong result, though:
v_readfirstlane_b32in halves reads the host wave's first lane, which is console lane 32 for the upper half. Dispatched in halves (withv_mbcntso the program has console lanes),v_readfirstlane_b32 s12, v0gives 32 in all 32 upper lanes; the console gives 0.Fix with tests: chippy01/VIctory#1 (onto this branch, rebased on
360f8aa). It keeps the first-lane read only for values proven alike across the console wave, ported from the analysis in fxceless/victory-fork, and refuses the rest with a reason. Offline over the title, 12 of 2,372 compute programs drop out with that reason; nothing else changes. On the GPU, alike values give 0 of 128 lanes wrong on the 5070 Ti and the Intel iGPU.AI-assisted (Claude Code); no game data.
Imported from Marvisak/VIctory. Originally posted by KainanP on 2026-11-25T18:17:02Z.
On a machine that also has a 16-lane Intel iGPU (UHD
8086:a78b,WaveLaneCount16..16),wave64_programs_in_halves_match_the_console_on_every_gpufails withIntel(R) UHD Graphics (halves): no pipeline, becauseeach_hardware()lists the iGPU and that driver refusesWaveSize(32)too. On that device the PR also keepsWaveSize(64), which is refused. On the RTX 4060 the halves form is exact (0 of 64 lanes differ). Details and table: https://github.com/Marvisak/VIctory/issues/2220#issuecomment-7170692046AI use: Claude Code (Claude Opus 5.5) ran the tests and wrote this.
Imported from Marvisak/VIctory. Originally posted by Mericas77 on 2026-11-25T18:51:57Z.
Tested on NVIDIA: RTX 4070 (the only adapter), driver 621.01, Windows 11, rustc 1.98.1. Head
360f8aaagainstmain13f91ca. That's an Ada card, a generation after the 3070 Ti in the description.halves_tests(--test-threads=1): 5/5 pass.wave64_programs_in_halves_match_the_console_on_every_gpuprints(halves): 0 lanes of 64 differ from the consoleand(wave64): no pipeline for 64-lane waves; skipped, which is the expected result on a 32-lane host.victory-shader --lib(with--skip heap_direct_texture_reads_mark_their_heap_index, #2571): 271 passed / 3 failed. That'smain's 266 plus the 5 new tests, and the same 3 known NVIDIA failures (a_heap_buffer_read_by_element_takes_the_views_stride,a_heap_buffer_read_where_no_buffer_view_is_reads_zeros,gathers_at_a_level_match_the_hardware).victory-gpu: 193 passed / 2 failed, the same asmain(the two 1,000,000-view heap-cap tests).No regression on Ada. No game data; the title was not run.
AI-assisted.
Imported from Marvisak/VIctory. Originally posted by chippy01 on 2026-11-25T18:37:31Z.
If this PR gets merged, I'll follow up by working on a way to implement Selective Cross-Wave Communication or, alternatively, a Hybrid Wave64 (32 physical + 32 virtual lanes) approach. The goal would be to allow the compiler to correctly execute instructions that require communication between lanes 0–31 and lanes 32–63.
In my opinion, addressing the underlying problem at its root is a better approach than introducing workarounds to bypass its limitations.
If this PR doesn't get merged, I'll still try to pursue at least one of these approaches, applying it to whichever alternative PR gets merged.
If anyone has any ideas or suggestions, I'll be glad to listen.
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-25T20:15:08Z.
Independent run on another machine: Ryzen 9 9950X3D with an RTX 4090 (driver 32.0.16.2140) and the CPU's Radeon iGPU (RDNA2, driver 32.0.21045.29003), Windows 11 26H2.
victory translate --list --pipelinesover the same four inputs as in the description,main13f91caagainst this PR360f8aa, pipelines made on the RTX 4090:mainEvery pipeline made on
main(25,347) is made here too, and 44 are new. The programs this PR refuses give their reason: 192 LDS in a one-wave group, 107 ballots, 48 lane reads across halves, 20 reductions.halves_testswith--nocapture, which lists both adapters:cargo test --release -p victory-shader --lib -- --test-threads=1, skippingmemory_tests::heap_direct_texture_reads_mark_their_heap_indexas in the description:main266 passed and 3 failed, this PR 271 passed and the same 3 failed (stride_tests::a_heap_buffer_read_by_element_takes_the_views_stride,stride_tests::a_heap_buffer_read_where_no_buffer_view_is_reads_zeros,synthetic_tests::gathers_at_a_level_match_the_hardware).Imported from Marvisak/VIctory. Originally posted by qtLkz on 2026-11-25T20:53:54Z.
Tested on NVIDIA Ada, a 32-lane-only host: RTX 4070 Ti, driver 621.01, Windows 11 Pro build 26300, Rust 1.98.1 pinned, this PR merged onto main
13f91ca(clean merge).cargo test -p victory-shader --lib --locked -- --test-threads=1 --skip heap_direct_texture_reads_mark_their_heap_index(The skipped test crashes the NVIDIA driver on main, #2571. The fix is in #2596 / #2587.)
All 5 new tests pass:
halves_tests::wave64_programs_in_halves_match_the_console_on_every_gpu ... okhalves_tests::a_wave64_program_reading_lanes_declares_32_lane_waves_in_halves ... okhalves_tests::reads_across_32_lane_halves_are_refused_with_their_reason ... okhalves_tests::lds_of_a_one_wave64_group_is_refused_in_halves ... okhalves_tests::the_test_program_is_what_its_comments_say ... okWhole lib: 271 passed, 3 failed, 3 ignored. The 3 failures (
stride_tests::a_heap_buffer_read_by_element_takes_the_views_stride,stride_tests::a_heap_buffer_read_where_no_buffer_view_is_reads_zeros,synthetic_tests::gathers_at_a_level_match_the_hardware) fail the same way on plain main on this card (#2317). Nothing new from this PR.So in addition to the RTX 3070 Ti (Ampere) in the description, the halves path checks out on Ada.
AI-assisted (Claude).
Imported from Marvisak/VIctory. Originally posted by chippy01 on 2026-11-25T20:59:39Z.
Pushed a second commit with two fixes. Both were wrong results in the upper host wave (console lanes 32-63), and both now have tests:
First-lane reads. Thanks @justrealyme for the report and the fix in chippy01/VIctory#1; it's folded into this commit with you as co-author.
v_readfirstlane_b32read the host wave's first lane, which for the upper half is console lane 32. Reproduced here on the RTX 3070 Ti and the Radeon iGPU: the first lane of the thread id gave 32 in lanes 32-63, where the console gives 0. The Radeon's own wave64 form gave 0. A first-lane read is now kept only for values proven the same in every lane of the console wave. The analysis gains two cases:Every other first-lane read is refused with its reason. Offline over the title, compute programs emitted go from 2,372 to 2,369. The 3 dropped read values that can really differ between halves: the cloud multiple-scattering cache, for example, reads a value joined from a branch on a per-lane compare.
DPP row masks. The row came from the host lane (0-1), so the upper half applied
row_maskbits 0-1 to console rows 2-3. Withrow_mask:0xc, lanes 32-63 kept their old value on both GPUs (32 of 64 lanes wrong); now 0 are. No program in this title uses such a mask in halves, so none of its translations change.New GPU tests:
dpp_row_masks_name_the_console_rows_on_every_gpuandfirst_lanes_kept_in_halves_match_the_console_on_every_gpu. The refusal cases are inreads_across_32_lane_halves_are_refused_with_their_reason.victory-shader --lib: 273 passed, with the same 3 NVIDIA failures asmain. Clippy (both runs) andcargo xtask policyare clean.The refused first-lane reads come back exactly once the two host waves can exchange values, which is the follow-up mentioned above.
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-25T21:16:58Z.
Thanks, @qtLkz, for running the five tests on the RTX 4070 Ti, and @chippy01 for the first-lane and DPP row-mask fixes. My RTX 4090 results above are from
360f8aa, before the follow-up. The 2,372 compute programs in that table are from that earlier revision.Imported from Marvisak/VIctory. Originally posted by Marvisak on 2026-11-25T22:16:15Z.
Automated triage for the maintainers.
Needs the maintainer's decision, plus one small fix. The rebase merges cleanly and CI
checkis passing. The approach is gated byemit::Options::host_wave32, which is set fromHost::wave32(D3D12_OPTIONS1, at most 32 lanes with 32 among them). It runs console wave64 compute programs as two 32-lane host waves. Reads across halves, LDS in one-wave groups, unproven first-lane reads, and tile-prone group shapes are refused with reasons inemit/lower/halves.rs. The shader cache key incrates/victory-gpu/src/shader_cache.rsnow includes the wave width. Several testers report the halves tests exact on NVIDIA Ampere/Ada/Blackwell and on RDNA2/RDNA3 (where they also match the native wave64 form).wave64_programs_in_halves_match_the_console_on_every_gpu(andevery_thread_keeps_its_own_id_in_halves_on_every_gpu) inemit/halves_tests.rsiterateHost::each_hardware(), which also lists 16-lane-only adapters. There both forms are refused and theassert!(*form == "wave64" && wave32, ...)fires, as reported in the thread on an Intel UHD iGPU. Please skip adapters where the halves form cannot be made, the same way the 64-lane form is skipped.On your reply: the third commit's refusal of group shapes a host wave may tile, and the merge of
main(using #573'sds_bpermute_b32within halves), read correctly.Generated by Claude Code
Imported from Marvisak/VIctory. Originally posted by davesousa on 2026-11-25T23:22:05Z.
First run in the world with this PR, on the same Ampere card as the description: RTX 3070 Ti 8 GB, driver 621.40, Windows 11 26200, 32 GB RAM.
diagbuild,VICTORY_D3D12_DRED=1. The base is13f91ca+ #2319 + #1906 + #2178 (without those, this card does not get through the world on NVIDIA; #1906 is inmainnow). This PR atb15a57b; the only conflict there wasshader_cache.rsagainst #2178 (each adds a key parameter; I kept both). Cache and pipelines rebuilt for each build. These runs are of your two commits before your merge ofmain(f60027f); the conflict resolution in that merge is not covered here.Offline (
translate --cache --pipelines, same four inputs), on the base and then with this PR:In the title, two 15-minute runs from the start screen through the world and the intro cutscene, one per build. The script stopped both; neither had a device removal:
The 170 dropped here all give a reason. The ones I could classify: 76 for LDS one console wave64 shares without barriers, 18 for lane masks or lane reads across halves, 11 for reductions over both halves, 7 for first-lane reads of values that may differ between the halves.
emit::halves_testspasses 7/7 here: (halves) 0 lanes of 64 differ from the console, and the wave64 form is skipped as expected.victory-shader --libandvictory-gpu --libshow no new failures against the base.I did not compare images, so this says nothing yet about whether the 9 programs that run now draw correctly.
AI-assisted (Claude Code); the runs are on my machine.
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-25T23:23:37Z.
Thanks for running this in-game, @davesousa. The drop from 170 host refusals to zero on the 3070 Ti lines up with what I saw offline on the 4090. The median world frame time barely moved, even with fewer slow submissions.
Your numbers give us a baseline for
b15a57bon the stack you listed. A matched run onf60027fwith screenshots would show whether those results held after the merge and what the nine newly running programs actually draw.Imported from Marvisak/VIctory. Originally posted by chippy01 on 2026-11-25T23:45:30Z.
Merged
main(842b0cb) inf60027f.main's ownds_bpermute_b32lowering from #573 already reads within the reader's half, so it replaces the halves-onlypermute_lanes. TheHosttest helpers now sit onmain's shared WARP device. Nothing measured changes.Then pushed a third commit: halves now refuse group shapes that a 32-lane host wave may tile.
The relabelling gives a thread the first flat id of its host wave, rounded down to 32, plus its host lane. That is right only while every host wave holds a run of consecutive ids. I ran a program in halves that stores 1 at its own id, on the RTX 3070 Ti and the Radeon iGPU. 32x2, 32x8, 64x4, 32x32 and 32x2x2 groups store half their ids on both GPUs, because the host gives a wave a 16x2 tile of the group. 8x4, 4x4, 8x8, 16x2, 16x4, 8x16, 16x16, 4x4x4, 2x2x16, 8x8x4 and one-row groups store all of them. #2126 found the same tiling on an RTX 5070 Ti for
main's 32-lane programs.No program the title translates in halves uses such a group; they are 8x8, 8x4, 4x4 or one row, so 2,369 are still emitted. Its 32x2, 32x32 and 6x6 programs were refused already, and they would have run wrongly once the exchanges arrive. When #2126's per-wave tickets land, halves can take its ids from them and drop this refusal.
New tests:
groups_a_host_wave_may_tile_are_refused_in_halvesandevery_thread_keeps_its_own_id_in_halves_on_every_gpu.victory-shader --lib: 307 passed on the merged head, with the same 3 NVIDIA failures asmain.Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-25T23:53:23Z.
Thanks for testing those group shapes on both adapters, @chippy01. The store-at-own-ID test shows where the flat-ID assumption breaks: a 16×2 tile crosses rows, and the wider groups lose half their writes.
The unchanged count of 2,369 gives us a reference for
86a16dc. A matched run of that head andb15a57bcan check whether the picture and frame times still agree after the merge and the new guard.Imported from Marvisak/VIctory. Originally posted by steven-seagull27 on 2026-11-26T02:20:58Z.
I tested the single-half case on
86a16dc. A 32-thread group fits entirely inside one Wave32. The guest compares the thread ID, saves and narrows EXEC, runsv_readfirstlane_b32 s12, v0, restores EXEC, and writes the scalar from all 32 threads. There is no branch or second half. The four masks select lane 0, lane 7, lane 31, or no lanes (the lane-zero fallback).36eb5f6)Both Wave32 runs returned zero for the lane-7 and lane-31 masks before #2830. The two PR heads merge cleanly. Windows' built-in WARP advertises Wave4 only here and skipped both requested widths.
I also compiled a standalone HLSL shader with DXC to check the remaining WARP result. With
[WaveSize(64)], 32 threads per group, andtid = SV_GroupIndex, thread 7 reported an all-zeroWaveActiveBallot(tid >= 7). A directWaveReadLaneAt(100 + tid, 7)in the same shader returned 107. Changing only the group size to 64 produced ballot wordsffffff80 ffffffffand elected lane 7. A native Wave64 Radeon readback on the 32-thread fixture would help distinguish the WARP result.Test-only commit a5a1999. To run from the head of this PR:
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-26T02:24:34Z.
Thanks for the minimal repro, @steven-seagull27. The 32-thread fixture reproduces the lane 7 and 31 failures within a single half, and both Wave32 runs go from 64 wrong dwords to zero with #2830. I can use
a5a1999for the same comparison on my 4090.I'd still like to see a native Wave64 Radeon run of the 32-thread fixture, especially whether the ballot is zero when the direct lane read returns 107.
Imported from Marvisak/VIctory. Originally posted by steven-seagull27 on 2026-11-26T02:35:41Z.
@TaynanGT I put both comparisons on one branch at 34c8e1c. It contains this PR, #2830 and the guest fixture, plus a separate HLSL shader compiled by the Windows SDK's PC DXC. It prints the actual adapter, selected wave width, ballot words, elected read, and direct read from lane 7.
@zed6000 Thanks for the native Wave64 result on #1737. If your 7900 XTX is available for this one, could you post the Radeon lines for the 32-thread group and the 64-thread control? From an existing clone, the following creates a separate worktree:
In the standalone test on WARP 1.0.22, 25 of the 32 threads had their own predicate missing from the Wave64 ballot. Thread 7 read
100through the elected lane and107directly from lane 7. Increasing only the group size to 64 gave107both ways and 0/64 wrong. On the RTX 5080, Wave32 had zero wrong for both group sizes. The standalone test prints all adapter/width results before reporting any mismatches.Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-26T02:38:21Z.
Thanks for putting both fixtures on
34c8e1c, @steven-seagull27. I can use that head for the 4090 check and report the actual wave width with the ballot and both reads.I'd look for whether Radeon also gets
100from the elected lane and107from lane 7 with 32 threads, then107both ways with 64. That would show whether the WARP result also reproduces on native Wave64 hardware.Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-26T02:46:55Z.
@steven-seagull27 I ran both tests on
34c8e1c. The guest first-lane test matched all four masks on the RTX 4090 in Wave32 and on the Ryzen 9 9950X3D's integrated Radeon in Wave32 and native Wave64.For thread 7, the 4090's Wave32 ballot was
ffffff80 00000000with either group size. On the Radeon in Wave64, it wasffffff80 00000000with 32 threads andffffff80 ffffffffwith 64. In all of those runs, lane 7 was elected and both reads returned107.The built-in WARP adapter reported Wave4 and skipped Wave32 and Wave64.
Imported from Marvisak/VIctory. Originally posted by chippy01 on 2026-11-26T09:14:50Z.
@TaynanGT here is the matched comparison. Same card as davesousa's, an RTX 3070 Ti 8 GB, but on driver 621.24 (theirs was 621.40). Ryzen 9 7900X, 32 GB RAM, Windows 11 26200, TDR delay at the default 2 s.
diagbuilds,VICTORY_D3D12_DRED=1,--console series-x.b15a57bis on davesousa's stack (+ #2319 + #1906 + #2178).86a16dchas #2319 + #2178; #1906 comes with the merge.shader_cache.rskeeps both key parameters, as davesousa did. Cache and pipelines were rebuilt for each build.Offline,
translate --cache --pipelineson the same four inputs:b15a57b86a16dcb15a57breproduces davesousa's column exactly.translate --list --wave32on the same inputs, program by program:b15a57b86a16dcNo compute program changes outcome. The guard refuses two programs, both of which
b15a57balready refused for a lane mask read as data. The guard now stops them before that check. The other halves reasons have the same counts on both builds: 192 LDS, 48 lane reads across halves, 20 reductions, 17 first-lane reads. Four pixel programs change outcome:b15a57brefused them for a lane mask read as data, and they translate after the merge.In the title I couldn't get the 15-minute runs. Both builds stopped in the world, the same way:
b15a57b86a16dcOnce the world loaded, the emulator's working set reached 20-22 GB, VRAM sat at 7.0-7.2 of 8 GB, and about 1 GB of RAM was left. Frames took seconds each (up to 15 s). Then no frame came for about a minute, and the title's own crash handler ended it ("Game Running" in its report). Both builds did this, even with most apps closed, so I read it as a limit of this machine rather than of either commit. The page file and the game data are both on a nearly full QLC SSD. davesousa's runs got through 15 minutes with the same card and RAM. Frame times from these runs aren't meaningful.
In the part both runs covered, no program ran on one build and was dropped on the other. The 43 programs
86a16dcrefused in its run all give halves reasons; none of them is the new tile-prone-group refusal.The captures can't answer the picture question on NVIDIA yet. In both builds the world frames show only the cutscene's subtitles and letterboxing over a flat background. Both runs log the same host refusal of a 2560x1440 texture (#797), which looks like the scene target.
One more thing about
b15a57b's stack. Its first boot on a fresh library hung for 28 s shortly after a library save, and the title crashed itself in "Game Init".b15a57bdoesn't have #2179, so a pipeline load waits while a save serialises the whole ~1 GB library.86a16dcgets #2179 with the merge. The hang didn't happen on every first boot. To keep the two builds alike, each got one throwaway boot on its fresh library before its run.Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-26T09:21:05Z.
Thanks for running both builds, @chippy01. The 2,369 compute programs on each build answer my question about the guard. It rejects the same two programs earlier, and the merge gets four more pixel programs through translation.
The picture and frame-time comparison is still open. Both runs hit the same 2560×1440 texture refusal and ended before 15 minutes. Could you share the HRESULT and the format and flags for texture
#797if they're in the log? The 28-second fresh-library stall also fits the save/load contention that #2179 addresses.Imported from Marvisak/VIctory. Originally posted by chippy01 on 2026-11-26T09:48:27Z.
@TaynanGT it's in the logs. Both builds write the same pair of lines once per run, at the cutscene (
b15a57bat 08:40:10,86a16dcat 08:52:16):0x80070057(E_INVALIDARG; "Parametro non corretto" is the Italian system text). It comes back on both tries: first with castable formats, then as a plain texture.TEXTURE2D, 2560x1440, 1 mip, 1 slice, 1 sample.format: 115isDXGI_FORMAT_B4G4R4A4_UNORMandflags: 1isD3D12_RESOURCE_FLAG_ALLOW_RENDER_TARGET.VICTORY_D3D12_DEBUG=1if you want the debug layer's own reason.That's one of the two textures in #797. The other one (
format: 86,B5G5R5A1_UNORM,flags: 5) is created in both runs now.mainmakes it without unordered access; the log line just before the refusal isno unordered access for this format: textures are made without it, their unordered views are refused format=86. So on this card only the 115 texture is still refused.On the 28 s stall: agreed, that's the save/load contention #2179 removes. It's why each build got one throwaway boot before its measured run.
@steven-seagull27 thanks for the masked first-lane fixture. The wrong lanes come from
main's lowering, not from the halves. An instruction with a scalar destination drops its EXEC guard, so under a narrowed EXECv_readfirstlane_b32reads the host wave's lane 0 on any host. #2830 fixes that onmain, and with it the halves path matches (TaynanGT's run on the 4090 and the Radeon iGPU at34c8e1c). I'll leave that fix to #2830 rather than duplicate it here.Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-26T09:50:27Z.
Yes, please try
VICTORY_D3D12_DEBUG=1on86a16dc, @chippy01. A run to the cutscene is enough. Could you paste the debug-layer message ID and text for the plain creation of theB4G4R4A4_UNORMrender target?Thanks for checking both formats. Format 86 now creates without the UAV flag, and 115 still returns
E_INVALIDARGon the plain path. If you already have a format-support dump, could you include theD3D12_FORMAT_SUPPORT1_RENDER_TARGETbit for 115?Imported from Marvisak/VIctory. Originally posted by chippy01 on 2026-11-26T12:56:21Z.
@TaynanGT the debug layer can't get this title to the cutscene on this PC. With
VICTORY_D3D12_DEBUG=1,86a16dc(the same diag build and stack as the matched run) stopped in Game Init. The boot's descriptor work went several times slower than without the debug layer: a few thousand title-slot warnings per 10 s instead of 40,000-85,000. The title's own watchdog ended the run at 79 s. Its deliberate write at+0x2215c35left a crash report that saysGame State: Game Init,Frame: 0. Without the debug layer the emulator gets to that texture at 81 s.So I repeated the two calls
make_texturemakes for that texture outside the emulator, with the debug layer on. The arguments are the same: 2560x1440, 1 mip,B4G4R4A4_UNORM,ALLOW_RENDER_TARGET, default heap. The castable list is whatcastable(115)gives (formats 49-52, 54, 56-59, 68, 69, 85, 86).CreateCommittedResource3with those castable formats and a clear value in format 115E_INVALIDARG, ID 817CreateCommittedResource3with the same castable formats, no clear valueCreateCommittedResource(plain), with or without that clear valueE_INVALIDARG, ID 599ID 599 is
D3D12_MESSAGE_ID_CREATERESOURCE_INVALIDMISCFLAGS(severityERROR, categorySTATE_CREATION):ID 817 is
D3D12_MESSAGE_ID_CREATERESOURCE_INVALIDCLEARVALUEFORMAT:In the runs the castable try failed as well. Outside the emulator it only fails with a clear value in format 115, so the title most likely passes one. The emulator then falls back to the plain creation, which fails with 599.
Format support (
CheckFeatureSupport(D3D12_FEATURE_FORMAT_SUPPORT)):B4G4R4A4_UNORM,Support10x008413f0,RENDER_TARGETclear0x02e4d3f0,RENDER_TARGETsetB5G5R5A1_UNORM,Support10x00e4d3f0,RENDER_TARGETset0x02e4d3f0,RENDER_TARGETsetBoth adapters report
RelaxedFormatCastingSupported. So on this card 115 can never be a render target format, but the castable texture is accepted once the clear value in 115 is left out. I haven't tested whether its render target views work in one of the castable formats.Imported from Marvisak/VIctory. Originally posted by chippy01 on 2026-11-26T14:01:42Z.
@TaynanGT the debug layer can't get this title to the cutscene on this PC. With
VICTORY_D3D12_DEBUG=1,86a16dc(the same diag build and stack as the matched run) stopped in Game Init. The boot's descriptor work went several times slower than without the debug layer: a few thousand title-slot warnings per 10 s instead of 40,000-85,000. The title's own watchdog ended the run at 79 s. Its deliberate write at+0x2215c35left a crash report that saysGame State: Game Init,Frame: 0. Without the debug layer the emulator gets to that texture at 81 s.So I repeated the two calls
make_texturemakes for that texture outside the emulator, with the debug layer on. The arguments are the same: 2560x1440, 1 mip,B4G4R4A4_UNORM,ALLOW_RENDER_TARGET, default heap. The castable list is whatcastable(115)gives (formats 49-52, 54, 56-59, 68, 69, 85, 86).CreateCommittedResource3with those castable formats and a clear value in format 115E_INVALIDARG, ID 817CreateCommittedResource3with the same castable formats, no clear valueCreateCommittedResource(plain), with or without that clear valueE_INVALIDARG, ID 599ID 599 is
D3D12_MESSAGE_ID_CREATERESOURCE_INVALIDMISCFLAGS(severityERROR, categorySTATE_CREATION):ID 817 is
D3D12_MESSAGE_ID_CREATERESOURCE_INVALIDCLEARVALUEFORMAT:In the runs the castable try failed as well. Outside the emulator it only fails with a clear value in format 115, so the title most likely passes one. The emulator then falls back to the plain creation, which fails with 599.
Format support (
CheckFeatureSupport(D3D12_FEATURE_FORMAT_SUPPORT)):B4G4R4A4_UNORM,Support10x008413f0,RENDER_TARGETclear0x02e4d3f0,RENDER_TARGETsetB5G5R5A1_UNORM,Support10x00e4d3f0,RENDER_TARGETset0x02e4d3f0,RENDER_TARGETsetBoth adapters report
RelaxedFormatCastingSupported. So on this card 115 can never be a render target format, but the castable texture is accepted once the clear value in 115 is left out. I haven't tested whether its render target views work in one of the castable formats.Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-26T20:03:52Z.
Thanks for isolating both calls, @chippy01. I reproduced the format 115 result on an RTX 4090 (621.40) with a standalone D3D12 test using the same 2560×1440 texture, render-target flag and castable list. With GPU-based validation enabled,
CreateCommittedResource3returnedE_INVALIDARG(817) with aB4G4R4A4_UNORMoptimized clear and succeeded without it. The 4090 reportedSupport1=0x008413f0, withRENDER_TARGETclear.I also created a
B5G5R5A1_UNORMrender-target view of the successful allocation and submitted aClearRenderTargetView. The GPU completed it and the debug layer reported zero errors. The Ryzen 9 9950X3D’s Radeon iGPU (32.0.21045.29003) accepted both creation calls and the same view and clear.That gives us a test for a separate texture fix. The title’s actual view format and the cutscene still need an in-game check.
Imported from Marvisak/VIctory. Originally posted by Lyrnc on 2026-11-27T00:46:09Z.
Wave64 hardware check of
c5ab088(merged with main63bcca4, a README-only merge) on a 32-lane host (RTX 5080).Setup. Windows 11, an RTX 5080 (32..32) and the Radeon iGPU of a Ryzen 7 9800X3D (gfx1036, RDNA 2, 32..64) in one machine. 231 hand-written GFX10 wave64 compute programs, our own code (no game files):
In most cases a value set inside the branch, a scalar or a lane result, is also read by every lane after the join, as compiled code does with a reduction's result.
Expected values: the same code run natively in wave64 on the gfx1036. An independent Python model agrees with the hardware on every case. Each program goes through
emit_with(.., Options { host_wave32: true, .. }),dxil.dllvalidation and a D3D12 dispatch, comparing every output of every lane. For reference, the last column is main run withWaveSize(64)natively on the Radeon. That is the per-lane form on a host that runs the console's wave size, andhost_wave32: falseon this branch gives exactly the same results.Results (exact / differ / refused):
v_readfirstlanein a branchv_readlanein a branchv_writelanein a branchv_cmpx)s_cbranch_vccz) alones_cbranch_scc0)What it means.
The halves themselves hold up. No pipeline is refused by the driver (main: every one of its 206 refusals is the driver refusing
WaveSize(64)), 29 programs are refused by the translator with a reason, and LDS one wave shares is exact (30 of 30: min/max, write and read in one branch, the allocation idiom). Lane reads of a lane outside the branch also come back right where main in native wave64 reads 0: mask lanes 32-63,v_readlaneof lane 0, lane 32 gets 0x5 here and 0x0 on main.The differences are the per-lane form's, not the halves'. 131 of the 133 cases that differ on the 5080 also differ on main in native wave64 on the Radeon. The other 2 are f32 sums that differ by 1 ulp on NVIDIA only; the same translation is exact for them on the Radeon. No case is exact here and wrong on main natively. By kind:
v_mov_b32 v11, s38after the join: lane 0 gets 0x5555, the hardware gives 0x1270 (the reduction, since the wave ran the branch). On the console a scalar belongs to the wave. Here the join's phi picks the value per lane by the edge the lane came by, for SGPR phis too (wide.rsmodule note: "Scalar code runs in every lane ... which keeps each lane's values";wide_phi,wide.rs:300-325). Outside wave-wide regions the per-lane form does the same, which is the subject of #269.v_writelaneto a lane outside the branch is dropped (8): mask lanes 0-31,v_writelanelane 33, read back withv_readlanegives 0x1234 where the hardware gives 0x777. The select is written inside the per-lane branch (lower.rs:6737-6751). The console'sv_writelaneignores EXEC; #320 handles this in the console flow.halves::lane_uniformcannot prove the same as needing the console's lanes would bring these programs into halves, but they would then hit item 1 for the value read after the join.s_cbranch_vcczby the lane's own bit), as on main.a wave reduction over both 32-lane halves where not every thread of the group meets, for every reduction inside a loop with a lane-dependent exit (vote loop, break loop, loops lanes leave). This is the case the description lists as remaining.waveActiveOporder inside a 32-lane wave.For comparison, the console-flow stack (#320 + #439, with #2214 for 128-thread groups) gives 139 of the 151 one-wave cases and 56 of the 65 two-wave cases exact on the same 5080, because there every lane runs every block and scalars are the wave's.
Not tested: the title;
halves_random_tests(not run here).AI use: Claude Code (Claude Opus 5.5) wrote the cases, the harness and this report, and ran them on the GPUs named here; the numbers come from those runs.
Float wave sums on the same branch
Setup. Hand-written console wave64 compute programs, one 64-thread group each, translated with
Options { host_wave32: true }, validated by dxil.dll and run through D3D12 on an RTX 5080 and on the Radeon iGPU (gfx1036). The reference is the same instructions run natively in wave64 on that gfx1036. The cases are 34 whole-wave f32 sums and 20 f64 sums in the compiler'sWaveActiveSumshape: DPP8[1,0,3,2,5,4,7,6]/[2,2,0,0,6,6,4,4]/[4,4,4,4,0,0,0,0],row_mirror bound_ctrl:1,v_permlanex16_b32 0, 0,v_readlane_b3232 and 0. They sit inside per-lane branches: v10 = the sum in the branch, v12 = the same scalar after the join, preset to 0x5555.a whole-wave section step the simulation does not follow.WaveActiveSumon NVIDIA). Example, every lane, +-2^24 terms: hardware 86.0 (0x42ac0000), 5080 86.1632 (0x42ac5390).f32/hash/hi32, v12 lane 0: hardware 0x44b88648 (the sum the lanes 32..63 made), translator 0x5555. In every one of these the sum inside the branch is right.Meaning. The halves form takes the sum, but adds within each host wave in the driver's order. A tree of partner-lane reads from bit 0 (lane ^ 1, 2, 4, 8, 16) before joining the halves makes these sums exact (measured in the fork's version: 59 of 59 on the 5080). Separately, a scalar the branch writes does not reach lanes that skipped the branch.
AI use: Claude Code (Claude Opus 5.5) wrote the cases and the harness and ran them on this PC. The numbers come from those runs.
Imported from Marvisak/VIctory. Originally posted by pickles976 on 2026-11-27T01:12:41Z.
Post-prologue Wine/NVIDIA refusal census — a new local verification target, not a #2633 regression claim
The copy-only scoped-XMem/paging integration has finally passed this16 GiB host's previous loading-RAM stop. A guarded180 s trial reached “VICE CITY, TWO YEARS AGO” at120 s, then black at175 s; minimum availableRAM3669.3 MiB, GPU peak4557 MiB. No controllable3D gameplay. Memory/provenance report: https://github.com/Marvisak/VIctory/pull/2519#issuecomment-7205904648.
The translator in that dirty mixed stack is #189
3e39e34037915da6d0f10b58b2872799bd9f3ca8, on base3ed7d725f6895fe1a235eb6fa8ff2485261ca151, preserving its automatic preferredEmulatemode and refusal paths. It is not #2633. The first formerly refused compute pipelines now create, but the later stage exposes43 new translation refusals:02384a60fda6f2d0339d476c267c03c7bfad8c6743ac5977c4183d3cbee28e8eThe LDS wording means this analysis could not establish a safe fence; it does not by itself characterize every actual control-flow path. First two examples report offsets0x288 and0x204 respectively. The same run has refused texture formats67/115/86, so the black frame's sole cause is not isolated. Zero ERROR-level or literal
no host pipeline:lines must not be reported as shader success: these translation refusals are WARN-level.Hardware: RTX4060 Laptop8 GiB, NVIDIA590.48.1, Wine11, Linux6.17,15693 MiB RAM. vkd3d-proton is the disclosed diagnostic-relaxed
2576c0b4adfae4a+, not stock certification; NVIDIA masking disabled. Requested mode1920x1080 still produced a3840x2160 swapchain, so no1080p performance claim. No guard raised, forced Wave32, skipped-refusal workaround or new unchanged title retry.This makes the divergent scalar/EXEC behavior covered in https://github.com/Marvisak/VIctory/pull/2633#issuecomment-7206737113 a concrete next gate for this machine, not just pipeline-creation coverage. Suggested owner acceptance cases: branch-produced SGPR results consumed after the join; ballot low/high words used as data; lane reads/writes across active/inactive halves; and LDS read→write/write→read ordering with equal barrier reachability. Preserve refusal where those properties cannot be established. A lowered/validated pipeline alone is insufficient; compare all lane outputs against a native-Wave64 or independently justified semantic oracle.
Local evidence:
.compat-runtime/logs/20261127T004545Z-console.log,20261127T004545Z-resources.csvandscoped-paged-trial-20261127T004545Z/. Only hashes/diagnostics are shared; title bytes and captures stay local. I have not run #2633's current head or claimed that it fixes these43 shaders.Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T01:27:43Z.
Thanks, @Lyrnc, for checking the lane outputs against native Wave64. The fact that 131 of the 133 differences on the 5080 also show up on native Wave64 in
mainhelps narrow this down. The case where a scalar is set inside a branch and read by lanes that skipped it looks especially useful as a regression test. Is that fixture or harness available to run on the 4090 and the Radeon iGPU here? My earlier 4090 results in this thread were from an older revision.@pickles976, thanks for including the exact stack and the warning counts. The 43 refusals came from #189 on the Wine/4060 Laptop run, so they give us cases to compare once the same shaders are run on #2633. The texture warnings also leave the cause of the black screen open. I agree that pipeline creation alone can't establish correctness here. I'd want to compare the ballot words, lane reads and writes, and LDS ordering against native Wave64 or a reference with known outputs.
Imported from Marvisak/VIctory. Originally posted by Lyrnc on 2026-11-27T04:31:27Z.
@TaynanGT yes, here it is: https://gist.github.com/Lyrnc/00c6589f26930d5d07c077f8c4a30131
fw64_cases.py: the 151 cases. The scalar-set-in-a-branch case isfirstlane_branch/*.oracle_fw64.json: the gfx1036 wave64 results per lane.fw64_ref.py: an independent model, which agrees on 151/151.fw64_local_tests.rs: the local Rust test, written against fxceless/victory-fork 52ac4ec. It needs small path and API changes for this branch.fw64_compare.py: the comparer.The README in the gist has the steps. Everything in it is hand-written, with no game data. On the Radeon iGPU, the f32 sums came out exact and the integer cases matched the 5080 counts. I'd be glad to see the 4090 numbers.
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T04:35:22Z.
Thanks for posting the cases and the per-lane Radeon results, @Lyrnc. I’ll start with
firstlane_branch/*onc5ab088and compare the RTX 4090 Wave32 output against the same oracle.Could you share the generated
fw64_data.rsfor this gist revision? The generator calls your localhw_oracle.assemble, and the generated file would let me use the exact same instruction words.Imported from Marvisak/VIctory. Originally posted by Lyrnc on 2026-11-27T04:38:02Z.
@TaynanGT added:
fw64_data.rsis now in the gist, generated from the samefw64_cases.pyrevision, with the exact instruction words that ran on the gfx1036.Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T04:42:22Z.
Thanks for adding the generated file, @Lyrnc. I found all ten
firstlane_branch/*cases in the updated gist. I’ll use those exact words for the first RTX 4090 comparison onc5ab088, with the gfx1036 lane outputs as the reference.Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T04:48:04Z.
@Lyrnc I ran all ten
firstlane_branch/*cases from your generated file onc5ab088, using native D3D12 on the RTX 4090 (621.40) withhost_wave32=true. All ten passed DXIL validation and dispatched. Nine differed from the gfx1036 reference, for 508 differing dwords out of 10,240. The second run produced byte-for-byte identical output.alllo32,hi32altlane0,lane40,lane63l31_32sparsenoneFor
all,v10at lane 32 was0x65on the 4090 and0x05on gfx1036. Forlo32,v11at lane 32 kept0x5555on the 4090 where gfx1036 returned0x05. The baseline comparison is still open.Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T04:58:12Z.
@Lyrnc I ran the same ten cases on the Radeon iGPU (driver
32.0.21045.29003) at both63bcca4andc5ab088. With the default wave size, both Radeon runs produced the same 10,240 outputs as the RTX 4090 run.I then added a
WaveSize(64)requirement in the isolated Radeon test on each revision and verified it in the emitted metadata. Both revisions still produced identical outputs. Compared with the gfx1036 reference, eight cases differed, with 406 differences, all inv11after EXEC is restored.v10matched across all ten masks, and bothallandnonematched in full.For
lo32, lane 32’sv11stayed at0x5555on both translated revisions and read0x05on gfx1036. That post-branch discrepancy already reproduces on the base63bcca4.Imported from Marvisak/VIctory. Originally posted by pickles976 on 2026-11-27T11:05:29Z.
Linux/Wine RTX 4060 Laptop verification of exact production head
706c006ca9a9ee525b64114831e1dd418b198ba4(2026-11-27).Hardware/stack: RTX4060Laptop8GiB,16GiB systemRAM,NVIDIA590.48.1,Wine11.0; diagnostic vkd3d2576c0b4adfae4a+ with the previously disclosed relaxed-vtable build, not stock-stack certification. NVIDIA vendor masking disabled. One experiment at a time; unchanged6000MiB globalGPU/2048MiB availableRAM/10GiB user-disk guards and9GiB/512MiB scope.
victory-shader --lib emit::halves_tests -- --nocapture --test-threads=1: 24 passed,0failed,0ignored,29.02s after fresh7.35s compilation from this checkout. Test-only changes replace both absent-hardware skips with assertions and require a complete output buffer before the per-lane comparison; production unchanged.53 logged NVIDIA halves readback legs report zero mismatches, including multi-console-wave divergent loops, early ends, first-lane-after-loop and LDS ordering. NativeWave64 controls correctly refuse on this32-lane GPU; this is not nativeWave64/WARP coverage.Same original
XboxBvhBuilder.dll,translate ... --pipelines --validate --list --jobs 1: 52/52 native compute pipelines created,52/52 validated,50.51s guarded command including fresh45.96s release compilation. Host automatically detected32-lane maximum; SDKdxil.dll validator loaded. All seven containers refused by our previous#439 mixed stack now pass: two64-thread address/LDS programs at0x25c40/0x28770, and five256/512-thread programs at0x93220/0x95220/0x99160/0x9a830/0x9be80. Their native hashes respectively28918b7150a7aad5,caa78b8ca62bc3d6,14394a322f6dd5c2,e63d22c4def9ba6a,9fc111d3be79364f,77360df21e12ea43,39321a95223001ed.This is a useful exact compiler/admission-gate advance, not actual BVH execution or a rendered-title claim. Our prior mixed runtime holds the entire builder at53pipelines/46made/7refused; we keep that all-or-none guard. The two64-thread native programs contain repeated LDS writes/cross-half lane reads without native barriers; a compact computed-address + divergent-LDS + post-reconvergence scalar readback against an independent nativeWave64 oracle remains valuable. No original program/assets/captures uploaded.
Local reproducibility logs:
.compat-runtime/logs/verify-pr2633-halves-20261127T105728Z/andverify-pr2633-builder-20261127T105909Z/(command,exactref/dirty disclosure,console,timing,resource samples). This is not a matched-parent performance comparison or certification of untested shaders.Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T11:16:45Z.
@pickles976 The 24 readback tests and the 52 accepted compute pipelines on
706c006give us a clear result for that diagnostic Wine stack. Keep the builder’s all-or-none guard for the runtime check. Pipeline creation and lane readback are useful evidence for that step, while the title still needs its own matched run with the builder active.Imported from Marvisak/VIctory. Originally posted by pickles976 on 2026-11-27T11:17:00Z.
Important additional gate: the independent published native-gfx1036 firstlane_branch oracle still finds wrong results at exact706c006. Ten no-loop programs, actual NVIDIA32-lane dispatch, mandatory DXIL validation, complete1024-word readbacks per case. Nine cases differ,total508/10240words; none-mask passes. For all-mask, high-half v10/v11 gets101 rather than5; for lo32 the inactive high half retains s38=0x5555 after reconvergence instead of5. These are separate from the passing24owner tests and52nativePSO admissions. Same oldc5ab088 symptom, not established706 regression. Initial local harness compile/layout mistakes were corrected before this verdict; raw outputs independently re-compared using documented register-major index(64*register+lane). Prior#439+Wine single-latch control is running. Runtime promotion of the integrated backend is held pending this check; do not equate PSO creation with Wave64 correctness. Public fixture https://gist.github.com/Lyrnc/00c6589f26930d5d07c077f8c4a30131 ; valid evidence verify-pr2633-native-oracle-layout-20261127T111306Z/.
Matched control now completed: prior#439
e2d3cfd507plus its previously installed Wine single-latch normalization produces byte-for-byte identical10240 outputwords, including the same508mismatches. No difference in these10programs attributable to#2633. This is not a clean immediate-parent comparison. Control.compat-runtime/logs/verify-pr439-native-oracle-20261127T111546Z/,6.31s freshcompile/0.96stest; head6.40s/1.01s. Suggest checking whether firstlane-only programs select the cross-half path at all, in addition to post-join scalar state. No title-causality claim.Routing isolation (local probe, now restored): adding only
v_readfirstlane_b32toLower::new'sconsole_lanesinstruction predicate reduces mismatches 508→406, without changing any program words, expected outputs or guards. The full/all mask now agrees completely; in-branch v10 readbacks all match. All406 remaining differences are in v11 after reconvergence: lanes inactive in the branch keep old scalar0x5555 instead of the scalar assigned by the executing console wave. This separates (1) omitted firstlane-only wave admission from (2) post-join scalar preservation; the one-line change is not a complete fix and was not title-trialled or retained in production. Logverify-pr2633-firstlane-routing-probe-20261127T111827Z/; fresh6.42scompile/1.08stest. Please retain both in-branch and post-join outputs in the regression, including disjoint low/high masks and one active lane. No new PR or game data uploaded.Imported from Marvisak/VIctory. Originally posted by chippy01 on 2026-11-27T11:29:35Z.
Does anyone have CPU usage metrics for a running version of the port?
If specific instructions translate poorly to Wave32, I'm considering testing a fallback path to the RDNA iGPU on Ryzen CPUs. However, I'm worried the added synchronization and transfer overhead will outweigh any minor quality gains.
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T11:30:19Z.
@pickles976 The 406 post-join differences match the WaveSize(64) Radeon control I posted above:
v10agrees andv11keeps the old scalar in the previously inactive lanes. That gives us a separate scalar merge to test after adding first-lane routing. The byte-identical #439 comparison puts the same defect in that control. Keep the all-or-none builder guard and hold runtime promotion. The regression should check both outputs for disjoint halves, one active lane, and the all/none controls before a title run.Imported from Marvisak/VIctory. Originally posted by pickles976 on 2026-11-27T11:31:01Z.
Matched consumer regression isolated outside the mixed integration (Linux/Wine11, physical RTX4060 Laptop8GiB, NVIDIA590.48.1, 16GiB RAM, diagnostic relaxed-vkd3d2576c0b4adfae4a+; not stock-Windows certification):
I replayed the unchanged instruction words from #439's
emit/lane_read_loop_tests.rson exact #2633 production706c006ca9a9ee525b64114831e1dd418b198ba4and the previously verified #439e2d3cfd50715954fb89ff462edb37a0c4395ecd0+ our disclosed Wine single-latch normalization. Only test-harness API adaptation, mandatory DXIL validation, NVIDIA vendor/32-lane assertions and complete readbacks differ. This is not an immediate-parent regression comparison.Lane t runs t iterations; each iteration reads the named lane's unchanged thread ID into scalar s9; after restoring EXEC it stores t+s9. Expected outputs are20..51 or40..103. In #2633's wave32 case, lane0 returns0 instead20 and lanes21..31 return21..31 instead41..51. Both wave64 cases return0 instead40 only for lane0. All three translated, validated and created native PSOs; failures are actual returned GPU data. The control matched all160words. This is distinct from the shared firstlane_branch defect reported above.
Suggested owner gate: retain the existing #439 lane-loop consumer fixtures when replacing the backend, including native-wave32 and a lane that never enters the loop. Check inactive source-lane reads and wave-scalar updates across loop exit/reconvergence; do not fix this by weakening expected outputs or forcing Wave32 for Wave64 programs. These fixtures use no game assets.
Logs:
.compat-runtime/logs/verify-pr439-lane-loop-control-20261127T112940Z/(fresh6.30scompile,0.79stest) andverify-pr2633-lane-loop-owner-20261127T112948Z/(fresh6.48scompile,0.77stest). Strict local fixturelab_lane_loop_consumer_readbacks; one thread, same resource guards. Our mixed integration also fails these consumers; no title launch on this port. The earlier24owner tests and52builder PSO admissions remain valid but are not sufficient runtime clearance. No claim that this proves the cause of the title's black HDR frame.Source pointer for the wave64 lane0 result:
emit/lower/wide.rs:597-622explicitly seedswide_keepwith zero and selectson ? x : heldper lane; its comment assumes a lane that never ran the block reads none of that value.wide_keep_blockat650-688 applies this to non-VGPR definitions, including scalars. The fixture's restored-EXEC post-loop s9 read is a concrete counterexample to that assumption. A fix needs to distinguish logical-wave scalar state from lane-local VGPR/EXEC bookkeeping, and preserve independent logical waves that have finished; blindly removing all retention would not be safe. Native-wave32's inactive-source case is an additional control-flow gate, not demonstrated fixed by a halves-only scalar change.Follow-up: retention alone is not a sufficient fix. A bounded local production probe changed only numeric SGPR retention inside widened loops to use a logical-wave predicate: host ballot of the block's active lanes, trade with that console wave's paired half (not a whole-group vote), retain the old scalar only when neither half participates. VGPR/mask retention and phi selection were unchanged. All three programs still validated, created PSOs and executed, with exactly the same14 wrong words (12/32,1/64,1/64); fresh6.51s compile,0.81s test. Evidence
verify-pr2633-scalar-wave-probe-20261127T114600Z/. Both production files were restored exactly afterward; no title run.Therefore the
wide_keepobservation above is not proof of the sole cause, and changing it alone is not a working patch.fill_phisalso sends numeric SGPR joins throughwide_phi/wide_pick's per-lane edge selection. The required fix must account for original scalar control flow at joins as well as retention; naively applyingany()to every incoming edge is not sufficient (the complement/skip edge is a wave-wide decision too). This refinement leaves the matched GPU failure and runtime hold unchanged.Update (2026-11-27): an owned fix for the divergent-scalar-join class now exists and passes the physical-GPU gates. r4tedx/VIctory#14 head
d21eb16(basec734600, the #439 lineage rather than this port) fixes the shared 508-word firstlane oracle mismatch by routingdivergent_scalar_joinsprograms through console flow with a per-lane fallback, instead of retaining per-lane scalar state. Matched A/B on the same RTX 4060 Laptop host: base 508/10,240 words wrong (9/10 cases) → head 10/10 cases exact, lane-loop consumers 0/160 on both. This PR's ownwide_keeplane-loop regression (14/160 vs 0/160 on the #439 control) is a separate defect of the paired-halves port and remains open. If patchingwide_keepretention proves difficult, adopting the same console-flow routing for divergent scalar joins is a working alternative with hardware evidence: https://github.com/r4tedx/VIctory/pull/14#issuecomment-7219801493Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T11:42:29Z.
@pickles976 The 12/32 native-Wave32 differences and the Wave64 lane-zero cases need their own gate alongside the first-lane fixture. The lane that skips the loop still needs the scalar value from its logical wave when EXEC is restored. Keep the consumer fixture and the all-or-none guard through the immediate-parent check.
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T11:42:32Z.
@chippy01 I found a process CPU measurement in our Series S baseline. The 9950X3D and RTX 4090 run on
bc090416used 624 process CPU-seconds per minute, or 10.4 logical CPUs on average across the process threads. That covers the session, including loading. For the iGPU test I’d still start with one self-contained compute pass and measure the copies, queue waits and shader time against that same pass on the discrete GPU.Imported from Marvisak/VIctory. Originally posted by carlosmegino on 2026-11-27T13:29:01Z.
@chippy01 @TaynanGT @pickles976 — continuing our existing NEW-354 claim, I am making the exact paired control a9ef792f6d516ee6200f4fedeb061a25153d48fd publicly fetchable in response to https://github.com/Marvisak/VIctory/pull/3180#issuecomment-7217327296. It will be distinguished from PiloteCode 140958f and the later partial-paired b3060be, with original attribution and reproducible synthetic fixtures.
My complementary scope is provenance and matched synthetic diagnosis, not a parallel scalar-flow fix. I have read the current
706c006head and your reports: 508 firstlane_branch mismatches separate into routing and 406 shared post-join scalar differences; the lane-loop consumers give 14/160 wrong words, including native Wave32 and the lane that never enters. The unsuccessful retention-only probe is not a fix or proof of a sole cause. I will preserve both in-branch and post-join outputs, exact guest words and each backend's identity when comparing the archived paired control. Please flag any existing owner work or regression revisions so our report can feed that work without duplicating it. No title run or runtime clearance is inferred.AI-assisted with OpenAI Codex; synthetic inputs only.
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T13:37:28Z.
@carlosmegino Please link the exact archived paired control once it’s fetchable. Preserve the in-branch and post-join outputs and identify the native-Wave32 consumer separately. On my side, #208 is reserved for the matched water comparison, so the synthetic scalar-flow diagnosis can stay with the upstream owners.
Imported from Marvisak/VIctory. Originally posted by ColorMeBoom on 2026-11-27T13:59:07Z.
@Lyrnc's 151 fw64 cases on a second AMD architecture: RX 5700 XT (RDNA1, gfx1010, 32–64 lanes), driver 32.0.21045.29003, Windows 11 26200, Rust 1.98.1. Your gist's
fw64_data.rsandoracle_fw64.jsonare unchanged. The harness isfw64_local_tests.rsadapted to upstream (ir::build+emit_with(.., Options), no other change), withdxil.dllvalidation and a native D3D12 dispatch, compared on all 16 outputs × 64 lanes. Three translations:main63bcca4, and this PR at706c006(merged ontomain) withhost_wave32: falseandtrue.main, native Wave64host_wave32: falsehost_wave32: true(halves)red_branchfirstlane_branchreadlane_branchlds_minmaxalloc_branchwritelane_branchred_nestedred_loopred_earlyoutlds_regionvote_loop_branchvote_loopbreak_loop(exact / differ / refused against the gfx1036 oracle)
mainandhost_wave32: falsegive byte-identical outputs in 151 of 151 cases. So a second AMD architecture finds the same 92 differences, which supports them being the translation's per-lane form and not one GPU's behaviour.706c006translate everything: 136 programs carry PSV0 lanes 32..32, so this card runs them at 32 lanes, and the other 15 have no wave size. The 16 programs yourc5ab088table had refused (red_loop3,vote_loop_branch6,break_loop7) now emit, validate and run.firstlane_branchin halves: 508 of 10,240 words wrong, the same count @pickles976 got on the RTX 4060 at this head; 457 of them are inv11. Native Wave64 here is also 508.readlane_branch×10: halves is closer to the oracle (e.g.0/hi32: 32 wrong words against 96 native,*/lane40: 63 against 65).break_loop×6: halves is worse, with a new error inv11.v11is the sum over rounds ofwhole_wave("add_nc_u32")over the lanes still in the loop. Native gets every lane right. In halves, each round's sum is the first round's, i.e. the lanes that already left (byv_cmpx+s_andn2_b64of the loop mask) are still counted.break_loop/all, lane 1 (two rounds): oracle0x2ef8, halves0x31c0(= 2 ×0x18e0, the first round's sum); lane 31:0x73e0against0xc700.v11is wrong in 56 lanes ofbreak_loop/all(168 wrong words in total, against 112 native), and in 32, 32, 32, 1 and 5 lanes oflo32/hi32/alt/lane40/sparse; native hasv11right in all of them.v12/v13differ the same way in both forms.The 15 f32 sums and the 65 128-thread programs aren't in the gist's
fw64_data.rs, so they aren't covered here. Outputs are register-major (64 * register + lane), as in your comparer.AI use: Claude Code (Claude Opus 5.5).
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T14:11:15Z.
@ColorMeBoom Your RX 5700 XT run reproduces the same 92 oracle differences in both native paths. The stale
v11loop sum is specific to halves and gives us a separate check for the next revision. The branch-only SCC vote in #3500 can be compared independently of the loop-mask change.Imported from Marvisak/VIctory. Originally posted by carlosmegino on 2026-11-27T14:29:21Z.
@chippy01 @TaynanGT @pickles976 — the requested exact archived paired control is now public: a9ef792f6d516ee6200f4fedeb061a25153d48fd, base
842b0cb76f8f5fa9289bd779783c51ec24d75302, branchcarlosmegino/VIctory:codex/repro-paired-a9ef792. Anonymous fetch from a new bare repository verified both this exact object and its base. The pinned test-only companion keeps all original compiler/host files intact and documents Linux/Wine commands, raw inputs, attribution and differences from 140958f/b3060be. No later backend is substituted.I ran only the scoped synthetic diagnostics on Windows/RTX 5070 Ti (621.01, lanes 32/32, Rust 1.98.1):
Thus the historical paired control is neither a universal passing consumer control nor equivalent to your head. I am not converting the refused program into a passing result. #439's attributed program/expected values are preserved.
For all ten of Lyrnc's exact firstlane_branch cases, mandatory DXIL validation, PSO creation and complete 1024-word readback succeeded, but the independent native-gfx1036 comparison gives 508/10,240 wrong, split as 51 v10 + 457 v11, with none-mask passing. This matches the existing NVIDIA and ColorMeBoom RDNA1 counts. Selection diagnostics show the first-lane sites have
st.guards[b][i] == Noneand no waterfall flag; the exact a9ef guarded-first-lane preference does not fire, and PSV0 retains 64 physical threads with no required wave size. This identifies a selection boundary; it does not prove a predicate change fixes scalar reconvergence.Native Wave32 cannot enter this port's Wave64-only paired path and still exposes its ordinary-flow scalar/inactive-source problem. The one passing paired Wave64 loop does not clear the post-join firstlane or joined-latch gates. Your previously disclosed retention-only probe remains unsuccessful; changing wide_keep alone is not established as a fix. Scalar phi/edge selection and wave-level scalar state need to be distinguished from per-lane VGPR/EXEC retention and independent waves that have finished.
I have read Chippy01's newer claim and TaynanGT's request. This remains matched evidence/reproducibility under our existing NEW-354 claim, not a parallel implementation. Current #2633 source checked here is still
706c006ca9a9ee525b64114831e1dd418b198ba4; I did not modify it, test a newer owner revision or launch the title.The companion contract also reproduces #3180's waited 64/128 seven-UAV passes on the exact backend, with intact canaries and no native D3D12/GBV warnings/errors. Those passes and the red consumer/oracle results are deliberately reported separately. Lyrnc's LOCAL files are fetched at pinned hashes, not republished; r4tedx/ifBars and PiloteCode retain their attributions.
AI-assisted with OpenAI Codex. Synthetic inputs only.
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T14:38:58Z.
@carlosmegino Thanks for pinning the exact
a9ef792control. The clean paired Wave64 latch, the refused joined-EXEC case and the 508 first-lane differences answer different questions. I’ll use the passing case as a control for that loop shape and keep the post-join first-lane result in the report.Imported from Marvisak/VIctory. Originally posted by carlosmegino on 2026-11-27T14:39:49Z.
@TaynanGT @chippy01 @pickles976 — follow-up to the exact-control/phase request. Access is independently reverified, and the two capture points are now preserved as separate per-lane data.
Exact control, not a replacement revision
codex/repro-paired-a9ef792, exact a9ef792f6d516ee6200f4fedeb061a25153d48fd.I fetched the original branch directly into a new empty bare object store, with system/global Git configuration disabled, no credential helper and no alternate object directories, before fetching any kit. Head and base matched exactly. That is an independent Git environment on this Windows host, not a claim of a second-machine GPU test. Separately, your exact-head Linux/Wine report already confirms access/build and fixture export; missing Graphics Tools/InfoQueue prevented original GPU execution, so that is not counted as a correctness failure or successful readback.
A clean independent fetch check is:
Outputs are separated by guest capture point. These reuse the previously completed Windows/RTX 5070 Ti/621.01 readbacks on exact a9ef792; no GPU tests were repeated for this data supplement. Lyrnc's native gfx1036 reference retains its attribution and pinned hash.
Both captured VGPRs are ultimately stored at shader end; v10 is an inside-branch snapshot, not a separate mid-dispatch readback. Inactive v10 lanes retain their initializer, whereas post-join v11 must be checked in every lane, including never-entered lanes. For
lo32, lane32's v10=0 agrees, but v11=0x5555 instead of 5. Forall, lane32's v10 and v11 are 101 instead of 5. The linked JSON preserves every actual/expected value and mismatch lane independently for both phases, with the raw TSV/executable/source hashes. The guarded paired preference is bypassed on these first-lane sites, as the earlier trace showed; this is not evidence for a one-line scalar fix.Native Wave32 is explicitly its own consumer: unchanged
program(32,20,false), expected 20..51, gives 12/32 wrong (lane0=0, lanes21..31=t rather than t+20). It never enters Wave64 paired lowering. The ordinary Wave64/lane40 consumer is 0/64 wrong with paired physical 32 / Wave32. The joined EXEC consumer refuses emission at 0x28; no PSO/readback is claimed. None of that is a 0/160 archive verdict.For Linux/Wine, use Rust 1.98.1, LLVM clang/lld, cargo-xwin, a working D3D12 SM6.6 prefix and your Windows x64 DXIL validator. The pinned kit guide includes the setup; the execution commands are:
The Windows evidence predicts a green 64/128 contract suite and a red consumer suite: lane-loop test exit 101, ten completed first-lane dispatches, oracle comparator exit 1 and overall consumer exit 1. These are expected observations to independently check under Wine, not promised cross-driver bit patterns. Wine mode explicitly omits Windows debug/GBV interfaces while keeping mandatory DXIL validation, complete readback and canaries; it does not certify the original GPU-runtime test.
I have also read the edited scalar-consumer report: the shared divergent-scalar-join class now has an owned fix, mohammadallami75-ops's r4tedx/VIctory#14, head
d21eb165c333de3f10d95558616b84d398df2d73, basec7346008de48f6c71e22cdff0d5f7b644fe798fb. Pickles976's external A/B reports 508→0 first-lane mismatches and 0/160 consumers on both that base/head. This belongs to that #439 lineage, not a9ef792, and is separate from #2633706c006's 14/160 consumer gate. I am feeding this evidence to the existing owners, not reimplementing or transplanting their fix.The matched water comparison in #208 remains reserved to @TaynanGT. No water/title shader, capture, branch, benchmark or experiment was touched. b3060be and 741aa8e remain separately identified later revisions; none of their results is included in this archive ledger.
AI-assisted with OpenAI Codex. Synthetic data only. PROGRESS.md and HANDOFF.md are updated; no duplicate claim or done entry.
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T14:49:15Z.
@carlosmegino The two snapshots make the result much clearer: 51 differences inside the branch and 457 after reconvergence. I’ll use those counts for the archived comparison. The native Wave32 failure, the passing ordinary paired Wave64 latch and the joined-EXEC refusal can each be checked against their own expected result.
Imported from Marvisak/VIctory. Originally posted by ColorMeBoom on 2026-11-27T15:02:16Z.
Same 151 fw64 cases at
b32cef7(RX 5700 XT, same harness as my report above, merged ontomain63bcca4):host_wave32: true): byte-for-byte the same outputs as at706c006, in 151 of 151 cases. So it's still 59 exact / 92 differ against the gfx1036 oracle, and still 508 of 10,240 wrong words infirstlane_branch. Thebreak_loopv11sum is still stale too: lane 1 ofbreak_loop/allreads0x31c0, not0x2ef8. The two new commits change neither.host_wave32: false: still identical tomainin 151 of 151.halves: 36 passed, 0 failed, none skipped. That includesrandom_wave64_programs_in_halves_match_one_wave64(64 of 64 compared against one wave64 on this card, none refused in halves) and the*_on_every_gpuhalves readbacks (0 lanes differ).AI use: Claude Code (Claude Opus 5.5).
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T15:08:57Z.
@ColorMeBoom The byte-for-byte comparison on the RX 5700 XT pins the result to
b32cef7. The 36 in-tree tests pass and the archived fixture still shows 508 first-lane differences and the stale loop sum. I’ll keep those two fixture results as acceptance checks for the scalar and mask changes.Imported from Marvisak/VIctory. Originally posted by ColorMeBoom on 2026-11-27T17:25:24Z.
A fix for the stale
break_loopv11sum in halves (reported above): one commit on top ofb32cef7,ColorMeBoom:pr2633-wide-sum(fce45f8, fast-forward).Cause. In a region run wave-wide, every thread runs the loop's block. Each vector write is guarded by the block's lanes (
wide_guard), and ballotswide_andtheir mask's bit with them. But the reductions whole-wave sections leave (Lower::shape:Active,Prefix,Masked,Half) took their lanes from the section's mask alone. Inbreak_loop/allthat bit folds totrue(select i1 true, %value, 0beforewaveActiveOp, while thev11accumulate right after it isselect %50, ...), so every lane that entered the loop counted in every round. A loop that lanes leave by EXEC (v_cmpx+s_andn2_b64of the loop mask +s_cbranch_scc0) therefore summed the first round's lanes each round. The fixwide_ands that bit with the current block's lanes in those four places. Outside wave-wide regionswide_andreturns its input unchanged, so nothing else moves. Thewide.rsmodule doc now lists "what whole-wave sections reduce" among the wave operations that see only the block's lanes.fw64, RX 5700 XT (same harness as above, 151 cases, against the gfx1036 oracle):
break_loop/…v11lanes wrong,b32cef7alllo32/hi32/altlane40/sparseThose six now give byte for byte what the per-lane form gives. The other 145 cases are unchanged, so it's still 59 exact / 92 differ overall, and
firstlane_branchis still 508 words, which is a separate issue. Halves total: 4,791 → 4,633 wrong words.host_wave32: falseis identical to before in 151 of 151.Regression test in
halves_tests.rs:a_whole_wave_sum_in_a_loop_lanes_leave_matches_the_console_on_every_gpu, plus its entry inthe_test_programs_are_what_their_comments_say. It's a loop where lanelgoes round(l & 3) + 1times, adding each round's whole-wave count of the lanes still in it, in thesum_kept_by_lanesidiom.Checks at
fce45f8: fullvictory-shader --lib --features host333 passed, 0 failed.halvesfilter withVICTORY_WARP=1: 37 passed.cargo clippy -p victory-shader --all-targets --features host -- -D warningsand the asset policy are clean, and the new lines are rustfmt-clean.AI use: Claude Code (Claude Opus 5.5).
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T17:29:26Z.
@ColorMeBoom The six
break_loopcases now agree with the per-lane result, and the 151 native wave64 results are unchanged. The negative control checks the block-mask correction at both 64 and 128 lanes. That lets this reduction fix stand on its own while thefirstlane_branchdiscrepancy is tracked.Imported from Marvisak/VIctory. Originally posted by pickles976 on 2026-11-27T17:45:02Z.
Verified ColorMeBoom's
pr2633-wide-sumcommitfce45f8ca36ae1821b36c97cf35ae86006797227(parentb32cef72554981f89fad00fecc8358699518da8a) on the physical RTX 4060 Laptop GPU under Linux 6.17 / Wine 11 / NVIDIA 590.48.1.cargo test -p victory-shader --features host --lib a_whole_wave_sum_ -- --nocapture --test-threads=1: 2 passed, 0 failed, 0 ignored, 2.33 s after fresh intended-worktree compilation (6.92 s). Production unchanged; local test-only strengthening requires the actual RTX 4060, SDK DXIL validation and complete readback dimensions instead of permitting an absent-adapter pass.Environment:
dxgi.hideNvidiaGpu = False; diagnostic relaxed-vtable vkd3d2576c0b4adfae4a+, not stock certification. Guarded 9 GiB memory / 512 MiB swap; sampled GPU peak147 MiB, available RAM minimum11187.8 MiB, disk minimum11.932 GiB. Evidence retained locally:.compat-runtime/logs/verify-pr2633-wide-sum-20261127T173746Z/.No matched parent run, full suite, native-RDNA oracle rerun, original BVH dispatch or title trial here. This verifies the reduction correction on another physical architecture; it does not clear the separate firstlane/scalar-merge discrepancy reported as unchanged in the author's 151-case comparison. Renderer promotion remains blocked on those consumer semantics, not merely native PSO creation.
AI-assisted local verification: OpenAI Codex GPT-6-Astra. No game assets or imagery attached.
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T17:47:45Z.
@pickles976 The executed readbacks cover both the 64- and 128-lane reduction cases on the RTX 4060 Laptop. That adds NVIDIA halves coverage to the RX 5700 XT result for
fce45f8. The native wave64 control and the remainingfirstlane_branchdifferences still have their own test results.Imported from Marvisak/VIctory. Originally posted by chippy01 on 2026-11-27T19:28:20Z.
@Lyrnc @pickles976 @ColorMeBoom @TaynanGT @carlosmegino thanks for the cases and the matched runs. Two new commits on this PR answer them (claimed in #1633, comment of 18:47 UTC):
break_loopv11. In a wave-wide loop every thread runs the block, including lanes that already left the loop, and the reduction counted those lanes. Now it counts the block's lanes only.wide_keepand the per-lane pick at the join, which pickles976 found that keeping the value alone doesn't fix.lane_uniformcan't prove alike now runs in halves. This is the routing pickles976 probed, with the same fallback.Lyrnc's 151 fw64 cases. I used the gist's
fw64_data.rsand oracle unchanged, with the harness adapted to this branch (local only, not committed). Results are exact / differ / refused against the gfx1036, identical on an RTX 3070 Ti and the Radeon iGPU of a Ryzen 9 7900X:b32cef7main's form, native wave64 (Radeon)v_readfirstlanein a branchv_readlanein a branchv_writelanein a branchs_cbranch_scc0)The 20 cases that still differ also differ in main's native wave64, in the same words, and halves is never wrong where native wave64 is right:
writelane_branch×8:v_writelane_b32to a lane outside EXEC. The write lands in the wave-wide block, but at the join the lane takes its own edge's VGPR. This is Lyrnc's item 2, and #320 handles it in the console flow.vote_loop×3 andvote_loop_branch×4:s_cbranch_vcczis decided per lane instructure(item 4).break_loop×5,v12: on the console the exit block runs with the last round's lanes only, but the per-lane form runs it in every lane that left.pickles976's lane-loop consumers, in our own encoding: lane t runs t rounds (lane 0 never enters), each round reads lane 40's thread id into a scalar and counts the rounds, and every lane stores both after the loop. There are two forms, an ordinary latch and the read in a branch whose EXEC is joined again before the backedge. In groups of 48, 64 and 128 every lane is now exact, lane 0 included. At
b32cef7lane 0 got 0 and each lane got its own round count. The native-wave32 consumer isn't in halves (a wave32 program already matches the console's wave on any host). Its scalars are main's per-lane form, which is #269's subject.New regression tests (both fail at
b32cef7):a_first_lane_read_in_a_branch_is_the_console_waves_after_the_join_in_halves_on_every_gpu: Lyrnc's masks (one half, the other, both, alternate, one lane in either half, lanes 31 and 32, none). It stores the value both inside the branch and after the join, in groups of 64 and 128.scalars_a_loop_leaves_are_the_console_waves_in_every_lane_in_halves_on_every_gpu: the consumers above.Title, offline
translate --list --wave32 --pipelineson the same four inputs: 2,723 of 2,723 compute pipelines made (2,721 atb32cef7; the 2 more come from the first commit), none lost. With the second commit, 87 programs run in halves for their first-lane reads (2 fall back to the old lowering), and 16 run a region wave-wide for a scalar a join reads.Not in these commits: the f32 sum order from Lyrnc's second report. Halves sum each 32-lane half with the host's
WaveActiveSum, so on NVIDIA an f32 sum can be 1 ulp off the console's DPP order. A section run step by step follows the console's order, so using that for f32 sums is the follow-up.@carlosmegino: the owner revisions are these two commits.
AI-assisted (Co-authored by Claude Opus 5.5) and measured on my own machine.
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T19:35:21Z.
@chippy01 I’ll use
b32cef7as the control and1b1ef21for the new Vice-Tay comparison. The 59 → 131 exact matches and 2,723/2,723 compute pipelines give us two offline checks before the matched water route. I’ll keep the 20 remaining mismatches and the f32 sum order separate in the results.Imported from Marvisak/VIctory. Originally posted by carlosmegino on 2026-11-27T19:41:14Z.
Thanks for confirming
27029afand1b1ef2161a2f1cbcb46d7f72a7b24baf1303d419as the official revisions, and for crediting the routing investigation.Our independent RTX 5070 Ti (native Windows, exclusively Wave32) check will use
b32cef7as the control and1b1ef216as the candidate. We will reuse the archived, unchanged Lyrncfirstlane_branchinputs and gfx1036 reference, separating the old 508 differences into v10 (inside the branch) and v11 (after reconvergence), plus the original #439 consumers and your new regressions. Translation, DXIL validation, PSO creation, completed execution and semantic readback will be reported separately. We will inspect retained-lowering fallbacks rather than counting pipeline admission as a semantic fix. Native Wave32 consumers, the remaining 20 cases and f32 summation order remain separate.In parallel, our experimental
42daca9analyzes and promotes a proven wave-private no-return LDS counter. Applied explicitly to Dathinel's intact original 96-thread synthetic fixture on the stable paired reference, it passed all 672 values and 56 guards; an indirect-address/different-EXEC variant passed another 672/56. Dynamic logical guest LDS accesses go from 658 to 388 (272 guest atomic additions replaced by two publication stores). This is not a measured GPU-traffic, timing or occupancy improvement, and the pass is not enabled in normal translation. We are checking compatibility/complementarity with the new halves/wave-wide implementation and preparing an attributed branch for independent technical review.We will not duplicate TaynanGT's announced water-path comparison, #269/#320, or your announced semantic fixes. AI-assisted with OpenAI Codex.
Imported from Marvisak/VIctory. Originally posted by pickles976 on 2026-11-27T19:43:56Z.
Verification of production head
1b1ef2161a2f1cbcb46d7f72a7b24baf1303d419on the physical RTX 4060 Laptop (32-lane host), Linux 6.17 / Wine 11 / NVIDIA 590.48.1. Diagnostic-relaxed-vtable vkd3d2576c0b4adfae4a+, not stock certification; NVIDIA masking disabled. Production unchanged; retained local test-only modules are byte-identical to the independent fixtures used in the earlier706c006report. SDK DXIL validation and the NVIDIA adapter are mandatory.706c006evidence1b1ef21, executed nowThis confirms the newly fixed halves/scalar consumers using our unchanged instruction streams, not only the new owner encodings. It is not a fresh immediate-parent A/B: the earlier results remain the archived
706c006runs. Current combined invocation is 1 test passed / 1 failed because the loop fixture deliberately retains its native-Wave32 control. That control still returns 0 for lane 0 and misses +20 for lanes 21–31; both Wave64 legs pass. This agrees with your explicit native-Wave32/#269 scope caveat, not a new regression from the two latest commits. Our older #439 + disclosed Wine single-latch control had all 160 words correct, so the native-Wave32 path remains a local runtime-integration concern.Also rebuilt this exact production head and ran the original local
XboxBvhBuilder.dllthroughtranslate --pipelines --validate --list --jobs 1: 52/52 translated, 52/52 required-SDK validations, 52/52 native NVIDIA PSOs created, with identical container-offset sets for validation and creation. This includes the original programs at offsets 0x25c40 and 0x28770. No original BVH program was dispatched, so this is admission/compilation, not tree integrity or title safety.Evidence under
.compat-runtime/logs/:verify-pr2633-revised-independent-oracles-20261127T193720Z/: fresh intended-tree build 6.95 s, tests 1.72 s; all complete raw consumer outputs retained.verify-pr2633-revised-builder-20261127T193907Z/: fresh release 46.89 s, guarded command 50.57 s.Peak sampled GPU <=222 MiB, available RAM >=10,900 MiB, disk >=12.058 GiB. Original 9 GiB/512 MiB scope and global guards unchanged. No title launch, forced approximation, partial builder, native-Wave64/WARP claim, full 151-case oracle run, or gameplay claim. Suggested next owner gate remains the native-Wave32 scalar/lane consumer plus the separately acknowledged remaining corpus classes; the two reported Wave64 loop errors and the 508-word firstlane mismatch are now cleared here.
AI-assisted verification; no source PR or assets published.
Native-Wave32 cause isolated; local correction passes (27Nov 20:13 UTC)
On production
1b1ef2161a2f1cbcb46d7f72a7b24baf1303d419plus a disclosed local two-function correction, the previously failing native-Wave32/readlane20 loop now returns every expected word. This is not an exact-head pass or a code PR.Causal path:
Lower::read_laneemitsdx.op.waveReadLaneAt.i32;valutreats its SGPR destination as unguarded by EXEC;fill_phisrecognizes the escaping SGPR as wave-scalar. Butwide::scalar_joinpreviously returned for all non-halves/one-host-wave programs. Native Wave32 kept historical per-lane scalar values across its divergent host loop instead of the console wave's one SGPR. Lane 0 never entered and kept zero; lanes 1–20 left while source lane 20 remained active; lanes 21–31 subsequently read an inactive source and produced zero. That explains the exact 12-lane failure pattern.Local correction, retaining the existing selective non-uniform/differing-scalar checks:
The native vote uses its own ballot word rather than halves exchange/LDS barriers. No fallback-admission change, forced Wave32 override, or safety-guard removal.
Physical RTX 4060 Laptop / Wine 11 / NVIDIA 590.48.1, mandatory SDK validator and NVIDIA 32-lane assertions, diagnostic-relaxed-vtable vkd3d
2576c0b4adfae4a+(not stock certification):scalars_a_loop_leaves_are_the_console_waves_in_every_lane_in_halves_on_every_gpu: 1/1 pass.Commands:
cargo test -p victory-shader --features host --lib emit::lab_ -- --nocapture --test-threads=1, then the named scalar-loop filter above. First passing invocation 2/2 tests, 1.54 s, fresh intended-worktree compilation 6.74 s; scalar-loop fixture 3.35 s on the same binary. Logs.compat-runtime/logs/verify-pr2633-native32-scalar-readbacks-20261127T201307Z/andverify-pr2633-native32-scalar-loop-regression-20261127T201402Z/. A preceding local test-only compile attempt referred to a nonexistentHostShader.barriersfield; it was removed before execution, not a shader failure. All consumer output assertions remain intact.This clears the reproduced native32 loop consumer, not all native32 shaders, original BVH execution, AMD/native64, or title rendering. The independent full-LDS fallback report in comment7227088196 remains a separate promotion blocker; this patch deliberately does not alter it. The original 52/52 BVH validation/PSO result above predates this local patch and is not relabeled as a new run. Suggested owner action: adopt/review this narrow native scalar-join route with both loop forms, and fix unsafe retained-lowering fallback separately before runtime promotion. AI-assisted investigation/local patch/verification: OpenAI GPT-6 Astra.
27 Nov: bounded writelane join correction, complete selected family verified
On the same
1b1ef2161a2f1cbcb46d7f72a7b24baf1303d419production plus the native32 correction above, a separate local correction now preserves an explicit lane write even when its target lane skips the branch. A guard-only correction failed the publishedwritelane_branch/0/hi32oracle (lane0 v100x1234instead of0x777); the later SSA join was discarding that write.The candidate routes only loop-free logical-Wave64/host-Wave32 writelane regions. It carries fixed-lane write provenance through nested phis and guarded ordinary VGPR writes, and folds affected join inputs in the region's CFG dependency order so a later ordinary write wins. It leaves the unaffected join fast path unchanged. Relevant local symbols:
route_lane_writes,wide_lane_write_guard,wide_lane_write,wide_keep_lane_write,wide_phi,wide_pick. This is a reviewable bounded approach, not a proposed blanket final overlay or general loop fix. The value-keyed provenance currently receives fresh instruction/select values; a future select constant-folding change must not intern these as shared constant keys. Multi-entry joins beyond the supplied cases remain a coverage limit.Required physical RTX4060 Laptop, 32-lane host and SDK validator, same Wine11/NVIDIA590.48.1/diagnostic-relaxed vkd3d conditions:
writelane_branchcases exact: 18,432 output words. Destinations0/33/63 × all/lo32/hi32/alternating/lane40/none masks.Public assembled inputs: https://gist.githubusercontent.com/Lyrnc/00c6589f26930d5d07c077f8c4a30131/raw/f4383c6d310fd40ed8c36c93d547f0f1f36a16be/fw64_data.rs . Independent gfx1036 expected outputs: https://gist.githubusercontent.com/Lyrnc/00c6589f26930d5d07c077f8c4a30131/raw/ce2f401463491742b10bb36d339c5d1e5103efbf/oracle_fw64.json , SHA256
eee0f705651c6083e3fbd8a0e3645ff55b66ed9222a68556b12a497477588715. Local selected data retains every input word and all nonzero native outputs; the remaining twelve words per lane were checked zero before compact extraction and are still asserted zero on GPU readback.cargo test -p victory-shader --lib lab_writelane_public_family_and_ordered_joins -- --nocapture --test-threads=1:1/1,20 GPU cases,1.19s, fresh6.88s intended-tree compilation. Evidenceverify-pr2633-writelane-family-20261127T213942Z/; scalar controlsverify-pr2633-writelane-scalar-controls-20261127T213353Z/(2/2,1.55s). No title run or gameplay claim. The other known break/vote-loop oracle families and unsafe retained-lowering fallback are not cleared by this selected-family result; no new full151-case verdict is claimed. Suggested owner action: retain all masks plus overwrite/nested consumers when reviewing the join correction, and resolve those separate promotion gates before title use.21:51 UTC — VCC-loop causality narrowed; SCC/EXEC loop is still separate
Same
1b1ef2161a2f1cbcb46d7f72a7b24baf1303d419plus the disclosed local native32/writelane corrections.structure::branchmodelss_cbranch_vccz/nzas a per-lane VCC/EXEC predicate;wide_exitwas using it to choose each lane's loop edge. These instructions instead branch on a whole-wave zero/nonzero value.A local causal probe, not a complete shipping fix, routes the enclosing VCC loop wave-wide, votes across the logical wave before choosing its edge, and forbids
unroutefor that forced route. All 11 publicvote_loop/vote_loop_branchcases now match all 11,264 native-gfx1036 oracle words on this physical RTX4060/Wine host. This includes low/high halves, alternate lanes, lane40 and the empty mask. Mandatory SDK validation and NVIDIA/32-lane assertions; no skips.Final combined controls: 4/4 fixtures, 2.91s after fresh intended-tree 6.72s compilation. The 11 vote cases, all 18 writelane cases plus two ordered/nested controls, all 10 firstlane cases, and native32/logical64 ordinary/joined readlane loops pass. Evidence:
.compat-runtime/logs/verify-pr2633-vote-loop-controls-20261127T215127Z/. Initial VCC-only proof:verify-pr2633-vote-loop-probe-20261127T214906Z/. This is selected-family coverage, not a new 151-case total.Do not extend that vote mechanically to SCC. A separate temporary extension to
s_cbranch_scc0/1still fails 5/7break_loopcases, 443/7168 output words; lane40 and empty-mask controls match. In the all-lanes case, lane0 accumulates v10=0x24 rather than 1 and incorrectly writes v12=8 rather than preserving 0xdead0000. Evidence:verify-pr2633-break-loop-probe-20261127T215038Z/. That SCC extension was removed before the passing controls. This points to the distinction between scalar control flow and the changing EXEC mask governing VGPR writes; making the branch uniform alone does not preserve it.Owner action: keep whole-wave VCC loop votes, but separately preserve actual EXEC-masked writes/loop phi state for SCC live-mask loops. Also test saved VCC bits outside current EXEC: the local probe still consumes the existing structured predicate and does not certify that broader numeric-mask case. The independently reported full-LDS
unroutefallback remains unsafe and is not fixed by this probe. No title launch or runtime-promotion claim.Break-loop cause narrowed: mask preservation fixes the oracle, but is not a promotable patch (27 Nov, 22:08 UTC)
Same
1b1ef216production base plus the disclosed local native32/writelane/VCC probes, same Wine 11 / RTX 4060 Laptop / NVIDIA 590.48.1 / diagnostic-relaxed vkd3d stack. Mandatory DXIL validator and physical NVIDIA readbacks; no title run.The CPU-only IR/structure census for public
break_loop/allshows loop EXEC phi values 86/87 reduced toBool::TRUEand every vector-write guard absent. The body temporarily expands EXEC withs_or_saveexec, restores it, then usess_andn2/SCC to retire lanes. A reach-relative mask truth is not an unconditional all-lanes truth once the region is emitted wave-wide.A causal-only variant that (a) forces mask phis to remain unresolved, (b) retains raw EXEC guards rather than reach-relative simplification, and (c) uses a whole-wave SCC branch vote returns all 7 public break-loop cases / 7,168 words exactly (previous scalar-vote-only probe: 443 wrong words). Fresh build 6.74 s, GPU fixture 0.96 s. Evidence:
verify-pr2633-break-loop-mask-phi-probe-20261127T215818Z/.Do not apply that global workaround: firstlane, vote-loop and writelane controls remain exact, but the previously passing native32 joined-latch consumer now refuses translation before dispatch. The initial refusal is a missing recursively referenced EXEC phi (
Value(22)->Value(38)at 0x28). Making unresolved-phi discovery visit backedges moves the refusal to numeric mask materialization at 0x48; it does not solve it. A separate SCC-as-Uniform structural probe also refuses mask-as-data before dispatch. These are local-probe admission regressions, not new upstream GPU-output failures. Logs:verify-pr2633-mask-phi-controls-20261127T215941Z/,verify-pr2633-joined-mask-structure-20261127T220256Z/,verify-pr2633-complete-mask-loop-controls-20261127T220442Z/,verify-pr2633-scalar-reach-loop-controls-20261127T220723Z/.Actionable owner boundary: preserve the distinction between a mask valid under per-lane reach and its actual EXEC bits through wave-wide lowering; discover all mask-phi/backedge dependencies and keep numeric-mask/SCC consumers supported. Keep both the seven break-loop native-oracle cases and the ordinary/joined native32 + logical64 lane-loop consumers as admission gates. The global mask/SCC probes and throwaway diagnostics are restored; only the previously passing local fixes/VCC variant remain, with sources for each causal variant archived alongside logs. Full-LDS fallback safety and the full title-program corpus remain separate gates; no rendering certification.
27 Nov 23:24 UTC — combined local correction passes the complete public oracle
On exact production
1b1ef2161a2f1cbcb46d7f72a7b24baf1303d419plus the disclosed local native-Wave32/writelane/VCC corrections, the break-loop compatibility blocker is now resolved locally. The native-Wave32 joined-latch fixture containss_mov_b64 exec, 0;Lanes::soprecognized only_b32operations for a Wave32 program, turning this low EXEC value into an opaque mask. Recognizing only the low-half meaning ofs_mov_b64(MOV has no SCC) removes that materialization failure. Do not extend this mechanically to b64 bitwise SCC: its high word can matter.Combined with preserving unresolved mask phis/backedge discovery, raw EXEC guards and whole-wave SCC/VCC loop votes, the unchanged public 151-case inputs match the independent native-gfx1036 oracle: 151/151, 154,624/154,624 output words exact, including 30 cases with the original 512-byte LDS reservation. The 2 ordered/nested writelane additions match 2,048 words, and native32/logical64 ordinary+joined consumers match all 192 words. Physical RTX4060 Laptop, NVIDIA590.48.1, Wine11, mandatory SDK validator and vendor0x10de/32-lane checks; diagnostic-relaxed vkd3d2576c0b4+ (not stock). No WARP or retry. Fresh6.78/7.02s intended-tree compilation; full-oracle run6.06s. Logs
verify-pr2633-exec-mov-loop-controls-20261127T232024Z/andverify-pr2633-exec-all-oracles-20261127T232131Z/; source snapshots+SHA256 manifest retained locally.I also removed the local
unrouteandkeptfallback paths rather than silently accepting a lowering whose required joins/exchanges failed. With those removed, the full151+2 cases and all192 consumer words remain exact. A 128-thread synthetic firstlane with all32KiB LDS reserved now explicitly refuses at0x20 for missing exchange space, while the native64 compile control succeeds. The enclosing owner admission test subsequently fails an implementation-only zero-barrier assertion (2 emitted vs0), not any readback; logverify-pr2633-failclosed-oracles-20261127T232433Z/is therefore 2passed/1failed overall, not all-pass.These are local experiments, not a PR-head pass, complete compiler certification or title result. Actual 52-container builder admission and integration remain next gates; no shader assets published and no title launch on this variant. The global mask-preservation policy needs owner review/targeting before shipping.
Original builder admission after the complete correction — 27 Nov 23:28 UTC
The same dirty
1b1ef216+ local correction, with unsafekept/unroutefallbacks removed, now translates 52/52 original XboxBvhBuilder containers, SDK-validates 52/52, and creates 52/52 native NVIDIA compute PSOs. Required validator is the logged DXCdxil.dll. Fresh intended-tree release compilation 47.17s; total guarded command 114.63s, GPU peak 338.0 MiB, available RAM minimum 8829.5 MiB. Evidenceverify-pr2633-corrected-builder-20261127T232615Z/{console.log,target-summary.json}. Original title programs were not dispatched by this CLI.The full-LDS admission fixture separately passes 1/1 after deleting its obsolete implementation-only zero-barrier assertion (not repinning it): a required exchange beyond the 32KiB budget explicitly refuses, while the native-Wave64 compile control succeeds. Evidence
verify-pr2633-failclosed-admission-20261127T232536Z/. This closes that admission check, not hardware execution at full LDS or rendering. No new title run yet; integration remains subject to combined runtime gates.28 Nov: paged runtime integration gates
The corrected backend is now ported into the existing dirty memory-tested runtime (base
3ed7d725, retaining Target-keyed caches, paged descriptors and prior memory/correctness fixes), not an exact PR-head result. Required NVIDIA/32-lane and SDK-validator gates pass: all151 public cases plus two ordered/nested cases are exact across156672 words; four native32/logical64 loop consumers are exact across192 words. Both paged-heap GPU fixtures and the explicit full-LDS refusal pass.verify-corrected-runtime-shader-gates-fixed-20261128T001655Z/:5/5, fresh7.40s build,5.84s fixtures.The reference partial/multiwave group checks also passed4/4 with39 explicit NVIDIA readbacks at48/64/128threads (
verify-pr2633-corrected-multiwave-20261127T232945Z/). On the integrated release, all52 original XboxBvhBuilder containers SDK-validate and create native PSOs (verify-corrected-runtime-builder-20261128T002116Z/, fresh50.91s build,120.27s total). Still no original-program dispatch proof from this CLI check. Runtime cache/builder/root-offset tests and the actual-bound texture-capture and native-FFX/depth fixtures pass. A30s no-input startup showed the account picker and time-stopped normally; no gameplay claim. Same Wine11/RTX4060Laptop/NVIDIA590.48.1 and diagnostic-relaxed-vkd3d caveat.Two local harness errors were corrected, not hidden as shader passes: the first integration test compile used the reference Host.wave32 API instead of runtime Host.target; a capture-fixture invocation omitted its required output folder and failed before recording. Both corrected paths pass. No BVH guard or resource limit removed.
28 Nov runtime follow-through: this local integration is not cleared for gameplay
The corrected, paged/scoped-memory mixed runtime described above passed its short startup, then exposed a new completion/watchdog gate. This is not an exact PR-head result or a proven #2633 regression. Same physical RTX4060 Laptop, Wine11, diagnostic-relaxed vkd3d; all resource and BVH all-or-none guards retained. Fresh release SHA256
46af3d20f062006c9a9d63f90a320c41117d38f923e0b2b75b7f01bce2efa042.00:30:07.522319Z, title frame2865 reports BVH builder53made/0refused/0dropped. This establishes admission, not correct original-builder execution.00:30:07.718–.869Z, but none completed/read back. The later actual-bound HDR probe was not reached. This is not another measured zero-HDR result.+0x23cf683, with+0x2215c35/+0x2215ecabelow it. Prior exact disassembly identifies+0x2215c35as the title watchdog fatal path. The saved crash context says Game Running/frame3668,735streaming requests, and an unsignaled cross-queue barrier. It does not isolate the stalled producer or prove shader causality.Evidence retained locally:
20261128T002637Z-{console.log,resources.csv,guard-events.jsonl},bound-apply-scene-trial-20261128T002636Z/, matching dump, exact binary/PDB. No game imagery/dump/assets published. Trace still has1366requested keys but only453with built records;205 distinct translation refusals are192mesh/13compute. Thus even the admitted-builder trial is not a fully compiled-scene verdict.No unchanged retry. I am inspecting the saved CPU waits/completion path and the multiwave synchronization boundary before choosing an offscreen regression. Useful owner isolation: associate queue submissions/signals/completed fence values with the first original-builder use, rather than treating52/52 PSO creation or the all-or-none admission log as execution proof.
Offline dump narrows the latest failure to native completion
The saved dump now provides an actual x64 PE-metadata unwind, not raw stack-word guesses. Executable/PDB GUID+age match the release above. Thread0x01e4 was inside
Host::execute'sWaitForSingleObject(event, INFINITE)(host.rs:1608), reached fromqueue::pump/Held::pump/queue::execute. Source order establishes that nativeExecuteCommandListswas called and bothqueue.Signalandfence.SetEventOnCompletionreturned success before this wait. Thread0x01d8 was secondarily blocked on globalHELDfromcopy_page_mappings; no CPU lock cycle is established.This identifies an outstanding native completion dependency, not its stalled GPU command or cause. The dump does not retain a submission/list/fence-value association with the recorded FFX/Apply work. A bounded static review found no concrete group-barrier/addressing defect; the existing48/64/128-thread checks still do not prove execution of the original256/512-thread builder programs. No further title run. Next diagnostic must identify submission/list and fence progress without releasing pending resources, forcing waits through, or changing queue ordering. Local evidence:
crash-offline-{evidence.json,summary.txt}beside this trial.28 Nov 01:34 UTC — native GPU progress bounded to a BVH dispatch interval
Still the disclosed dirty mixed runtime with the local semantic corrections above, not an exact PR-head or gameplay result. Linux/Wine11, RTX4060 Laptop8GiB, NVIDIA590.48.1, diagnostic-relaxed vkd3d
2576c0b4adfae4a+; all original resource/BVH guards retained.The first passive run (
20261128T010746Z) completed native submission7975 but not7976. ExecuteCommandLists/Signal/event arming returned; three native-fence samples remained7975 for2.16/4.16/6.16s. Its separately recorded native-FFX capture list was never submitted before the early stop. Thus recording the FFX call did not establish that FFX was executing at the stall. The CPU note cap was512, so that run alone did not identify the failing command.Added a default-off local probe using the actually enabled
VK_NV_device_diagnostic_checkpointsextension (VKD3D_CONFIG=breadcrumbs), not timestamp queries or WriteBufferImmediate barriers. Unique recording/note tokens, current native command buffer obtained at every marker, retained native queue/device owners. No inserted GPU waits, resource writes, queue splitting or changed dispatches. The real-NVIDIA copy fixture checks all64 words and distinguishes a completed list from a second list held behind a CPU fence, then verifies completion after release;1/1. Existing real native-FFX FP16/RGB9E5/depth fixture also1/1 with the probe enabled.Changed title trial
20261128T012958Z, fresh intended-tree diagnostics release:Dispatch(1055,1,1), compute5552dac6a2b7a1fd. Note2199 is before the followingDispatch(9,1,1)of the same program.5552dac6a2b7a1fd,XboxBvhBuilder.dll+0x53fd0,29024bytes, threadgroup[32,1,1]. Group size by itself does not establish the original console wave-size flag.VKD3D_CONFIG=breadcrumbsalso changes this vkd3d build's native timeline wait fromUINT64_MAXto 5seconds (libs/vkd3d/command.c:643-661). Its VK_TIMEOUT path callsd3d12_device_report_faulteven with built-in breadcrumb recording compiled out (vkd3d_private.h:4500-4503). Therefore the third-sample0x887a0005 is the diagnostic timeout/reporting path, not independent evidence of a new kernel/driver reset or a new shader regression. The unchanged first two checkpoint/fence samples occur before that5s deadline. No timeout will be raised to push through this result.vkd3d_wait_for_gpu_timeline_semaphore ... vr 2(VK_TIMEOUT). Supervisor stopped the workload before the title watchdog; no watchdog suppression or unchanged retry. No kernel journal entries in the actual interval; idle telemetry recovered133MiB/0%/38C.Only loading imagery, no scene/gameplay. Sampled GPUpeak3580MiB, minimum availableRAM4499.8MiB, scopepeak9128.1MiB (near the9GiB scope cap), minimum availabledisk10.016GiB. This was not a RAM/GPU/disk-guard stop, but these samples do not exclude memory-pressure effects. Identified unheld temporary backing files cleaned after scope exit; trace losslessly compressed.
Local evidence:
.compat-runtime/logs/native-submission-trial-20261128T012958Z/{summary.json,checkpoint-events.txt,pending-recording-notes.json}and timestamped console/resources. Images/assets/raw root-address data stay local. Earlier CPU-noteheap:nulllabels must not be interpreted as null root bindings: that formatter sometimes interprets64-bit root addresses as heap indices.Actionable next gate: inspect this exact builder program's loop/scalar/atomic termination invariants, then reproduce any mismatch with a bounded synthetic fixture. We are doing that offline rather than replaying the failed title, skipping the dispatch, disabling the all-or-none guard or raising timeouts. Compilation/admission53/53 is now clearly insufficient to certify execution.
28 Nov 01:47 UTC — another one-host-wave semantic boundary reproduced and corrected locally
The checkpoint program's original FSSM record now confirms native Wave32, not merely a32-thread group: shader
5552dac6a2b7a1fd, record flags3145760 with FLAG_WAVE32(bit5) set,12928 native-code bytes, group32×1×1. Original module/container hashes remain unchanged. This does not yet establish that either particular first-lane instruction takes the affected widened route.A bounded synthetic consumer exposes two gaps on the same dirty #2633-based integration with the earlier proposed local corrections (not a pristine upstream-head comparison): enter lanes8–31, read the first active lane into anSGPR, then consume thatSGPR in every lane after reconvergence.
v_mbcntexplicitly selects console-lane handling. Expected8 everywhere.Cause and narrow correction:
first_lanereturnedNoneunconditionally for!trades(). In a widened region physical lane0 executes even when excluded by emulated EXEC;waveReadLaneFirsttherefore selects the wrong lane. Keep the old fast path only outside widened regions; inside, ballot emulated EXEC and read its first lane. Return that same-host result without a half exchange when!trades().scalar_joinexplicitly excludedhalves && one_host_wave(). Remove that exclusion: physical-wave sharing does not distribute an SGPR update to lanes that skipped its defining branch.Before: fresh7.96s intended-tree compile, regression0/1 in0.81s,
verify-native-firstlane-before-20261128T014458Z/.After: fresh7.38s compile, 5/5 focused checks in7.46s: new128-word consumer, existing first-lane/loop fixtures, four lane-loop consumers(all192words), and the published no-loop RDNA2 oracle(10240words).
verify-native-firstlane-corrected-20261128T014616Z/. New consumer requires actual NVIDIA vendor0x10de/physical lanes32–32, mandatory SDK validator, native PSOs and complete GPU readbacks. No WARP proof; unchanged Wine11/NVIDIA590.48.1/diagnostic-relaxed-vkd3d2576c0b4+ and guards. PeakGPU217MiB/minavailableRAM11496.7MiB.No title rerun or watchdog-fix claim. This is an established scalar consumer correction on the mixed stack. Its exposure in the original dispatch, upstream producer validity and any other BVH semantic gaps remain to be checked. The original parent-walk is not a cross-workgroup spin-wait; its uncapped traversal depends on acyclic parent links and returning-atomic retirement. Source inspection found the aliased carry input/output correctly uses distinct SSA values, so no carry-alias defect is claimed.
Self-contained synthetic consumer fixture (no title code or assets)
Original-program exposure and bounded title progress (2026-11-28 02:09 UTC)
The original
5552dac6a2b7a1fdprogram does exercise the corrected first-lane route: its allocator broadcasts at0xd38/ block 51 and0x2444/ block 147 both lower withwide=true, trades=false. With paged views and both write-mark settings, the unchanged original container passes mandatory SDK validation and real RTX 4060 native PSO creation (one local probe, two emitted variants). This was not original-program GPU dispatch. Temporary emission tracing was removed before the fresh release.The next usable title observation is stronger but still bounded: same dirty mixed
3ed7d725integration with the disclosed local corrections, release SHA2563e1626216d5f88213c7f15f7906a82bfc9d9caede3420616505cfbd2ec0383b8, Wine 11 / RTX 4060 Laptop / NVIDIA 590.48.1 / diagnostic-relaxed vkd3d2576c0b4+. In submission 7589, recording 17285, the formerly stalled Dispatch(1055,1,1), CS5552 is command 2138. Native bottom-of-pipe checkpoints subsequently advanced 2830 → 3066 → 3853 at 2.22 / 4.22 / 6.22 seconds. Thus the GPU passed that dispatch shape and continued through later builder work, rather than staying at the old checkpoint. This is not a same-input BVH readback comparison, a completed-submission result, or proof that all builder output is correct.At the third sample
GetDeviceRemovedReasonreported0x887a0005; the external six-second pending-submission stop terminated the scope. Important diagnostic confound:VKD3D_CONFIG=breadcrumbsmakes this vkd3d build use a five-second semaphore wait (command.c:649–662), whereas these checkpoint samples show continuing GPU progress. No kernel GPU/reset/OOM entries occurred in the measured interval. I am testing without the heavyweight checkpoint/breadcrumb diagnostics next, retaining the independent six-second pending stop, four-second telemetry-query stop, all resource guards, and the unmodified title watchdog; no native-driver timeout patch or higher resource limit.The last observed window was loading artwork; no gameplay or watchdog-fix claim. GPU peak 3696 MiB, available-RAM minimum 4156.5 MiB, disk minimum 10.701 GiB. An earlier corrected-build attempt hit the disk guard before this observation and is not counted as a shader result. Local evidence:
verify-original-bvh-firstlane-route-20261128T015126Z/,native-submission-trial-20261128T020530Z/{verified-summary.json,native-checkpoint-progress.json}, and matching console/resources. Original game containers and imagery remain local.Checkpoint-free follow-through (2026-11-28 02:18 UTC)
Same corrected mixed release as above (
3e1626216d5f88213c7f15f7906a82bfc9d9caede3420616505cfbd2ec0383b8), with only NV checkpoint/native breadcrumb diagnostics disabled; external six-second pending/four-second query stops and all memory/GPU/disk guards retained. Wine11 / RTX4060Laptop / NVIDIA590.48.1 / disclosed diagnostic-relaxed vkd3d2576c0b4adfae4a+.5552dac6a2b7a1fdcalls before truncation; this is not a complete command count or a BVH output comparison.Evidence:
.compat-runtime/logs/native-submission-trial-20261128T021431Z/{verified-summary.json,pending-recorded-commands.json}and20261128T021432Z-{console.log,resources.csv}. Thus the earlier stalled BVH dispatch shape is no longer the observed stopping point after the narrow firstlane correction; full BVH correctness and a final colour frame remain unproved. The next local diagnostic uses independently verified, bounded per-list completion words rather than native breadcrumbs, preserving batch boundaries and native-fence retirement. Its real-GPU copy/order/reset fixture passed1/1 (128checked data words; old completion cannot cover a reset recording), not a title result.28 Nov — later unfinished graphics interval, not renewed BVH attribution
Follow-through on the same disclosed dirty Linux/Wine/RTX4060 Laptop integration with the local native-Wave32 EXEC/first-lane correction; diagnostic-relaxed vkd3d
2576c0b4adfae4a+, not exact PR-head or stock certification. No further shader edit in these two observations.20261128T023221Z, checkpoint-free per-list end words: the BVH-containing submission completed in 4799ms. A later23-owned-list batch remained pending at6193ms, device removal reason0;18 list-end words had completed. The first unfinished recording has182 CPU notes:91 non-dropped indirect graphics calls,89 existing dropped-pipeline notes,2 barriers. Its first two graphics candidates are VS25ebc92075b62822with PS1cd9bc634417a981/48e74d16cbfa45e3(tiled lighting). This narrows the unfinished interval, not the executing shader or a proven deadlock; preceding transition/prelude work is not independently marked. User heard audio and saw a coloured prologue background without the title text. No visible gameplay.20261128T024422Z) stopped earlier: the six-second external rule triggered at6132ms on a BVH-containing batch, but that batch completed at6442ms before termination. Its last observed marker512 is the diagnostic note cap, not an isolated instruction. User reported no audio/prologue in this trial. Do not interpret this as recurrence of the fixed native32 first-lane failure. Instrumentation overhead is possible, not established by matched timing.Evidence retained locally:
native-submission-trial-20261128T023221Z/{verified-summary,pending-list-attribution}.json,native-submission-trial-20261128T024422Z/{verified-summary,pending-command-attribution}.json,verify-graphics-list-progress-20261128T025120Z/,verify-native-observation30-20261128T025407Z/. New owner head00a023481512edbf3ff1c22108aebbc772149e33was noticed; these results do not test its two newer commits.28 Nov —30second observation resolves a specific later graphics boundary
The selective-graphics trial is now complete:
20261128T025611Z, same disclosed corrected mixed production (not new00a02348), fresh intended GPU/HLE/app release32.52s. The BVH-containing submission completed in 5457ms. Later submission8792 remained pending for 30066ms, native device-removal reason0. Across all15 samples21/26 owned-list end markers completed; the first unfinished list stayed at before-note3, never reaching note4/end.That interval is the indirect graphics operation with VS
25ebc92075b62822and PS48e74d16cbfa45e3, exact original nameTL_PS_NoDir_PBR_MATERIAL_STANDARD_42ad1e50_Wrapped. The immediately preceding operation uses the same original argument address/VS with PS1cd9bc634417a981. MARKER_OUT reaching note3 brackets preceding work, but does not prove the preceding pixel shader ran (an indirect record can have zero instances), nor identify an instruction inside the stalled interval. Pipeline/binding/argument/transition work remains in scope—not yet a demonstrated NoDir translator defect.The title also raised its deliberate null-write watchdog (
+0x23cf683, caller+0x2215c35) near03:00:32, before the external30s termination. Loading artwork120/150/180s; window210/240s black. GPUpeak4443MiB, minimum availableRAM4277.1MiB, scopepeak9096.5MiB, diskminimum10.214GiB; not a resource-floor stop. No kernel GPU/reset/OOM entry; inactive scope verified and only identified unheld backing reclaimed.Exact original1cd9/48e7 containers are retained locally with matching BLAKE3/SHA256; CPU-only disassembly parsed both (1.60s), no extracted game bytes/images published. Actionable next gate: isolate this exact NoDir indirect-draw interval, distinguish its bindings/arguments from pixel/helper-lane lowering, and require an offscreen consumer regression before another title retry. Do not bypass the watchdog, omit the pass, or infer rendering from completed BVH pipelines. Local evidence:
native-submission-trial-20261128T025611Z/{verified-summary,pending-command-attribution}.json,graphics-boundary-shaders-20261128T025611Z/containers.json,verify-graphics-boundary-shader-info-20261128T030313Z/.28 Nov — isolate our compute correction from pixel lowering (not an owner regression)
The local
route_votes/route_lane_writesadditions described above were eligible for pixel programs, whereas the relevant console-lane setup is compute-only. These additions are absent from owner1b1ef216; this is a local-integration finding. The exact stalled-boundary NoDir pixel48e74d16cbfa45e3emitted 24 of 25 first-lane reads through our widened early return rather than the existing pixel helper-aware fallback. Both local route methods now requireStageIo::Cs, preserving the compute correction and restoring the existing pixel route. All 25 reads now use the helper-aware fallback; marked/unmarked original emissions pass required SDK validation. That check does not dispatch the original shader.Fresh mixed-tree verification on the physical RTX 4060 Laptop/Wine 11, NVIDIA 590.48.1, diagnostic-relaxed vkd3d
2576c0b4adfae4a+: 8/8 pass, 7.39s compilation, 4.92s tests. This includes the original emission, an actual bounded pixel/quad draw, and six retained compute firstlane/scalar/lane-loop/writelane/vote/break consumer fixtures. Evidence:verify-compute-stage-pixel-corrected-gates-20261128T031657Z/.No pixel-corruption or title-stall fix is established yet. The bounded 16-round gradient waterfall passes on both sides. Two earlier local fixture failures used OR rather than AND-NOT when removing served EXEC lanes; those are invalid shader verdicts. The corrected baseline is
verify-pixel-helper-waterfall-corrected-control-20261128T031616Z/(1/1). This change limits unintended scope, not a claimed matched bug fix. A fresh changed-stack title observation is pending; all resource guards, the 30s pending window and the title watchdog remain intact. No original shaders/assets are attached.28 Nov — changed-stack title follow-through: former graphics boundary completes
After the compute-only eligibility change above, a fresh shader/GPU/HLE/app diagnostics release (47.90 s) was run on the same Linux/Wine/RTX 4060 Laptop diagnostic stack. Mixed base
3ed7d725+ corrected1b1ef216; not the newer00a02348head. Same 30-second pending-submission cutoff, 9 GiB/512 MiB scope and global GPU/RAM/disk guards; title watchdog unchanged.The first material recording has the same three command headers as the earlier stalled recording: barrier, STD
1cd9bc634417a981, NoDir48e74d16cbfa45e3(same VS25ebc92075b62822, original argument address and max-count). Both shaders freshly translated and created before their first bind. All 11 submissions containing those material draws completed, 31–208 ms; the longest submission overall completed in 6,548 ms, and completion continued through submission 8111. No watchdog/access-violation or kernel entry was observed before the stop.This is positive progress past the former boundary, not a controlled-cache causal proof or general hang fix. A recorded indirect draw and completed submission do not establish nonzero instance count, pixel execution, identical descriptor contents or correct shader output. The corrected synthetic pixel fixture still passes on both sides.
The unchanged 10 GiB user-available disk floor, not a pending timeout, stopped the run at 247.83 s (9.996 GiB; exit 137). GPU peak 4,229 MiB; available-RAM minimum 3,513.1 MiB; scope peak 9,216 MiB. The window remained black at 240 s. Native FFX input/output samples 1 and 8 remain raw RGB zero; depth sample 8 is populated (6.68% nonzero). There were still 782 unfinished pipeline builds. No visible or controllable gameplay. Four exact-inode/unheld backing files were reclaimed only after scope exit; guards were not weakened.
Local evidence:
native-submission-trial-20261128T031948Z/{verified-summary,material-command-attribution,backing-cleanup,trace-compression}.json, matching console/resources and the previous025611Zboundary evidence. Captures/assets remain local. Next diagnostic is completed lighting/HDR producer work and missing dependencies, not another unchanged black-frame retry.28 Nov — actual intro scene captured; performance remains far from playable
The same corrected local 1b1ef216-based mixed executable now displays an actual city/palm/coloured-light intro scene in the Wine client (040112Z, unmodified client capture at04:06:08Z), not merely an intermediate target. Lighting is severely wrong/dark, controllability unverified. This does not certify current owner00a02348 or canonical main. No images/assets published.
Full hardware/provenance report and sanitized profiling data: RTX4060 Laptop8GiB/16GiB/Linux6.17/Wine11, same diagnostic-relaxed vkd3d caveat. A subsequent diagnostic run stopped at342.62s on the unchanged2048MiB global-RAM floor; its last capture remained black, so it is not a second visible-scene proof. Fifteen late host-present intervals have4.38s median/16.57s max; pipeline workers account for6.19 of7.80 active CPU cores despite758 native-library loads versus2made. Copy/wait costs and390unfinished pipelines remain. Recorded-command logging still produced103.49MiB, explicitly disclosed. Next: remove that diagnostic overhead without weakening the native-progress observer, time cache-load/PSO work and copy owners, then verify actual shading. Earlier failure history and all shader-safety gates remain intact.
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-27T19:59:14Z.
@carlosmegino The archived gfx1036 inputs keep
b32cef7and1b1ef21comparable for the Windows run. Please keep the LDS promotion on its own branch and record 658 → 388 as guest LDS operations.@pickles976 That clears the 508-word first-lane mismatch and both Wave64 loop consumers on the RTX 4060 Laptop setup. I’ve recorded the 12 native-Wave32 mismatches separately for the Vice-Tay comparison.
Imported from Marvisak/VIctory. Originally posted by carlosmegino on 2026-11-27T20:00:48Z.
@chippy01 — matched native Windows / RTX 5070 Ti validation completed at control
b32cef72554981f89fad00fecc8358699518da8aand candidate1b1ef2161a2f1cbcb46d7f72a7b24baf1303d419. Physical adapter 0x10de/0x2c05, waves 32/32, driver 621.01, Rust 1.98.1, SDK 10.0.26100.0 DXIL validation, debug layer + GBV. Production operations unchanged; local test-only route markers.b32cef71b1ef216All ten original masks / 10,240 words per arm were compared with the unchanged archived gfx1036 oracle, with complete readbacks and extra guard words. Your three new regressions also pass with strict hardware setup. The consumer invocation retains the original zero-error assertion and therefore still fails overall on the native Wave32 negative; it is not an all-passed suite. The exact SDK host warning about ignored COPY_DEST initial state was logged separately; no other warning/error was accepted.
Fallback check: both exact retained programs validate and create PSO, and their unsigned DXIL is byte-identical to
b32cef7. Neither was dispatched; semantic correctness remains unverified. A separate synthetic 128-thread firstlane negative, unchanged instructions but all LDS reserved so trades cannot be allocated, takesunrouteand executes with 64/128 wrong lanes. This confirms that successful fallback admission can retain incorrect answers; it does not establish that runtime error for the two real programs.New LDS compatibility evidence: your head already runs Dathinel's intact original 64- and 96-thread fixtures correctly (448/448 and 672/672 words, 56 guards each). Our explicitly promoted forms instead have 128 and 192 wrong words. On promoted96, only the own/peer counter UAVs differ: counters 256/160 instead of 160/112; the other five UAVs and all guards match. Static emitted barriers increase 9→15 (64) and 5→11 (96). This sequence was correct on the paired reference, so we are not enabling it on halves or claiming a performance/partial-group coverage gain. Counting all present lanes per visit is consistent with the observed totals, but that is a hypothesis rather than a root-cause fix.
The attributed, test-only prototype and its backend-neutral analysis are now public at 03be2d0, with a synthetic failing repro/installer and full limits. Independent technical review requested (@PiloteCode @Dathinel too): especially the privacy/atomic/alias proof and the rewritten numeric-EXEC count on wave-wide regions. Is related work already planned? No competing scalar or mask correction is being posted.
The static applicability check proves none of the 59 archived Wave64 programs containing ds_add under the current narrow region/layout contract; it does not show those programs are inherently unoptimizable. No original BVH program was dispatched and no BVH PSO census, full 151-case rerun or water-path comparison was repeated. The remaining 20 cases, f32 order, #269/#320 and TaynanGT's water comparison stay separate. NEW-354 remains active. AI-assisted with OpenAI Codex.
Imported from Marvisak/VIctory. Originally posted by ColorMeBoom on 2026-11-27T20:17:55Z.
@chippy01 RX 5700 XT (RDNA1) at
1b1ef21, merged ontomain63bcca4, same fw64 harness and gfx1036 oracle as my earlier runs:host_wave32: true): 131 exact / 20 differ / 0 refused, the same counts as your RTX 3070 Ti and Radeon iGPU.firstlane_branch10/10,readlane_branch20/20,red_*all exact. What's left isbreak_loop5,vote_loop3,vote_loop_branch4 andwritelane_branch8. 146 programs carry PSV0 32..32. The PR'shalvestests: 39 passed, 0 failed.host_wave32: false: byte-identical tomainin 151 of 151 (59 exact). That's the form a 64-lane host (AMD) runs, and the PR leaves it alone. The same scalar-join problem is open there as #3562, with a fix for the per-lane form in #3593. It uses the same rule as your commit (the value of the last block in code order that some lane of the wave ran) and takes that form from 59 to 108 exact.The two together: #3593 and this PR conflict textually in
lower.rs(themodlines, and the calls after a block's phis:wide_enter/lds_block_startandwave_scalars). Both sides are kept. There's one real interaction:wave_scalarshas to leave halves alone (|| self.halves), because thereconsole_lanesis set while the host wave is half the console's. With that, merged locally on this card: halves 131 / 20, byte-identical to this PR alone in 151 of 151, andhost_wave32: false108 / 43, byte-identical to #3593 alone. So whichever lands second needs that one-line guard; I'll add it to #3593 if this PR goes first. (The full suite on the local merge didn't run: Windows Application Control blocked that test binary.)AI use: Claude Code (Claude Opus 5.5).
Imported from Marvisak/VIctory. Originally posted by chippy01 on 2026-11-28T02:32:59Z.
@carlosmegino @pickles976 @TaynanGT thanks for the matched runs on
1b1ef21. Two more commits are up (claimed in #1633). The first answers the fallback finding; the second closes the last gap to #439 apart from the tiled shapes.The first-lane fallback. carlosmegino is right about this. If a program runs in halves only for its first-lane reads and can't run there, it keeps
main's form: each 32-lane host wave reads its own first lane, and the DXIL is byte-identical tob32cef7, as you found. Two title programs took this path:The second one is a real limit, and carlosmegino's synthetic negative hits exactly that limit. Shaders: in halves, a trade borrows its slots from an LDS that fills the host's 32 KiB removes it. When the slots don't fit beside the program's LDS, the trade borrows the program's first LDS dwords: a barrier, each thread saves one dword, a barrier, the trade, each thread puts its dword back, and a final barrier. Only those programs pay for the three extra barriers.
A new test,
a_trade_beside_a_full_lds_borrows_its_slots_and_gives_them_back_on_every_gpu, has the same shape as the negative: a first-lane read of data across the halves, with every byte of LDS reserved. Every thread writes its own LDS dword before the trade and reads it back after. It runs in groups of 48, 64 and 128; the 128-thread group is in halves only because of its first-lane read. On the RTX 3070 Ti and the Radeon iGPU, 0 lanes differ and every LDS value is intact. Before the commit it was refused. In the title, the hit-detection program now runs in halves instead of falling back, and the two programs refused for the same reason now translate.Descriptors chosen where the whole group goes into a region. The commit Shaders: in halves, a descriptor chosen where the whole group goes into a wave-wide region folds as the wave's scalar translates the two remaining programs #439 handled and this didn't. A scalar branch sends the whole group straight to a region's last block, and that block's store picks its descriptor by control flow. On the console that descriptor is scalar data the wave holds, so its heap index now folds the way a scalar phi does. A new case in the whole-group region tests has this shape: in halves on both GPUs and as one wave64 on the Radeon, 0 lanes differ. #439 now translates only the 4 tiled group shapes this refuses, and its split form gets their thread ids wrong on NVIDIA.
Title (
translate --list --wave32 --pipelines, same four inputs, RTX 3070 Ti): compute pipelines made 2,723 at1b1ef21→ 2,725 with the descriptor commit → 2,727 with the borrowed slots, of 2,763 (25,750 pipelines in all), none lost on the way. One program still falls back for its first lanes: they're all in the compiler's scalarization loops.Native wave32. The 12/32 consumer is a wave32 program, and those don't run in halves. On any host they run in main's per-lane form. There, a scalar after a lane-dependent loop is each lane's own value, and reading a lane that has already left the loop returns nothing. That's what #269 fixes for scalars and #320 for lane reads where lanes branch differently, so fixing it here would duplicate their work.
LDS counter promotion: nothing related is planned on our side.
AI-assisted (Co-authored by Claude Opus 5.5) and measured on my own machine.
Imported from Marvisak/VIctory. Originally posted by chippy01 on 2026-11-28T02:55:31Z.
Btw if someone wants to contribute to this PR with tests or commits you are more than welcome. 🫡
Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T03:09:45Z.
I checked the new
00a023481512edbf3ff1c22108aebbc772149e33head and added an LDS-boundary regression. Test commitac857bbextends the PR's existing first-lane and LDS readback test. It compares the last LDS size that fits separate trade slots, one dword beyond that size, and the full 32 KiB case, for groups of 48, 64 and 128 threads.A separate app-local WARP 1.0.22 run using Agility 1.620.2 validated all nine shaders through DXIL validation and PSO creation. All 1,440 output words matched the expected first-lane result and restored LDS values. The
halvesfilter reported 41 passed, including the temporary WARP test. The physical-adapter sections still skipped on this host. The committed test compiled withcargo check -p victory-shader --release --tests --locked.The CI run for this PR head passed both Clippy stages and stopped at
frame::tests::waits_end_on_ticks_and_count_frames. The branch also preserves the exact #2877 virtual-clock head through merge4a1c1c3. The extracted frame module passed 24 repeated test-process runs on both configurations, with three tests per run on the combined branch. #2877 can be considered separately from the shader regression.Please retain the Git authors on cherry-pick or rebase, or add
Co-authored-by: andrewpozdnakov7-jpg <[email protected]>if folding my test into another commit.AI-assisted with OpenAI Codex.
Imported from Marvisak/VIctory. Originally posted by pickles976 on 2026-11-28T05:48:54Z.
Verified exact production head
00a023481512edbf3ff1c22108aebbc772149e33on RTX 4060 Laptop / NVIDIA 590.48.1, Linux 6.17 / Wine 11, 32-lane host. NVIDIA masking disabled; diagnostic-relaxed-vtable vkd3d2576c0b4adfae4a+(not stock certification).b538852f58c99307(ScreenProbes ActivateProbes) andd3e5b737ea7cc150(ClusterLightsWorldSpace): 2/2 emitted, mandatory SDK DXIL validated, native PSOs created, one worker. No original-program dispatch or title rendering claim. Fresh intended-tree release compile 46.90 s; entire guarded command 51.53 s.Evidence:
verify-descriptor-owner-original-programs-20261128T054110Z/andverify-descriptor-owner-region-lds-20261128T054702Z/. No game assets/images uploaded.Integration caveat: our older, heavily mixed runtime with local scalar/loop corrections plus only
7103ccfcstill fails an SDK dominance check (into 48 false, icmp result used by a non-dominated xor) and does not validate those originals. A retained older local-fixes control has the same synthetic failure. The clean exact owner head above passes: this is not a reported regression in your current head. We are isolating our integration difference before promoting it; the partial port is not a runtime recommendation.Follow-up on the admission boundary: the clean head's ScreenProbes success is not evidence that the cross-half meeting was established.
lower.rs:162-167permitswide.unroute()after failed first-lane-only halves lowering, then retries the plain route. Our older mixed runtime deliberately retains the refusal instead of that retry. The original program has onev_readfirstlane_b32at0x110; its missing scalar later surfaces as a refusal at0x358. We have not executed that original program, so this observation alone does not establish wrong output on the clean head. A read-site/guard-scoped uniformity proof or original-program execution oracle is still needed before treating the admission result as exact Wave64 semantics.Separately, the mixed-stack ClusterLightsWorldSpace forward-reference panic was narrowed to entry-mask replacement scope plus stale IR context during deferred boolean construction. After a local correction it emits and creates a native NVIDIA PSO, but mandatory SDK validation still says
Module bitcode is invalid(0/1 validation). We have not promoted it to a title run. Evidence:verify-mixed-cluster-lights-location-scope-20261128T061631Z/. This remains a local integration defect, not a clean-head regression.Mixed-runtime follow-through, 28 Nov 06:53 UTC
The local scoped-SSA correction now passes the original ClusterLightsWorldSpace
d3e5b737ea7cc150: one emission, one required SDK validation, one native NVIDIA PSO (--host-lanes 32-32); fresh intended-tree compile10.11s, guarded13.05s. No original-program dispatch. Logverify-mixed-cluster-lights-final-20261128T065230Z/. This supersedes the earlier mixed-stack validator failure, not the historical log. The fix carries explicit predecessor IR context through deferred Boolean lowering and resolves composite leaves through the valid entry phis; it does not relax mask or wave guards.Ten retained consumer checks passed. The extended composite-mask region GPU fixture now also passes after correcting our lab fixture (an accidentally encoded32-bit OR, then a mask/data initialization and an unsupported elsewhere-mask consumer). Final fixture retains the composite join, uses a real false mask, and explicitly intersects with current EXEC before counting; identical console expectations are preserved. Final evidence
verify-mixed-composite-mask-consumer-20261128T065308Z/; earlier failed probe attempts are not owner regressions.On exact production
00a023481512edbf3ff1c22108aebbc772149e33, two additional synthetic scalar-splat consumers—confined and reconverging—both SDK-validate and return all64 expected words on physical RTX4060 (2/2, fresh6.70s compile,1.29s tests;verify-owner-active-splat-consumers-20261128T064600Z/). These simple programs do not establish the original ScreenProbes SMEM/indirect-exit contract. That original remains refused in the mixed runtime; the generic plain-wave fallback was not imported. No claim of a reproduced fault in those two positive controls.Both ClusterLights and ScreenProbes refusals were already logged in our actual rendered-intro baseline
20261128T051844Z; clearing only ClusterLights is a changed rendering candidate, not a claim that all lighting is fixed. Same Wine11/NVIDIA590.48.1/diagnostic-relaxed-vkd3d conditions; all safety cutoffs remain intact. No title result for this correction yet.28 Nov runtime safety follow-through: the same mixed release with the validated local descriptor-entry correction rendered intro palms/buildings/lights, then a 25-list native submission stopped completing. Execute/Signal/event arming all returned; NVIDIA logged Xid109/CTX SWITCH TIMEOUT about 6 seconds into the completion wait, and the title watchdog followed. No guard threshold or telemetry timeout fired. This is not attributed to ClusterLights, this PR, or the last shader compiled: background pipeline workers continued after the already-recorded batch was submitted. The performance-mode trace had no per-command/list identities.
Full measured profile, exact binary/provenance and chronology: https://github.com/Marvisak/VIctory/issues/841#issuecomment-7234510162 . Title/GPU trials are parked, with all shader/builder/resource guards intact. The local observer now optionally snapshots bounded, already-retained pipeline names before Execute and reports them on a pending wait, rather than relying only on the unreachable post-wait slow-list report. Its two CPU-only ownership/bounds/nonblocking tests pass; actual native-pending activation is not yet tested. This supplies candidate provenance for a separately justified changed-stack experiment, not a GPU-hang fix or permission to rerun unchanged.
Imported from Marvisak/VIctory. Originally posted by ColorMeBoom on 2026-11-28T06:57:41Z.
@chippy01 @andrewpozdnakov7-jpg Physical run of the new head and the LDS-boundary test, on a card that has both wave sizes: RX 5700 XT (Navi 10, RDNA1, 32–64 lanes, driver 32.0.21045.29003, Windows 11 26200). The hardware sections ran; nothing skipped.
Head
00a0234:victory-shader --lib --features host: 336 passed, 0 failed, 3 ignored;halvesfilter: 40 passed;random_wave64_programs_in_halves_match_one_wave64: 64 of 64 compared against one wave64 on the same card, none refused.andrewpozdnakov7-jpg's
ac857bb(on00a0234):a_trade_beside_a_full_lds_borrows_its_slots_and_gives_them_back_on_every_gpupasses on the hardware adapter. That covers groups of 48, 64 and 128 at the last LDS size that fits separate trade slots, one dword past it, and the full 32 KiB. The wholehalvesfilter: 40 passed.@Lyrnc's 151 hand-written wave64 cases, each compared lane by lane with a gfx1036:
00a0234: 131 / 151 exact, every output identical to1b1ef21;WaveSize(64): 59 / 151, unchanged.So the two new commits don't move any existing case, and the remaining 20 (
break_loop,vote_loop*,writelane_branch) are as before.AI use: Claude Code (Claude Opus 5.5).
Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T06:59:04Z.
Thanks, ColorMeBoom. Your RX 5700 XT result adds a native hardware pass for all three LDS boundaries in the test-only commit
ac857bbon00a0234. My earlier run used WARP. The separate 151-case comparison applies to the reported head and remains at 131 exact matches.chippy01 can pick up the LDS-boundary test from the branch linked in the original test report.
Please retain the Git author on cherry-pick or rebase, or add
Co-authored-by: andrewpozdnakov7-jpg <[email protected]>if folding the test into another commit.AI-assisted with OpenAI Codex.
Imported from Marvisak/VIctory. Originally posted by chippy01 on 2026-11-28T14:54:10Z.
@neonbyte1 Sorry to bother you but I looked at your work and you look like a man of culture, whenever you have time could you take a look at this work ( #2633 ) and benchmark it on your hardware?
I know this is a huge PR but without constant merges I tried to collect all the common knowledge achieved by the whole contributors and incrementally build this whole beefy PR.
The idea behind this was to create a contribution to the code to directly solve the problems connected to running wave64 instructions onto wave32 systems whithout using workarounds.
I have also to really thank whole the people who worked on #439 and gave me a really good starting point on what had to be done.
Imported from Marvisak/VIctory. Originally posted by neonbyte1 on 2026-11-28T14:56:38Z.
@chippy01 happy to. Here's what I'll run on the RTX 5090 (Linux, Wine 11.22 + vkd3d-proton) and post here:
00a023481against its base63bcca43c, over the whole shader pack. For each, how many programs translate, how many are refused and for which reason, and whose wave size changes.For context: my fork's integration takes the other route (#439/#320's console flow, plus pair meetings for groups of several console waves, #3683), so I can also say how the two compare on the same title.
The census and tests come first; the game runs follow in our queue today or tomorrow morning.
Edit: changed the priority schedule, results should arrive within the next few hours.
AI-assisted (Claude); measured on my machine, no game data shared.
Imported from Marvisak/VIctory. Originally posted by neonbyte1 on 2026-11-28T15:30:56Z.
@chippy01 first results from the RTX 5090 (Linux, Wine 11.22 + vkd3d-proton). Your head
00a023481(A) against its base63bcca43c(B), diagnostics builds, no patches needed to build either under Wine.Your tests: all 34 of the PR's halves tests pass on the 5090, in 51 s.
Census over the whole shader pack (26 084 programs; the compute side, which is what this PR is about):
WaveSize(64), which a 32-lane NVIDIA device then refuses at pipeline creationWaveSize(64)to 32, so none of them are refused by the device for wave sizeA's 31 translator refusals: 13 lane-mask join of an untracked mask, 6 tiled group shapes, 5
v_cvt_f32_f64, 4 lane mask read as data, 1 divergent lane mask, 1 descriptor read only as data, 1 descriptor address read as data. 7 of them are halves-specific.For comparison, my fork's integration (#439/#320's console flow + #3683's pair meetings) emits 2,629. Your halves translate 42 programs the console flow refuses: 15 whole-wave sections, 13 implicit-derivative samples in the console flow, 12 with a title barrier not met, 1 value used before the meeting, 1
v_permlanex16_b32. The console flow translates 20 that the halves refuse (13 lane-mask joins of an untracked mask, 5 tiled groups, 1 mask off the meeting, 1 descriptor address). So the two cover different gaps.One correctness point to check: when one half writes a UAV address that the other half reads later in program order, the emitted shader has no barrier between the halves (0
dx.op.barrier). On the console that's program order inside one wave. In the console flow we measured up to 53 % stale reads for exactly this pattern before adding a UAV fence (#439, #3683). A port of that test to your halves saw no stale read in the 96 samples it could take on the 5090, but nothing orders the two halves, so I'd expect it to show up under load. The test and the fix shape are in https://github.com/neonbyte1/VIctory/tree/suggest/uav-order-all-forms.In game, not yet: the base
63bcca43calone doesn't start in our Wine setup; it dies 8 s in with a stack overflow, so upstreammainwithout the integration PRs never ran here. One run of your head crashed invkCreateComputePipelinesright after translating program2f03a2df10503cef. That was one run, and a probe that creates only that pipeline from both builds is queued to see whether it's deterministic. For an in-game number I'm looking at merging the halves onto my fork's integration as a fallback for exactly the programs the console flow refuses (+42 programs, +1.6 % of compute).AI-assisted (Claude); measured on my machine, no game data shared.
Imported from Marvisak/VIctory. Originally posted by neonbyte1 on 2026-11-28T15:33:51Z.
@chippy01 a correction to the UAV point in my last comment, and it's a bigger finding than I wrote there. The "96 valid samples, no stale read" came from a broken harness: it delivered no group id, so 1,024 groups collapsed onto one console wave. Corrected run on the RTX 5090: one group of 64 / 256 / 1,024 threads, 256 dispatches each, lane 5's half writes a UAV dword and a lane of the other half reads it later in program order:
The write itself lands every time (0 slots left unwritten). But with the halves as emitted (0
dx.op.barrier), the other half's later read sees the old value every time. On the console that's program order inside one wave. For comparison, the console flow showed up to 53 % stale reads for the same pattern before the UAV-fence fix in #439/#3683. The fix shape (a meeting with a UAV fence before an access that conflicts with an earlier one, only where such a conflict exists) is form-independent: https://github.com/neonbyte1/VIctory/tree/suggest/uav-order-all-forms.AI-assisted (Claude); measured on my machine, no game data shared.
Imported from Marvisak/VIctory. Originally posted by ColorMeBoom on 2026-11-28T17:18:49Z.
@neonbyte1 @chippy01 I ported neonbyte1's UAV write-then-read case to this PR's halves. Here is the AMD result, with a true wave64 control on the same card. The UAV ordering gap reproduces on AMD in halves, and one wave64 keeps the order.
RX 5700 XT (Navi 10, RDNA1, 32 and 64 lanes, driver 32.0.21045.29003, Windows 11 26200), head
00a0234. Setup per row:wof each console wave loads a dword only it touches, adds 1 and stores it to its wave's slot, then lanerloads the slot;host_wave32: true) and as one wave64 (false).The three variants differ only in one instruction at the top, which picks the form:
w5 →r6 (same half)w5 →r40w40 →r5row_mirror)v_readlane_b32 s9, v0, 40(a trade, with its meeting)The writer's store landed in every slot in every row, so a stale read means the load came early, not that the store was lost.
What this adds to neonbyte1's 5090 numbers:
WaveSize(64)on the same card keeps it in every row. So it isn't an NVIDIA artifact, and on a 64-lane AMD host it's specific to the 32-lane form.v_readlaneat the top, the halves meet before both accesses, which hides most of the gap. 182 of 4096 reads were still stale at 1024 threads. Like neonbyte1's fix shape, a fence has to sit between the conflicting accesses.host_wave32: false. I ran the same probe onmain63bcca4afterwards: identical, all stale with no lane reads and 0 stale with either lane read. So that part isn't this PR's; it's onmainfor AMD hosts too. Filed as #3766.The probe is an ignored test on top of
00a0234:ColorMeBoom:probe/2633-uav-order(a18c02e). Run it withcargo test -p victory-shader --lib --features host -- --ignored --nocapture local_uav_write_then_read_across_halves;PROBE_RUNSsets the dispatch count. One run each; the 182 needs repeats before it means more than "not zero".AI use: Claude Code (Claude Opus 5.5).
Imported from Marvisak/VIctory. Originally posted by Dathinel on 2026-11-28T17:45:00Z.
A small-card data point: RTX 3050 Laptop GPU, 4 GB (Ampere, 32-lane waves only, driver 610.62), Windows 11, Ryzen 7 7435HS, Rust 1.98.1, head
00a02348.cargo test --locked -p victory-shader --lib emit::halves_tests -- --test-threads=1: 33 passed, 0 failed, 25 s. With--nocapture, on the hardware adapter:emit::halves_random_tests: skipped here ("no hardware adapter runs 64-lane waves"), so it adds nothing from this machine.Not run: the rest of the lib tests, the title, and the UAV write-then-read case @neonbyte1 and @ColorMeBoom describe above (I can run a ported version of it on this card if that helps: say which branch).
Why it matters for this card in the title: on an
f4b48ad-lineage tree here, the programs that still take an approximate form or are refused are what shows in the picture.sr_tracing:CS_DeferredFallbacksAlpha_SkyProbe(b7953a05b189dfc1) stops every exact form at "a first-lane read where not every lane runs" and its approximate form covers hair and beards in dots; the notes are in https://github.com/Dathinel/victory-4gb/issues/44.No game files or captures. Measured and written with AI assistance (Claude Code).
Imported from Marvisak/VIctory. Originally posted by ColorMeBoom on 2026-11-28T18:14:23Z.
@Dathinel It's
ColorMeBoom:probe/2633-uav-order(a18c02e): one ignored test on top of00a0234.It prints a
RESULTline per variant, form, lane pair and group size.PROBE_RUNSsets the dispatch count (default 256). On a 32-lane-only card thewave64form should print "no pipeline; skipped" for the DPP andv_readlanevariants. Thehalvesrows are the ones that matter, especially thev_readlanerow at 1024 threads, where the RX 5700 XT had 182 of 4096 stale. A second GPU family on those rows would show whether a trade's meeting is enough by chance or only usually.AI use: Claude Code (Claude Opus 5.5).
Imported from Marvisak/VIctory. Originally posted by steven-seagull27 on 2026-11-28T20:58:56Z.
I have a working, synthetic-verified fix for masked-loop Wave64 binary64 sums in 32-lane halves (combining #2633's
706c006c+ #2978'sf923b5dc+ #385's90997428, directly addressing the Wave32-halves half of #3501 / #3502): commitfe9318econsteven-seagull27/VIctory(fix/3502-fp64-halves-masked).Root causes addressed
sum64.rs/halves.rs:Lower::sum64previously skippedself.reduction_meets()?, omittedself.wide_and(block, on, c)on the predicate in wave-wide blocks, and did not combine the two 32-lane halves. AddedLower::sum64_halvesto trade(lo, hi)in a single two-word rendezvous (identity(0, 0)=+0.0for missing upper halves), reconstruct viadx.op.makeDouble.f64, add indouble, and bitcast back toi64.lower.rs):Shape::Masked,Shape::Active, andShape::PrefixinLower::shape()also missedself.wide_and(block, on, c).wide.rs,lower.rs,phi.rs): Oncereduction_meets()widens the loop to run wave-wide so neither half can deadlock on early loop exit, the whole-wave section leaves intermediate reduction VGPRs withVal::Missing("a whole-wave section step the simulation does not follow"). When the post-sectionv_mov_b32unconditionally overwrites those VGPRs for every active lane of the wave-wide block,write_placedrefused the write because of the block guard. AddedWide::active_onlytracking so block-mask-only overwrites store the new value while still refusing any read where an inactive lane could observe it (loop exits, back-edge/exit phis,v_readlane/v_writelane, DPPfi: true, and instruction-guarded writes).Synthetic hardware & WARP verification (
fe9318ec)All tests use generated synthetic Wave64 compute shaders (no game data), Windows 11 x64, Rust 1.98.1 MSVC, Windows SDK DXIL validator:
wave64_binary64_sum_in_halves_translates_and_enforces_safety(DXIL + barrier counts + negative escape/readlane checks)wave64_binary64_sum_in_halves_matches_the_console— straight-line (4 groups × 64 lanes)wave64_binary64_sum_in_halves_matches_the_console— masked loop (u64::MAX << 32,u32::MAX,1 << 63,0xA000_0001_0000_0055)waveActiveOp.f64sub-packet bug)wave_wide_32bit_sum_excludes_inactive_lanes_on_every_gpucargo clippy -p victory-shader --all-targets --locked -- -D warnings: cleancargo xtask policy:asset policy: 200 files okvictory-shader --libsuite (skipping pre-existing NVIDIAheap_direct_texture_reads_mark_their_heap_index#2571): 349 passed (only the 3 pre-existing706c006cNVIDIA stride/gather failures remain).To test or cherry-pick onto a #2633 + #2978 branch:
AI-assisted. Synthetic fixtures only.
Imported from Marvisak/VIctory. Originally posted by steven-seagull27 on 2026-11-29T08:26:11Z.
@chippy01 Rebased the masked-loop Wave64 binary64 sum fix onto your latest #2633 head (
00a02348) + #2978 (e854af8d) so it cherry-picks cleanly: commit3ba25486onsteven-seagull27/VIctory(fix/3502-fp64-halves-masked-00a02348; keeping the earlierfix/3502-fp64-halves-maskedbranch intact).Rebase adjustments for
00a02348Lower::shape()wide_andhunk (already covered by27029aff) and matchedsum64.rstoself.wide_and(self.cur_ir, on, c).Wide::active_onlywithhalves::Literal(478848cc/27029aff): block-mask-only overwrites of section scratch VGPRs inwrite_placeddo not callask_literalprematurely, while any refused inactive-lane observation forwardsunfollowedtoask_literalso 32-bit literal section replay is preserved. Addedpermlanefetch-inactive (v.opsel & 1) alongside DPPfi: true.sum64_halvesusestrade(c, &[(lo, 0), (hi, 0)])and automatically inherits00a02348's borrowed-slot handling for full 32 KiB LDS.Synthetic verification (
3ba25486, Windows 11 x64, Rust 1.98.1 MSVC)wave64_binary64_sum_in_halves_translates_and_enforces_safety(DXIL validation, barrier counts, 48 & 64-thread negative escape/readlane checks)wave64_binary64_sum_in_halves_matches_the_console— RTX 5080 (Wave32 halves)wave64_binary64_sum_in_halves_matches_the_console— App-local WARP 1.0.22 (VICTORY_WARP=1)wave_wide_32bit_sum_excludes_inactive_lanes_on_every_gpu— RTX 5080cargo test --locked -p victory-shader --lib -- --test-threads=1 emit::halves_tests a_whole_wave_binary64_sumhalves_tests+ both #2978valu_testsbinary64 sums)cargo clippy --locked -p victory-shader --all-targets -- -D warningscargo xtask policyasset policy: 199 files okFetch / cherry-pick (onto #2633
00a02348+ #2978e854af8d)AI-assisted. Synthetic fixtures only.
Imported from Marvisak/VIctory. Originally posted by TaynanGT on 2026-11-29T11:25:38Z.
Thanks for the follow-up on the first-lane fallback and the full-LDS borrowed-slot case, and thanks to steven-seagull27 for the rebased binary64 tests. The masked-loop and straight-path results on RTX 5080 and WARP are useful. I'll keep those synthetic results separate from matched title runs on the updated head.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.