Repository navigation
fix(libSceAgcDriver): SPI_PS_INPUT_CNTL registers start at their clear-state value - #2128
Merged
oneandonlydean merged 1 commit intoOct 10, 2026
Conversation
…r-state value A title that never writes SPI_PS_INPUT_CNTL_0 relies on its clear-state value 0, but the register was absent from the initial context, so every draw of a pixel shader with interpolants was rejected with "missing register at DWORD 0x191". All 32 SPI_PS_INPUT_CNTL registers now start at 0, as in the GFX10 clear state, both initially and after CLEAR_STATE. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
oneandonlydean
added a commit
to oneandonlydean/AnyPS5
that referenced
this pull request
Oct 10, 2026
oneandonlydean
added a commit
to oneandonlydean/AnyPS5
that referenced
this pull request
Oct 10, 2026
SleglJan
pushed a commit
to SleglJan/AnyPS5
that referenced
this pull request
Oct 10, 2026
…ps-input-cntl-clear-state fix(libSceAgcDriver): SPI_PS_INPUT_CNTL registers start at their clear-state value
12 tasks done
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
A title that never writes
SPI_PS_INPUT_CNTL_0(context register0x191) relies on its clear-state value, 0. The driver's initial context did not contain theSPI_PS_INPUT_CNTLregisters. As a result, every draw of a pixel shader with interpolants (SPI_PS_IN_CONTROL.NUM_INTERP> 0) was rejected when[DecodePixelStageInfo](https://github.com/boykopovar/AnyPS5/blob/main/core/libs/prx/libSceAgcDriver/Graphics/src/ShaderInputState.cpp)read register0x191.Planet Coaster (PPSA01736) writes
SPI_PS_INPUT_CNTL_1..31(0x192..0x1b0, values 1..31) and leavesSPI_PS_INPUT_CNTL_0at its reset value. Without this change it stops at its first UI and video draws:On older main the same draws were skipped instead (
[gpu] skipped draw: AGC graphics: missing register at DWORD 0x191), and every presented frame was black.All 32
SPI_PS_INPUT_CNTLregisters (0x191..0x1b0) now start at 0 in[InitialContextRegisters](https://github.com/boykopovar/AnyPS5/blob/main/core/libs/prx/libSceAgcDriver/Execution/include/QueueState.hpp). The initial context andCLEAR_STATEalready share that table.Source for the value: the GFX10 clear state in amdgpu,
clearstate_gfx10.hlines 427–458. Ingfx10_SECT_CONTEXT_def_2, whose extent starts at0xa0d8,SPI_PS_INPUT_CNTL_0is entry 185. That is register0xa191, the driver's0x191. It andSPI_PS_INPUT_CNTL_1..31are all0x00000000.Tested
Windows 11, MinGW-w64 15.2.0, RTX 3060.
agc_driver_graphics_tests: a fresh queue state whose pixel stage has two interpolants and writes onlySPI_PS_INPUT_CNTL_1decodesCNTL_0as 0 andCNTL_1as written.ClearContext(CLEAR_STATE) resets all 32 to 0. Without the change, the test fails withmissing register at DWORD 0x191.tools/check_conventions.py --base origin/mainpasses.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed in TechnicalDebt.mdfiles or images added to the repository