tests: treat SH 0x2/0x3 as live PS user-data address slots #991
No reviewers
Labels
No labels
bug
documentation
duplicate
enhancement
GPU
GUI
help wanted
question
Shaders
Video
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/KytyPS5--KytyPS5!991
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/991/head"
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?
@theantipopau on GitHub · 2026-10-02 23:39 UTC · original
theantipopau:pm4-user-data-slots→main· +12 −5 · 1 files · 1 commits · closed without mergingProblem
shader_recompiler_compute_testsaborts on currentmainat:Exit code 127 after only 33 checks — the rest of the suite never runs.
Cause: #964 ("Improve Hades II compatibility") registered handlers at SH offsets
0x2/0x3(SPI_SHADER_USER_DATA_ADDR_LO_PS/HI_PS) because Hades II's indirectSET_SH_REG_INDIRECTtraffic writes the PS user-data address there.CheckPm4NativeTargetGeometryRegisters, added much earlier in1df06e23, still lists0x002/0x003among the "removed GCN register holes" that must have no handler, so the two changes now contradict each other.CI never notices:
.github/workflows/build.ymlonly ctestsaudio_out2_port|ime_dialog|virtual_memory_allocation, and the #964 PR body itself notes automated tests were not run for that branch.Fix
0x002/0x003fromlegacy_shader_slots(19 → 17 entries) and document why they stopped being holes.g_hw_sh_funcandg_hw_sh_indirect_funckeep handlers at those offsets, so the slots are still guarded — just for the opposite reason (they must be handled, not ignored).The remaining 17 slots, the depth/color legacy holes, and the
0x0cb..0x0ebrange are unchanged, so the dispatch-table regression check keeps its original strength for genuinely removed GCN registers.Testing (Windows, local build of
shader_recompiler_compute_tests)main(e317465d)Pm4NativeTargetGeometryafter 33 checksbae42bcf)Pm4NativeTargetGeometry ok, 62 checks pass before this machine's knownD24_UNORM_S8_UINTdriver rejection (that one is fixed by #930)VectorFractF16CapturedAndEdgesreadback case (hardware-captured rounding, unrelated to PM4 dispatch)Runtime diagnostics during the investigation confirmed
sh[0x002] handler=1 indirect=1andsh[0x003] handler=1 indirect=1— both tables intentionally occupied after #964.🤖 Generated with Codebuff
@theantipopau on GitHub · 2026-10-04 17:57 UTC · original
Superseded by upstream: current
mainalready has all of this, so rebasing leaves no meaningful delta.legacy_shader_slotsonmainis already the 17-element array without0x002u/0x003u.native_ps_address_slots_are_handled, which checksg_hw_sh_func[Pm4::SPI_SHADER_USER_DATA_ADDR_LO_PS]/..._HI_PS(both direct and indirect) — andSPI_SHADER_USER_DATA_ADDR_LO_PS = 0x2,SPI_SHADER_USER_DATA_ADDR_HI_PS = 0x3inpm4.h, i.e. exactly the literal0x002u/0x003ucheck this PR added, now included in thelegacy register holesRequire.Only the extra comment lines referencing #964 would remain, which are not worth a standalone change. Closing.
Pull request closed