Repository navigation
fix(agc): move periodic profiling writes off GPU workers - #798
Merged
oneandonlydean merged 2 commits intoOct 6, 2026
Merged
Conversation
9 tasks done
|
Other open pull requests touch the same code. Merging one will break the other, or both implement the same thing. If this one builds on them, list them in Depends on.
|
This was referenced Oct 21, 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
Periodic AGC profiling reports currently write to
stderron GPU queue and presentation threads, sometimes while holdingGuestMemory::GpuMutex. WithAPS5_PROFILE_DRAW=1, a slow diagnostic destination can delay submitting otherwise ready GPU work.Format and copy periodic profiling output into a bounded 4 MiB queue and write it from a separate thread. The writer batches output, drains accepted chunks on shutdown, propagates write failures, and explicitly reports dropped chunks if the destination falls behind. The capacity includes in-flight output. Existing report formats and profiling switches are retained; error and assertion reporting remains synchronous.
Tested
--repeat until-fail:3; all three PR checks passed.agc_profile_output,agc_register_command_tests,agc_shader_disk_cache,agc_write_tracking,agc_driver,agc_driver_pm4,agc_driver_graphics,agc_driver_flat_store,agc_driver_image_store_packed,agc_driver_lds_atomics.Known limits: another interactive run still timed out at frame 112 and switched to the CPU scaler. This PR removes measured diagnostic-output stalls, but does not claim to resolve every frame timeout, improve FPS, or eliminate Vulkan instance/device initialization cost. A pre-existing UCRT invalid-parameter diagnostic also occurs during startup and remains unchanged.
Checklist
main(b10f5701); no other open PR implements the same changeIn-game screenshots
Fresh captures from the final implementation in the separate DOOM integration. The interactive session ran for 213 seconds, completed more than 7,400 dispatches and reported no frame timeouts, CPU fallback or dropped profiling chunks.