runtime: attribute GPU-to-CPU copy refusals #3955

Open
github-bot wants to merge 1 commit from github-bot/gh-3953 into main AGit
Owner

@⁠lambirou on GitHub · 2026-12-03 16:56 UTC · original
lambirou:codex/memory-refusal-attribution → main · +578 −37 · 10 files · 1 commits · open

Problem

The #3718 GPU-to-CPU census reports one dest_title_refusals total whenever a
refused copy or resolve has a destination with title memory. A refusal caused by
the source, such as CopyBufferRegion ... title_backed_source, is counted by the
same total. A historical run reported 299,486 refusals while every detailed
sample was a source refusal, so the total cannot identify what needs fixing.

Change

  • Add a fixed operation-by-cause matrix for the five copy/query operations and
    every refusal cause they can return.
  • Record title_backed_source separately from
    destination_has_title_memory, while preserving the existing total and query
    subset semantics.
  • Emit non-zero buckets in the five-second heartbeat.
  • Add x2w_d3d12_gpu_to_cpu_refusal_snapshot so fixtures can inspect the matrix
    without changing the layout of the existing snapshot export.
  • Exercise all five operations and add a negative control that fails if a
    source refusal is attributed to destination title memory.

This changes diagnostics only. Map, copy forwarding and refusal behavior remain
unchanged.

Refs #3678.

Validation

Windows 11, MSVC 19.44 Debug, debug layer unavailable, WARP and AMD Radeon RX
9060 XT (32.0.32029.2010):

ctest --preset dev --no-tests=error -R '^startup_gpu_to_cpu_' --output-on-failure -j1
ctest --preset dev --no-tests=error -R '^(startup_list_copy|startup_list_queries)' --output-on-failure -j1
python -B tests/standin_exports_check.py
  • GPU-to-CPU suite: 16/16 passed, including both negative controls.
  • Copy/query families: 17/17 passed.
  • Stand-in exports: 515 cases on current main, 6/6 mutations killed.
  • Markdown links: 286 files and 1,011 links checked.

The historical 299,486-refusal run has not been replayed with this build. Known
detail lines were source refusals, but the full breakdown needs a new heartbeat.

**@⁠lambirou** on GitHub · 2026-12-03 16:56 UTC · [original](https://github.com/R0Y00/Xbox2Windows/pull/3953) `lambirou:codex/memory-refusal-attribution` → `main` · +578 −37 · 10 files · 1 commits · open ## Problem The #3718 GPU-to-CPU census reports one `dest_title_refusals` total whenever a refused copy or resolve has a destination with title memory. A refusal caused by the source, such as `CopyBufferRegion ... title_backed_source`, is counted by the same total. A historical run reported 299,486 refusals while every detailed sample was a source refusal, so the total cannot identify what needs fixing. ## Change - Add a fixed operation-by-cause matrix for the five copy/query operations and every refusal cause they can return. - Record `title_backed_source` separately from `destination_has_title_memory`, while preserving the existing total and query subset semantics. - Emit non-zero buckets in the five-second heartbeat. - Add `x2w_d3d12_gpu_to_cpu_refusal_snapshot` so fixtures can inspect the matrix without changing the layout of the existing snapshot export. - Exercise all five operations and add a negative control that fails if a source refusal is attributed to destination title memory. This changes diagnostics only. `Map`, copy forwarding and refusal behavior remain unchanged. Refs #3678. ## Validation Windows 11, MSVC 19.44 Debug, debug layer unavailable, WARP and AMD Radeon RX 9060 XT (`32.0.32029.2010`): ```text ctest --preset dev --no-tests=error -R '^startup_gpu_to_cpu_' --output-on-failure -j1 ctest --preset dev --no-tests=error -R '^(startup_list_copy|startup_list_queries)' --output-on-failure -j1 python -B tests/standin_exports_check.py ``` - GPU-to-CPU suite: 16/16 passed, including both negative controls. - Copy/query families: 17/17 passed. - Stand-in exports: 515 cases on current `main`, 6/6 mutations killed. - Markdown links: 286 files and 1,011 links checked. The historical 299,486-refusal run has not been replayed with this build. Known detail lines were source refusals, but the full breakdown needs a new heartbeat.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-12-03 17:11:49 +00:00
github-bot force-pushed github-bot/gh-3953 from 57f73f52cf to c311ac632b 2026-12-03 17:25:15 +00:00 Compare
Author
Owner

@⁠lambirou on GitHub · 2026-12-03 17:40 UTC · original · edited 2026-12-03 17:48 UTC

Rebased onto the current main and resolved the refusal-attribution overlap in commit a7ee7c444. Revalidated locally: 16/16 GPU-to-CPU, 17/17 copy/query and 515 stand-in export cases with 6/6 mutations killed. GitHub checks are running on the new head; ready for review when they pass.

**@⁠lambirou** on GitHub · 2026-12-03 17:40 UTC · [original](https://github.com/R0Y00/Xbox2Windows/pull/3953#issuecomment-7386876876) · edited 2026-12-03 17:48 UTC Rebased onto the current `main` and resolved the refusal-attribution overlap in commit `a7ee7c444`. Revalidated locally: 16/16 GPU-to-CPU, 17/17 copy/query and 515 stand-in export cases with 6/6 mutations killed. GitHub checks are running on the new head; ready for review when they pass.
This pull request has changes conflicting with the target branch.
  • tests/standin_exports_check.py
View command line instructions

Manual merge helper

Use this merge commit message when completing the merge manually.

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/3955/head:github-bot/gh-3953'
git switch 'github-bot/gh-3953'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-3953'
git switch 'github-bot/gh-3953'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-3953'
git switch 'github-bot/gh-3953'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-3953'
git switch 'main'
git merge --squash 'github-bot/gh-3953'
git switch 'main'
git merge --ff-only 'github-bot/gh-3953'
git switch 'main'
git merge 'github-bot/gh-3953'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.