gpu: keep the alias registry test independent of bottom-up ASLR #1111

Manually merged
github merged 1 commit from gh-pr/1111/head into gh-pr/1111/base 2026-11-26 22:42:31 +00:00
Owner

@⁠archielcqp-a11y on GitHub · 2026-11-24 01:10 UTC · original
archielcqp-a11y:gpu/alias-registry-first-fit-v2 → main · +10 −2 · 2 files · 1 commits · merged 2026-11-24 01:47 UTC

Change

check_gpu_alias_registry needs a free 64 KB block below its first graphics allocation. With bottom-up ASLR off, VirtualAlloc(nullptr, ...) places allocations first-fit from the bottom, no block remained below, and both gpu_alias_registry tests failed in setup ("region below the first allocation"). The block is now committed before the first allocation, which first-fit placement then puts above it; when randomized placement puts it higher, the test releases it and searches below as before. Independent problem; no issue.

Verification

Commit 4921f15 on upstream 31f9ebb, Windows 10 build 19045, RTX 3080 and WARP, debug layer enabled.

Bottom-up ASLR off (Windows Security → Exploit protection, after a restart), 10 runs of ctest --test-dir <build> --no-tests=error -R '^gpu_alias_registry_' per build, original and fixed source each rebuilt (measured on the original base d2ac415; on 31f9ebb see the stacked run below):

Build Original Fixed
dev 10/10 runs failed 0/10 failed
app-local WARP 10/10 runs failed 0/10 failed
release 10/10 runs failed 0/10 failed

With bottom-up ASLR on: 10/10 passed in all three builds.

Also tested on upstream 31f9ebb with all five rebased changes stacked (620 tests, Agility SDK 1.620.2 + WARP 1.0.22 build, bottom-up ASLR off): gpu_alias_registry_hardware/_warp, cpu_shim_shadow_warp, cpu_shim_chain_warp and both wave64_emulate tests pass. The remaining failures also fail on plain 31f9ebb: bvh_wave64_warp, wave_shuffle_warp (#145), cpu_archive_texture_gpu_warp, cpu_native_load_config_callback, pe_package_import_closure.

Evidence and follow-up

No new fixture. docs/experiments.md gains a paragraph after the existing note on the interior block's search.

Checklist

  • This pull request covers one reviewable behavior.
  • I included the exact command and result for every check I ran.
  • I considered a negative control or failure case for a new fixture. (The original code under ASLR off is the failure case.)
  • I updated README/docs when a capability or build requirement changed.
  • I did not include game files, dumps, distribution links or secrets.

This change was AI-assisted.

🤖 Generated with Claude Code

**@⁠archielcqp-a11y** on GitHub · 2026-11-24 01:10 UTC · [original](https://github.com/R0Y00/Xbox2Windows/pull/1111) `archielcqp-a11y:gpu/alias-registry-first-fit-v2` → `main` · +10 −2 · 2 files · 1 commits · merged 2026-11-24 01:47 UTC ## Change `check_gpu_alias_registry` needs a free 64 KB block below its first graphics allocation. With bottom-up ASLR off, `VirtualAlloc(nullptr, ...)` places allocations first-fit from the bottom, no block remained below, and both `gpu_alias_registry` tests failed in setup ("region below the first allocation"). The block is now committed before the first allocation, which first-fit placement then puts above it; when randomized placement puts it higher, the test releases it and searches below as before. Independent problem; no issue. ## Verification Commit `4921f15` on upstream `31f9ebb`, Windows 10 build 19045, RTX 3080 and WARP, debug layer enabled. Bottom-up ASLR off (Windows Security → Exploit protection, after a restart), 10 runs of `ctest --test-dir <build> --no-tests=error -R '^gpu_alias_registry_'` per build, original and fixed source each rebuilt (measured on the original base `d2ac415`; on `31f9ebb` see the stacked run below): | Build | Original | Fixed | |---|---|---| | dev | 10/10 runs failed | 0/10 failed | | app-local WARP | 10/10 runs failed | 0/10 failed | | release | 10/10 runs failed | 0/10 failed | With bottom-up ASLR on: 10/10 passed in all three builds. Also tested on upstream `31f9ebb` with all five rebased changes stacked (620 tests, Agility SDK 1.620.2 + WARP 1.0.22 build, bottom-up ASLR off): `gpu_alias_registry_hardware`/`_warp`, `cpu_shim_shadow_warp`, `cpu_shim_chain_warp` and both `wave64_emulate` tests pass. The remaining failures also fail on plain `31f9ebb`: `bvh_wave64_warp`, `wave_shuffle_warp` (#145), `cpu_archive_texture_gpu_warp`, `cpu_native_load_config_callback`, `pe_package_import_closure`. ## Evidence and follow-up No new fixture. `docs/experiments.md` gains a paragraph after the existing note on the interior block's search. ## Checklist - [x] This pull request covers one reviewable behavior. - [x] I included the exact command and result for every check I ran. - [x] I considered a negative control or failure case for a new fixture. (The original code under ASLR off is the failure case.) - [x] I updated README/docs when a capability or build requirement changed. - [x] I did not include game files, dumps, distribution links or secrets. This change was AI-assisted. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
check_gpu_alias_registry needs a free 64 KB block below its first
graphics allocation. With bottom-up ASLR off, VirtualAlloc(nullptr)
places allocations first-fit from the bottom and no block remained below,
so the test failed in setup ("region below the first allocation"). The
block is now committed before the first allocation, which first-fit
placement then puts above it; with randomized placement the test falls
back to the existing search below.

Windows 10 19045, bottom-up ASLR off after a restart, 10 runs each of
ctest -R '^gpu_alias_registry_' (RTX 3080 and WARP):
  dev/w10/release  original 10/10 runs failed, fixed 0/10 failed.
With ASLR on: 10/10 passed in all three builds.

This change was AI-assisted.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 22:42:27 +00:00
github manually merged commit 4921f15448 into gh-pr/1111/base 2026-11-26 22:42:31 +00:00
This discussion has been locked. Commenting is limited to contributors.
No description provided.