Skip to content

fix(agc): add opt-in ordered submission completion events - #2585

Closed
ddrsilva wants to merge 1 commit into
boykopovar:mainfrom
ddrsilva:fix/submission-eop
Closed

ddrsilva wants to merge 1 commit into
boykopovar:mainfrom
ddrsilva:fix/submission-eop

Conversation

@ddrsilva

Copy link
Copy Markdown

What

Minecraft Preview can stop producing frames while waiting for a graphics event after submissions with no interrupt-requesting packet. This draft adds an experimental, title-independent fallback enabled with APS5_IMPLICIT_SUBMISSION_EOP=1; the default behavior is unchanged.

For each successful non-suspend submission without an executed explicit interrupt, the worker registers one event after recorded GPU work. Pending work is submitted and the event runs through the recorder's completion path, rather than signaling when CPU packet processing ends. With no GPU work outstanding it signals immediately. Explicit interrupts retain their packet behavior and suppress the fallback, including across REWIND tails. Tracking is scoped to the submission rather than a persistent thread flag.

Console behavior is not established: this is an opt-in compatibility proposal, not a claim that all console submissions implicitly interrupt. The shared recorder can conservatively delay the event behind another queue's work. These limits are recorded in TechnicalDebt.

Related investigation: #1277 . Other boot compatibility changes, shader fallback, mouse changes and performance experiments from that overlay are deliberately outside this PR. Related open PRs #1201 and #1745 address draw commits and flip pacing, not this implicit-event fallback; integration with a future asynchronous committer would require ordering the callback after its commits.

Tested

Windows, RTX 2080 Ti, MinGW-w64 GCC 15.2.0, Release build with BUILD_TESTING=ON and timing logs off.

Based on 40a5b8fa with only this topic committed. The affected libraries and four test executables build successfully.

Six focused CTest cases pass with Vulkan required and shader caching disabled: agc_driver (3.65 s), agc_driver_flip (0.05 s), agc_driver_pm4 (0.23 s), agc_driver_pm4_failure (0.02 s), agc_driver_implicit_eop (0.33 s), and agc_driver_completion_order (0.31 s). Total wall time with two parallel tests: 3.69 s.

The new submission test checks blocked-submission ordering, independent graphics/compute events, coalesced counts, empty submissions, explicit-interrupt deduplication before/after a REWIND tail, suppression at suspend boundaries, and removed registrations. The GPU recorder test checks that event delivery waits for batch retirement and follows a completion label. The new submission test fails as expected with implicit delivery disabled. Existing submit/interrupt tests pass with the default behavior.

python tools/check_conventions.py --base origin/main and git diff --check pass. Linux and full-suite CI remain unrun locally.

Prior title evidence, on 56bfc4d1 plus separate local boot compatibility and shader preparation fixes: disabling implicit completion delivery held Minecraft Preview at a black window after six presented frames, with a registered graphics event and no graphics triggers. Enabling it delivered queue-0 events and allowed loading and world rendering at 1920x1080 / 32 chunks. Those runs used the earlier implementation in the combined local build; the isolated branch in this PR has not been run in Minecraft. This PR alone is not asserted to boot an otherwise unmodified upstream build. No FPS improvement is claimed.

Not tested: console hardware, Linux/lavapipe, the full test suite, other titles. Maintainer-triggered full Linux/Windows CI is still needed.

Checklist

  • Based on current main; no other open PR found implementing this implicit-event fallback
  • One topic per PR; follow-ups go in a new PR
  • No comments in code added
  • No unimplemented exports or silent stubs added
  • No notes, investigation files, logs, screenshots, game binaries or saves added to the repository
  • No new third-party code
  • Generic opt-in behavior; no title-id checks
  • Depends on: none for this code; title boot requires separate compatibility work
  • AI-assisted: yes, prepared and tested with OpenAI Codex. The PR author is responsible for reviewing every line. Draft pending that review and verification of interrupt semantics.

@github-actions

Copy link
Copy Markdown

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.

Pull request Conflicting files (lines on main) Same exports Same new files
#1835 docs/dev/TechnicalDebt.md L2

@github-actions github-actions Bot added the intake paused Closed while PR intake is limited to authors with at least 10 PRs merged into main label Oct 10, 2026
@github-actions

Copy link
Copy Markdown

Thank you for your interest in the project! We are sorry, but we cannot accept more PRs while we work through the existing backlog. This PR has been automatically closed and labeled "intake paused". This is not a judgment of the quality of your changes.

@github-actions github-actions Bot closed this Oct 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

intake paused Closed while PR intake is limited to authors with at least 10 PRs merged into main

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant