Ratchet & Clank: Rift Apart: a registered pixel shader is drawn with DB_SHADER_CONTROL=0 while its header sets 0x20601 #2621

Closed
opened 2026-10-10 08:28:57 +00:00 by EdouardSence · 2 comments
EdouardSence commented 2026-10-10 08:28:57 +00:00 (Migrated from github.com)
Contributor

Imported from boykopovar/AnyPS5. Originally posted by EdouardSence on 2026-10-10T08:28:57Z.


What

Ratchet & Clank: Rift Apart (PPSA01474) stops about 64 s in:

AGC driver: prepared shader artifact is missing for the requested static ABI: address=74731224064 stage=5 wave=64 pushOffset=0 pushCapacity=128 preparedLayouts= [0,128] [0,0]

The pixel shader at 0x116653fc00 is registered, and its header's context registers set DB_SHADER_CONTROL = 0x20601. The variant prepared at registration has depthExportEnable = 1 and executeOnNoop = 1. The title draws with it under two different context values:

draws DB_SHADER_CONTROL in the context at draw depthExportEnable executeOnNoop
first ones 0x20601 1 1
a later draw 0x0 0 0

The later request's static key differs from the prepared one only in those two fields (positions 23 and 26 of BuildInterface's key). The layout, the user data and the code are the same. PreparedAtUse returns false for a registered, non-deferred shader, so the draw throws.

I can't say who writes 0x0; the log doesn't show which packet changes the register between the two draws. If the GPU really runs the draw with that context value, the host shader for that draw needs the variant without Z export. So this is the case @XairRrR raised on #1902: a registered shader drawn under state its registration did not prepare. fisherjoey noted there that it is a policy decision for #1836's follow-up.

Measured

main 3539d1ce with #1988 reverted (otherwise the title crashes earlier, #2603). Linux, GCC, Release, RX 9070 XT, RADV / Mesa 26.2.4, headless gamescope, scripted input. The key comparison and the register values come from temporary local logging in SourceHandleFor and Driver::decodeDraw, which isn't part of any branch.

  • About two runs in three reach this stop.
  • The other runs stop earlier on AGC graphics: color views of several array slices are unsupported (#2102).
  • Rise of the Ronin (PPSA04540) stops on the same message with stage=1 on a stack of open PRs. I haven't checked whether it is the same cause.

How should a registered shader be handled when the draw's context differs from the header's registers in fields that change the recompiled shader? Prepare that variant at draw, or something else? I can test any candidate on this title.

Tested and written by Claude (AI assistant) on a contributor's machine.

<!-- greyfinch-sync:boykopovar/AnyPS5:issue:5789582377 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/issues/2621). Originally posted by [EdouardSence](https://github.com/EdouardSence) on 2026-10-10T08:28:57Z. --- ### What Ratchet & Clank: Rift Apart (PPSA01474) stops about 64 s in: ``` AGC driver: prepared shader artifact is missing for the requested static ABI: address=74731224064 stage=5 wave=64 pushOffset=0 pushCapacity=128 preparedLayouts= [0,128] [0,0] ``` The pixel shader at `0x116653fc00` is registered, and its header's context registers set `DB_SHADER_CONTROL = 0x20601`. The variant prepared at registration has `depthExportEnable = 1` and `executeOnNoop = 1`. The title draws with it under two different context values: | draws | `DB_SHADER_CONTROL` in the context at draw | `depthExportEnable` | `executeOnNoop` | |---|---|---|---| | first ones | `0x20601` | 1 | 1 | | a later draw | `0x0` | 0 | 0 | The later request's static key differs from the prepared one only in those two fields (positions 23 and 26 of `BuildInterface`'s key). The layout, the user data and the code are the same. `PreparedAtUse` returns false for a registered, non-deferred shader, so the draw throws. I can't say who writes `0x0`; the log doesn't show which packet changes the register between the two draws. If the GPU really runs the draw with that context value, the host shader for that draw needs the variant without Z export. So this is the case @XairRrR raised on #1902: a registered shader drawn under state its registration did not prepare. fisherjoey noted there that it is a policy decision for #1836's follow-up. ### Measured `main` 3539d1ce with #1988 reverted (otherwise the title crashes earlier, #2603). Linux, GCC, Release, RX 9070 XT, RADV / Mesa 26.2.4, headless gamescope, scripted input. The key comparison and the register values come from temporary local logging in `SourceHandleFor` and `Driver::decodeDraw`, which isn't part of any branch. - About two runs in three reach this stop. - The other runs stop earlier on `AGC graphics: color views of several array slices are unsupported` (#2102). - Rise of the Ronin (PPSA04540) stops on the same message with `stage=1` on a stack of open PRs. I haven't checked whether it is the same cause. How should a registered shader be handled when the draw's context differs from the header's registers in fields that change the recompiled shader? Prepare that variant at draw, or something else? I can test any candidate on this title. *Tested and written by Claude (AI assistant) on a contributor's machine.*
EdouardSence commented 2026-10-10 13:45:48 +00:00 (Migrated from github.com)
Author
Contributor

Imported from boykopovar/AnyPS5. Originally posted by EdouardSence on 2026-10-10T13:45:48Z.


Retested on main b5f5362d3: the stop is unchanged, same shader 0x116653fc00, stage=5, about 55 s in. To get there it needs #861 reverted (#2704) and #2102 bypassed. For #2102 I used a local probe that drops the color views of several array slices refusal and renders into the first slice of the view only, which is wrong and only meant to see further.

Data for the policy question, from one more local probe (not proposed as is): PreparedAtUse returning true for a registered, non-deferred pixel shader, so the DB_SHADER_CONTROL = 0 variant is prepared at draw.

  • Only this one shader takes that path in the run: it is logged once, for 0x116653fc00.
  • The title then runs the full 240 s with no stop, no crash and no GPU reset. Frames: the intro and the Insomniac logo render; from about 65 s to the end the presented image is black while the GPU keeps working. That black screen may well come from the slice-0 probe, since the title is drawing into layered targets at that point, so I would not read anything into it for this issue.

So on this title, preparing that one variant at draw is enough to move past #2621. I can rerun with any candidate.

Tested and written by Claude (AI assistant) on a contributor's machine.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6098134473 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/issues/2621#issuecomment-6098134473). Originally posted by [EdouardSence](https://github.com/EdouardSence) on 2026-10-10T13:45:48Z. --- Retested on main `b5f5362d3`: the stop is unchanged, same shader `0x116653fc00`, `stage=5`, about 55 s in. To get there it needs #861 reverted (#2704) and #2102 bypassed. For #2102 I used a local probe that drops the `color views of several array slices` refusal and renders into the first slice of the view only, which is wrong and only meant to see further. Data for the policy question, from one more local probe (not proposed as is): `PreparedAtUse` returning true for a registered, non-deferred pixel shader, so the `DB_SHADER_CONTROL = 0` variant is prepared at draw. - Only this one shader takes that path in the run: it is logged once, for `0x116653fc00`. - The title then runs the full 240 s with no stop, no crash and no GPU reset. Frames: the intro and the Insomniac logo render; from about 65 s to the end the presented image is black while the GPU keeps working. That black screen may well come from the slice-0 probe, since the title is drawing into layered targets at that point, so I would not read anything into it for this issue. So on this title, preparing that one variant at draw is enough to move past #2621. I can rerun with any candidate. *Tested and written by Claude (AI assistant) on a contributor's machine.*
EdouardSence commented 2026-10-11 13:15:48 +00:00 (Migrated from github.com)
Author
Contributor

Imported from boykopovar/AnyPS5. Originally posted by EdouardSence on 2026-10-11T13:15:48Z.


Fixed on main a11c8f7f by #2917. Ratchet & Clank: Rift Apart (PPSA01474) now prepares this shader at use, once:

Shader 0x116653fc00 stage 5 has no artifact prepared at registration for the state of this draw or dispatch; preparing it at use

The title then runs the whole 120 s run without an abort, with no local probes or reverts (Linux, RX 9070 XT, RADV). The Insomniac Games logo renders at about 25 s, and the screen is black after that. That is a separate problem, and the same picture my probe gave above. The SIGSEGV of #2704 / #2687 and the #2907 fault I reported at about 16 s don't happen in this run either. Closing.

Tested and written by Claude (AI assistant) on a contributor's machine.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6109416474 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/issues/2621#issuecomment-6109416474). Originally posted by [EdouardSence](https://github.com/EdouardSence) on 2026-10-11T13:15:48Z. --- Fixed on `main` a11c8f7f by #2917. Ratchet & Clank: Rift Apart (PPSA01474) now prepares this shader at use, once: ``` Shader 0x116653fc00 stage 5 has no artifact prepared at registration for the state of this draw or dispatch; preparing it at use ``` The title then runs the whole 120 s run without an abort, with no local probes or reverts (Linux, RX 9070 XT, RADV). The Insomniac Games logo renders at about 25 s, and the screen is black after that. That is a separate problem, and the same picture my probe gave above. The SIGSEGV of #2704 / #2687 and the #2907 fault I reported at about 16 s don't happen in this run either. Closing. *Tested and written by Claude (AI assistant) on a contributor's machine.*
Sign in to join this conversation.
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
boykopovar/AnyPS5#2621
No description provided.