Repository navigation
Conversation
Every 8- and 16-bit BDA store and the unaligned path of every 32-bit store emitted one get_bda_write_pointer lookup and one note_bda_write per byte at the store site, five write lookups per 32-bit store. They now call write_bda_bytes, which loops over the bytes and does, per byte and in order, the same lookup, the store when it is mapped and the write note, so faults are recorded exactly as before. On an RTX 3060 the agc_driver_flat_store binaries shrink from 496,256 to 138,240 bytes (wave32) and from 928,384 to 225,152 bytes (wave64), and the cold run from 19.7 s to 2.2 s.
note_bda_write unrolled its 8 compare-exchange probes, and drivers inline it at every BDA store and atomic. The probes now run in a loop that tries the same slots in the same order and stops at the same slot, so the recorded pages and the overflow flag are unchanged. With the byte store helper, the agc_driver_flat_store binaries on an RTX 3060 go from 138,240 to 75,648 bytes (wave32) and from 225,152 to 130,560 bytes (wave64), and the cold run from 2.2 s to 1.2 s.
… path The declaration, the state field and the definition of write_bda_bytes now sit next to EmitBdaStore and the other BDA write functions instead of next to the dword read functions, which boykopovar#1267 extends at the same lines. No change to the emitted code.
note_bda_write ran a device-scope compare-exchange on every probe, also when the slot already held the page. The table lives in host-visible memory, so each BDA store paid an atomic across PCIe, and nearly every store hits a page an earlier store noted. Load the slot first and only compare-exchange when it does not hold the page. The slots probed, the pages recorded and the overflow report are unchanged. DOOM (PPSA99666) presents through a compute kernel that stores about two million pixels through raw pointers per frame: 248 ms per dispatch before, 8.1 ms after, on an RTX 5070 Ti. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Integrate upstream boykopovar#1265 by popcoder565 and boykopovar#1280 by Scott Schuster while preserving their original history. Emit shared looping byte-write helpers and written-page probes, and skip compare-exchange when a slot already holds the page. Add focused shader and full integration validation on both hosts. AI-assisted integration and validation: yes.
This was referenced Oct 9, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Fork integration of two existing shader-recompiler performance changes:
Original commit history and authorship are retained. The integration applies those four source commits to the restored current-main tree; it does not claim new instruction semantics or console hardware measurements.
These changes directly address the oversized BDA-store shaders involved in the two Linux test timeouts. They also reduce repeated atomics against host-visible fault-tracking memory on discrete GPUs. The upstream descriptions include NVIDIA, AMD and Intel measurements for boykopovar#1265, and NVIDIA measurements for boykopovar#1280; those measurements belong to the original contributors and have not been reproduced on physical hardware here.
Adds Linux/Windows validation that builds and runs the affected BDA store/atomic tests with the existing 30-second limit, then builds the full project and guest libraries and runs the full suite. Linux enables SPIRV-Tools validation and requires the Vulkan software driver.
Tested
The targeted CI test phase completed successfully on Linux and Windows in run 37991651105. Linux then built the full project and all guest libraries and completed the full 523-test suite successfully, with explicitly reported skips for unavailable facilities. Windows also built the full project and guest libraries. Its full 514-test suite had one failure, patched_libraries: 15 PRX libraries loaded and 101 failed because the old test environment selected the wrong C++ runtime. All other tests passed or were explicitly skipped. This branch does not yet contain the separate CMake runtime-selection fix. Windows runners can explicitly skip tests requiring an unavailable GPU; the full Linux phase requires the Vulkan software driver. Earlier Linux baseline timing was 51.03 seconds for global_vcc_base and 67.98 seconds for flat_store; the earlier integration run failed their 30-second limits. On the cold targeted Linux run, flat_store completed in 26.15 seconds and global_vcc_base in 16.69 seconds. Their subsequent full-suite runs completed in 4.34 and 2.71 seconds, respectively; those later timings can benefit from driver cache and are not claimed as cold results. Limits and test coverage have not been relaxed.
Combined follow-up validation
The combined review branch integration/project-completion at commit 76f71f8 includes #8, #9, #10 and #11 plus the separately developed Windows runtime fixes. Results below apply to that combined commit; the individual PR heads retain the baseline results above.
Commercial games, a physical discrete GPU, PCIe performance and console execution have not been tested. The scanner's export-body counts do not establish semantic completeness: encrypted SELF conversion, complete Tempest audio, predictive GPU memory management and full Mesh/Ray Tracing support remain outside the implemented changes.
Checklist
Owner-requested fork integration of existing upstream implementations, with original attribution.