You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(agc): name the shader and V# when a draw is refused for a buffer descriptor type - #5897
Stray (PPSA02101, #5894, and PPSA02100, #5879) stops in its opening cinematic on
[videoout] presentation failed: buffer descriptor uses an unsupported type
The message names neither the shader nor the descriptor. Both reporters had to add a local print at the throw in materializeTables to get them, and APS5_DUMP_SHADERS writes nothing for this case: draws dump a request only when preparation fails (PrepareShaderWithDiagnostics), and this throw comes later, while the draw's resources are captured. Compute dispatches already put compute shader 0x... and the dump path in front of the same errors.
materializeTables: the error names the buffer slot and the four V# words, e.g. buffer descriptor uses an unsupported type (buffer 0 V# 20722c00 c3800000 001dc13f a1b00fac), like the image interface error does with its T#.
Driver::materializeDrawStage: a failure in the stage's resource capture or materialization is rethrown as shader 0x<address> stage <n>: <reason>, the prefix PrepareShaderWithDiagnostics uses. With APS5_DUMP_SHADERS set, the stage's request is dumped and its path goes in the prefix too.
agc_driver_buffer_descriptor_runtime checks that the refused vector read names buffer 0 and its words.
New agc_driver_draw_unsupported_buffer_type: a draw whose pixel shader loads through a V# with Stray's word 3 (0xa1b00fac, type 2) fails with the pixel shader's address and stage and the V# words.
No behaviour changes: the same descriptors are refused as before, only the message is longer.
Title. I do not have Stray. With this PR the next report of #5894 or #5879 carries the shader address, the descriptor and, with APS5_DUMP_SHADERS=1, a .req dump without a local patch.
Tested
Linux (Bazzite 44, GCC 16.2.1, Ninja, Release, -DBUILD_TESTING=ON), RX 7700 XT (RADV), based on main84b01f9cd:
Full build and ctest: 1140 of 1162 pass and 20 are skipped (the display tests, no display in that shell). agc_driver_tessellation segfaults on unchanged main here, and agc_host_import_sparse fails on main too (test(agc): drop a shared range's backing when the range goes away #5759 fixes that test).
agc_driver_draw_unsupported_buffer_type fails without the DrawCapture.cpp change (the message has no shader 0x... stage 5), and agc_driver_buffer_descriptor_runtime fails without the ResourceMaterializer.cpp change (no (buffer 0 V# ...)).
Under APS5_DUMP_SHADERS=1 the new test still passes and writes shader_<address>.req for the pixel shader.
tools/check_conventions.py --base upstream/main passes, and tools/pr_overlap.py reports no overlap. Windows and macOS were not built here.
Checklist
Based on current main; no other open PR implements the same functions
One topic per PR; follow-ups go in a new PR
No comments in code except technical debt
Unimplemented paths throw; no silent stubs added
No notes, investigation .md files or images added to the repository
No new third-party code
Generic behaviour, not specific to one title
Depends on: none
Unblocks: none (diagnostics for PPSA02101 and PPSA02100)
@oneandonlydean rebased onto mainb9d9ec605 (head 7af296130) after #6093. Its stageCapture.capture = capture sat on the line this PR wraps in try; it now follows the wrapped Materialize call, and the PR's changed lines are otherwise the same. #6093's stage data hits patch words into a cached result without materializing, so they don't reach this throw.
Full build and ctest here: 1188 of 1212 pass and 21 are skipped (display tests). agc_driver_tessellation, application_heap_lazy and agc_host_import_sparse fail on unchanged main here too. agc_driver_draw_unsupported_buffer_type, agc_driver_buffer_descriptor_runtime and agc_driver_draw_cache_reuse pass.
Since #5894 was closed as a duplicate: the Stray stop in #5879 throws from the capture call (shaderMemory.Capture(invocation), which materializes), so the wrapper covers both calls, and a run with this PR names the shader there.
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
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
Stray (PPSA02101, #5894, and PPSA02100, #5879) stops in its opening cinematic on
The message names neither the shader nor the descriptor. Both reporters had to add a local print at the throw in
materializeTablesto get them, andAPS5_DUMP_SHADERSwrites nothing for this case: draws dump a request only when preparation fails (PrepareShaderWithDiagnostics), and this throw comes later, while the draw's resources are captured. Compute dispatches already putcompute shader 0x...and the dump path in front of the same errors.materializeTables: the error names the buffer slot and the four V# words, e.g.buffer descriptor uses an unsupported type (buffer 0 V# 20722c00 c3800000 001dc13f a1b00fac), like the image interface error does with its T#.Driver::materializeDrawStage: a failure in the stage's resource capture or materialization is rethrown asshader 0x<address> stage <n>: <reason>, the prefixPrepareShaderWithDiagnosticsuses. WithAPS5_DUMP_SHADERSset, the stage's request is dumped and its path goes in the prefix too.agc_driver_buffer_descriptor_runtimechecks that the refused vector read names buffer 0 and its words.agc_driver_draw_unsupported_buffer_type: a draw whose pixel shader loads through a V# with Stray's word 3 (0xa1b00fac, type 2) fails with the pixel shader's address and stage and the V# words.No behaviour changes: the same descriptors are refused as before, only the message is longer.
Title. I do not have Stray. With this PR the next report of #5894 or #5879 carries the shader address, the descriptor and, with
APS5_DUMP_SHADERS=1, a.reqdump without a local patch.Tested
Linux (Bazzite 44, GCC 16.2.1, Ninja, Release,
-DBUILD_TESTING=ON), RX 7700 XT (RADV), based onmain84b01f9cd:ctest: 1140 of 1162 pass and 20 are skipped (the display tests, no display in that shell).agc_driver_tessellationsegfaults on unchangedmainhere, andagc_host_import_sparsefails onmaintoo (test(agc): drop a shared range's backing when the range goes away #5759 fixes that test).agc_driver_draw_unsupported_buffer_typefails without theDrawCapture.cppchange (the message has noshader 0x... stage 5), andagc_driver_buffer_descriptor_runtimefails without theResourceMaterializer.cppchange (no(buffer 0 V# ...)).APS5_DUMP_SHADERS=1the new test still passes and writesshader_<address>.reqfor the pixel shader.tools/check_conventions.py --base upstream/mainpasses, andtools/pr_overlap.pyreports no overlap. Windows and macOS were not built here.Checklist
main; no other open PR implements the same functions.mdfiles or images added to the repository