Repository navigation
Conversation
|
Independent test run on commit
AI use: Antigravity (Gemini 4 Neon) ran clippy/tests locally and wrote this report. |
|
Merged onto main 90228a7 and ran No change: every failure count is the same as main, and no new reason appears. So no regression in translation. What this PR changes at run time isn't covered by this check. |
|
RTX 3070 Ti 8 GB (32-lane waves), driver 621.x, Windows 11, fork With #83 on top, the driver refuses six more compute pipelines with
Reproduced offline in seconds: AI-assisted (Claude Code); counts and hashes only, nothing from the game. |
…e effects In `ir::without_skips`, removing `s_cbranch_execz` causes waves with `EXEC == 0` to fall through and execute the skipped region `inside`. Previously `skipped()` exempted `Reg::S(126 | 127)` (`EXEC_LO`/`EXEC_HI`) from join-phi checks without verifying that `inside` keeps `EXEC == 0`, and did not check `inside` for EXEC-independent scalar side effects. 1. Reject skipping regions containing EXEC-independent scalar side effects (`s_store_*`, `s_buffer_store_*`, `s_scratch_store_*`, `s_atomic_*`, `s_buffer_atomic_*`, `s_sendmsg`, `s_sendmsghalt`, `s_barrier`, `s_round_mode`, `s_denorm_mode`). 2. Compute a least fixpoint of values inside `inside` that may be nonzero when `EXEC` enters as `0` (seeded with external values other than the skip branch's own `EXEC` dwords), propagating zero through narrowing `v_cmpx_*`, `s_and*`/`s_andn2*`, `s_mov_b32`/`s_mov_b64`, and pure whole-wave sections (`s_or_saveexec`/`s_nand_saveexec` paired with an exact full-width restore). Reject if any `EXEC` write or phi inside `inside` (outside a pure whole-wave section) or incoming `EXEC` phi at `target` can become nonzero, or if a live VGPR phi at `target` takes a value written inside a whole-wave section. 3. Add synthetic unit tests verifying outer-EXEC restores, `s_or_b64`/`s_andn2_b64` EXEC widening, inner narrowing (still allowed), `s_sendmsg`, `s_barrier`, and `s_buffer_store_dword`.
|
Tested on Windows 10 (19044), RTX 3080 (32-lane waves), title build 1.0.2.1, release + diagnostics. With this empty-EXEC guard plus #11 (restore parked lane-mask pairs a few instructions apart) and #77 (v_fma_mixlo/mixhi over an f16 first interpolation half), the Applying #11 alone previously removed world geometry for us; with this guard the geometry is preserved. So the guard appears necessary alongside #11's restore forward-search — the combination is what made the irradiance cache usable on this card. The remaining clothes/material lighting issue looks separate (the deferred-material pixel programs #77 addresses). Thanks — useful fix. |
…masked vector writes Integrate the fixed-point analysis from fxceless#443. A write through an empty mask carries a previous full-wave temporary into its destination. Account for that carry and for proven all-lane full-dword overwrites when checking join values.
|
@YeokiNoewChi I reproduced the regression on an RTX 5070 (driver 610.88). All six programs validated on both revisions. Native pipeline creation was 6/6 on the original parent and 0/6 on 7ed853a. I updated this branch at 4bf38e3. It retains the empty-EXEC store regression, reuses the region analysis from #443, and checks whether full-wave temporary values survive a later masked write. Native pipeline creation now passes 6/6 with approximate local-wave lowering disabled. The 14 lighting pipelines in #62 also validate and create successfully. I did not dispatch the six programs in this check. I’ve left this in draft for independent testing of rendered output and broader shader coverage. Thanks for catching the difference between DXIL validation and actual pipeline creation. |
|
Full compute comparison. I compared the emitted DXIL for all 2,689 compute containers in the local input index with the same 32-lane host settings. Both revisions emitted 2,680 programs. Exactly 20 outputs changed. All 20 validated on both builds. Main created all 20 native pipelines on the RTX 5070, and the draft created 16. The four regressions cover raster and ray-traced shadow classification. The original six and the separate fourteen lighting cases all passed on both builds. This remains blocked on the four native failures. Keeping this in draft. A checkpoint run exposed two additional compute pipelines that regress between fork main Both new failures have an empty-EXEC branch to program termination that skips workgroup barriers. Main's translator removes that branch and emits wave32. This branch preserves it and emits wave64, which the adapter rejects. RDNA2 permits an early-exiting wave to leave the remaining waves to synchronize. Any fix here needs to preserve that behavior across the barriers and loops. AMD RDNA2 ISA, section 4.3 The visual difference is real. At the same stationary jail window, the bright orange highlight across the back of the character's head became dark. The median frame-time reading over 57 seconds was 455 ms on main and 415 ms on this branch at about 5,000 draws/frame in each. That is one ordered comparison on one GPU. |
|
Updated the draft to Checkpoint follow-up: the repaired head and main both reached the interactive cell and responded to movement. The earlier dark-hair difference disappeared on the repaired head. Both logged the same six unrelated native compute refusals. The PR description records the comparison and its limits. |
Back-port from Belobug fxceless#83 (same rule as upstream #2406). Hardware tests raw VCC; masking with EXEC flips a branch when only inactive-lane bits are set. Regression test included.
An empty console wave can branch past a block that restores an earlier EXEC mask and writes to shared memory. Removing that branch lets the store run. The synthetic regression covers both a branch to an early return and a branch to a join.
Depends on #443 by @AscilCH, included here with its original commit. The follow-up at 4bf38e3 applies its analysis to early returns as well as ordinary skips. A masked vector write can carry a previous full-wave temporary into a join. The analysis follows that value through masked writes and phis. A plain full-width conditional select or cross-row permutation can discard the old destination when all lanes are active and none of its explicit sources reads that destination.
The follow-up at 26c9647 handles a terminal empty-wave branch over workgroup barriers. A retired RDNA2 wave drops out of subsequent rendezvous. The new check permits it to walk the region with empty EXEC when every wave reaches the same gate, all paths visit the same barriers exactly once in order, and loops have bounded scalar counters. The original checks on side effects and EXEC restores still apply. AMD RDNA2 ISA, section 4.3
Verification on Windows 11, RTX 5070, driver 610.88
310c6eband previous draft4bf38e3. Each revision emitted DXIL for the same 2,680. This follow-up changes exactly four outputs from the previous draft. All four match main byte-for-byte and use the regular 32-lane translation.The current head and main both reached the interactive jail checkpoint and responded to the same movement sequence on the RTX 5070. Both completed the observation with no host GPU failure and the same six unrelated compute pipeline refusals. None of the four regressions above appeared in either refusal set. At the prison window, both runs showed orange light on the character’s hair. The dark-hair image from the previous draft did not persist after repair. The fence also varied across repeated launches of the same main binary. Different geometry was still streaming during the timed window, so this comparison establishes neither a frame-rate gain nor visual parity.
AI-assisted implementation and testing. The public test fixtures are handwritten. Thanks to @Xeltax for narrowing the original lighting example and @YeokiNoewChi for reporting the native pipeline regression.