Allow a bounded wait for the GPU mapping fence #307

Manually merged
github merged 1 commit from github-bot/gh-307 into gh-pr/307/base 2026-11-27 15:29:59 +00:00 AGit
Owner

@⁠TaynanGT on GitHub · 2026-11-27 15:14 UTC · original
TaynanGT:fix/mapping-fence-wait-221 → main · +147 −31 · 4 files · 1 commits · merged 2026-11-27 15:23 UTC

Add VICTORY_MAPPING_WAIT_MS for the event wait on the GPU memory-mapping fence. A timed-out marker stays pending. Later allocation calls check its completion before reusing the list and return promptly while it is still pending. A new successful mapping still requires a fresh marker.

The blocked mapping wait is reported in #221. Three focused tests passed on Windows with the native event API and simulated D3D12 fence operations, covering the timeout, later completion, and the absence of a second signal or event registration while polling the old marker. The Proton test on the affected setup is pending.

**@⁠TaynanGT** on GitHub · 2026-11-27 15:14 UTC · [original](https://github.com/TaynanGT/Vice-Tay/pull/307) `TaynanGT:fix/mapping-fence-wait-221` → `main` · +147 −31 · 4 files · 1 commits · merged 2026-11-27 15:23 UTC Add `VICTORY_MAPPING_WAIT_MS` for the event wait on the GPU memory-mapping fence. A timed-out marker stays pending. Later allocation calls check its completion before reusing the list and return promptly while it is still pending. A new successful mapping still requires a fresh marker. The blocked mapping wait is reported in [#221](https://git.gtahub.st/github/TaynanGT--Vice-Tay/issues/221). Three focused tests passed on Windows with the native event API and simulated D3D12 fence operations, covering the timeout, later completion, and the absence of a second signal or event registration while polling the old marker. The Proton test on the affected setup is pending.
Keep a timed-out mapping marker pending. Later callers check the existing fence before reusing its list, while the optional wait limit releases the shared mapping lock.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-27 15:20:20 +00:00
Author
Owner

@⁠chatgpt-codex-connector[bot] on GitHub · 2026-11-27 15:14 UTC · original · edited 2026-11-27 15:17 UTC

Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-27T15:15:49.650461Z 64f2fcc PR opened
🔒 Security Review ✅ Completed 2026-11-27T15:17:38.466266Z 64f2fcc PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@⁠codex review" or "@⁠codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

**@⁠chatgpt-codex-connector[bot]** on GitHub · 2026-11-27 15:14 UTC · [original](https://github.com/TaynanGT/Vice-Tay/pull/307#issuecomment-7221811125) · edited 2026-11-27 15:17 UTC <!-- codex-pull-request-review-summary --> <!-- codex-review-state:v1 {"code_review":{"commit_sha":"64f2fccb655d354f65315ba8f9a08541e278f6e9","has_any_findings":false,"has_unresolved_findings":false,"status":"completed"},"security_review":{"commit_sha":"64f2fccb655d354f65315ba8f9a08541e278f6e9","has_any_findings":null,"has_unresolved_findings":null,"status":"completed"}} --> <!-- codex-security-review:v1 {"blockingSeverityThreshold":"P0","headSha":"64f2fccb655d354f65315ba8f9a08541e278f6e9","mergeGateEnabled":false,"pullRequestNumber":307,"repository":"TaynanGT/Vice-Tay","status":"completed"} --> <details> <summary><strong>Codex Review Summary</strong>: ✅ Completed</summary> This comment shows the latest Codex review activity on this pull request. | Review | Status | Commit | Review trigger | | --- | --- | --- | --- | | 📝 **Code Review** | ✅ **Completed** <relative-time datetime="2026-11-27T15:15:49.650461Z">2026-11-27T15:15:49.650461Z</relative-time> | `64f2fcc` | PR opened | | 🔒 **Security Review** | ✅ **Completed** <relative-time datetime="2026-11-27T15:17:38.466266Z">2026-11-27T15:17:38.466266Z</relative-time> | `64f2fcc` | PR opened | <details> <summary>ℹ️ About Codex in GitHub</summary> <br/> [Your team has set up Codex to review pull requests in this repo](https://chatgpt.com/codex/cloud/settings/general). Reviews are triggered when you - Open a pull request for review - Mark a draft as ready - Comment "@⁠codex review" or "@⁠codex security review". Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. </details> </details>
github-bot changed target branch from main to gh-pr/307/base 2026-11-27 15:29:57 +00:00
github manually merged commit 64f2fccb65 into gh-pr/307/base 2026-11-27 15:29:59 +00:00
Author
Owner

@⁠Melanpan on GitHub · 2026-11-27 15:24 UTC · original

✨ Claude-sama tested this! ✨ The Proton test on the affected setup (RTX 5090, driver 620.73.04, GE-Proton11-14 + view-tree server, Fedora), with 64f2fcc + the local diagnostics patch, VICTORY_MAPPING_WAIT_MS=5000, linux/play.sh series-s:

Time Event
16:22:59.74 Xid 13 (Graphics SM Warp Exception … MMU Fault)
16:23:04.23 mapping fence wait timed out value=4295 limit=5000
16:23:04.24 host GPU device removed after 2 submissions sent ahead … 0x887A0005, then host GPU failure

No title watchdog (+0x23cf683): the run ends through the device-loss report about 4.5 s after the fault, instead of hanging until the watchdog fires 30 s later. The shader fault itself is unchanged (see #221).

Tested with Claude Code on my own copy of the title.

**@⁠Melanpan** on GitHub · 2026-11-27 15:24 UTC · [original](https://github.com/TaynanGT/Vice-Tay/pull/307#issuecomment-7222021329) ✨ **Claude-sama tested this!** ✨ The Proton test on the affected setup (RTX 5090, driver 620.73.04, GE-Proton11-14 + view-tree server, Fedora), with `64f2fcc` + the local diagnostics patch, `VICTORY_MAPPING_WAIT_MS=5000`, `linux/play.sh series-s`: | Time | Event | | --- | --- | | 16:22:59.74 | Xid 13 (`Graphics SM Warp Exception … MMU Fault`) | | 16:23:04.23 | `mapping fence wait timed out value=4295 limit=5000` | | 16:23:04.24 | `host GPU device removed after 2 submissions sent ahead … 0x887A0005`, then `host GPU failure` | No title watchdog (`+0x23cf683`): the run ends through the device-loss report about 4.5 s after the fault, instead of hanging until the watchdog fires 30 s later. The shader fault itself is unchanged (see #221). *Tested with Claude Code on my own copy of the title.*
Author
Owner

@⁠TaynanGT on GitHub · 2026-11-27 15:32 UTC · original

@⁠Melanpan The timeout surfaced device removal about 4.5 seconds after the graphics fault. That confirms the bounded wait on your Proton setup. The earlier graphics fault is still open in #221.

**@⁠TaynanGT** on GitHub · 2026-11-27 15:32 UTC · [original](https://github.com/TaynanGT/Vice-Tay/pull/307#issuecomment-7222173578) @⁠Melanpan The timeout surfaced device removal about 4.5 seconds after the graphics fault. That confirms the bounded wait on your Proton setup. The earlier graphics fault is still open in #221.
This discussion has been locked. Commenting is limited to contributors.
No description provided.