GPU: stop when a direct submission fence wait fails #984

Open
avt0m4t48 wants to merge 2 commits from upstream-pr/986 into main
avt0m4t48 commented 2026-11-25 15:10:41 +00:00 (Migrated from github.com)

Imported from fxceless/victory-fork. Originally posted by avt0m4t48 on 2026-11-25T15:10:41Z.


A synchronous submission can currently publish completion, retire resources and start copy-back after fence event registration fails or the Win32 wait returns WAIT_FAILED. The non-relay late-submit path also runs the title's bottom-of-pipe writes after either error. The D3D12 device can still report success at that point.

Route signal, event-registration and Win32 wait errors through the existing GPU failure handler. The synchronous submit and non-relay late paths share the direct-queue wait. Preserve the Windows last error when the wait fails. Publish synchronous completion after the existing device-removal check.

Verification

  • The baseline synchronous probe injected a failed event registration or wait while a real Windows WARP queue was gated. Both cases published completion with the fence still at 0, short of its required value of 1.
  • The baseline late-flight probe reproduced both failures in VICTORY_LATE_WAIT=1 VICTORY_RELAY=0. The title-facing write was visible while the fence remained pending.
  • The candidate run at 85e2a1f verified five injected paths in isolated WARP children. The failure callback observed no completion and the late write was untouched. The ordinary, timed and late controls completed. The exact production source passed the default Windows check, seven queue tests and the repository asset policy.

The probes inject immediate API errors around an actual WARP queue. Physical-adapter device loss and title runs were outside this validation.

Assisted-by: Codex

<!-- greyfinch-sync:fxceless/victory-fork:issue:6607610759 --> Imported from [fxceless/victory-fork](https://github.com/fxceless/victory-fork/pull/986). Originally posted by [avt0m4t48](https://github.com/avt0m4t48) on 2026-11-25T15:10:41Z. --- A synchronous submission can currently publish completion, retire resources and start copy-back after fence event registration fails or the Win32 wait returns `WAIT_FAILED`. The non-relay late-submit path also runs the title's bottom-of-pipe writes after either error. The D3D12 device can still report success at that point. Route signal, event-registration and Win32 wait errors through the existing GPU failure handler. The synchronous submit and non-relay late paths share the direct-queue wait. Preserve the Windows last error when the wait fails. Publish synchronous completion after the existing device-removal check. ### Verification - The [baseline synchronous probe](https://github.com/avt0m4t48/victory-fork/actions/runs/45640189667) injected a failed event registration or wait while a real Windows WARP queue was gated. Both cases published completion with the fence still at 0, short of its required value of 1. - The [baseline late-flight probe](https://github.com/avt0m4t48/victory-fork/actions/runs/45642844643) reproduced both failures in `VICTORY_LATE_WAIT=1 VICTORY_RELAY=0`. The title-facing write was visible while the fence remained pending. - The [candidate run at `85e2a1f`](https://github.com/avt0m4t48/victory-fork/actions/runs/45643963558) verified five injected paths in isolated WARP children. The failure callback observed no completion and the late write was untouched. The ordinary, timed and late controls completed. The exact production source passed the default Windows check, seven queue tests and the repository asset policy. The probes inject immediate API errors around an actual WARP queue. Physical-adapter device loss and title runs were outside this validation. Assisted-by: Codex
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/986:upstream-pr/986'
git switch 'upstream-pr/986'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/986'
git switch 'upstream-pr/986'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/986'
git switch 'upstream-pr/986'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/986'
git switch 'main'
git merge --squash 'upstream-pr/986'
git switch 'main'
git merge --ff-only 'upstream-pr/986'
git switch 'main'
git merge 'upstream-pr/986'
git push origin 'main'
Sign in to join this conversation.
No reviewers
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
fxceless/victory-fork!984
No description provided.