runtime: verify native Windows interior placeholder splits #990

Merged
R0Y00 merged 1 commit from upstream-pr/997 into main 2026-11-23 20:44:45 +00:00
R0Y00 commented 2026-11-23 20:28:00 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-23T20:28:00Z.


Refs #888. Adds a native Windows reference fixture for the interior placeholder split used by the desktop page mapper.

  • Reserve five Windows allocation units and isolate one interior unit. Check the base and size of all three resulting reservations with VirtualQuery.
  • Refuse an aligned span that crosses two placeholders and verify that all three reservations remain as they were.
  • Replace the middle with a pagefile-backed view, read back a written byte, and restore the middle placeholder without changing either neighbor. Then release each region independently.

This exercises Windows directly using synthetic sizes. The existing XMem test covers the shim's mapping, coalescing, and range ownership.

Local checks

Commit ffbbf52, Windows 26200.9974, MSVC 19.51, Windows SDK 10.0.26100.

.\tools\dev.ps1
cmake --preset release '-DCMAKE_CXX_FLAGS_DEBUG=/Z7 /Od /RTC1' '-DCMAKE_C_FLAGS_DEBUG=/Z7 /Od /RTC1'
cmake --build --preset release --target windows_placeholder_partition_check
ctest --preset release --no-tests=error -R '^windows_placeholder_partition$' -V

The workstation uses /Z7 because its installed PDB manager rejects /Zi. The configure also points INTAKE_PYTHON at an existing requirements environment. CTest passed 1/1 with no skips. The observed allocation granularity was 65,536 bytes.

A direct cl.exe /nologo /std:c++17 /W4 /O2 /EHsc <source> /link OneCore.lib build also returned 0. In a temporary mutation that skipped the interior split, the fixture observed the original 327,680-byte reservation where it expected 131,072 bytes, and returned 1.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:issue:6568173150 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/997). Originally posted by [R0Y00](https://github.com/R0Y00) on 2026-11-23T20:28:00Z. --- Refs #888. Adds a native Windows reference fixture for the interior placeholder split used by the desktop page mapper. - Reserve five Windows allocation units and isolate one interior unit. Check the base and size of all three resulting reservations with `VirtualQuery`. - Refuse an aligned span that crosses two placeholders and verify that all three reservations remain as they were. - Replace the middle with a pagefile-backed view, read back a written byte, and restore the middle placeholder without changing either neighbor. Then release each region independently. This exercises Windows directly using synthetic sizes. The existing XMem test covers the shim's mapping, coalescing, and range ownership. ## Local checks Commit `ffbbf52`, Windows 26200.9974, MSVC 19.51, Windows SDK 10.0.26100. ```powershell .\tools\dev.ps1 cmake --preset release '-DCMAKE_CXX_FLAGS_DEBUG=/Z7 /Od /RTC1' '-DCMAKE_C_FLAGS_DEBUG=/Z7 /Od /RTC1' cmake --build --preset release --target windows_placeholder_partition_check ctest --preset release --no-tests=error -R '^windows_placeholder_partition$' -V ``` The workstation uses `/Z7` because its installed PDB manager rejects `/Zi`. The configure also points `INTAKE_PYTHON` at an existing requirements environment. CTest passed 1/1 with no skips. The observed allocation granularity was 65,536 bytes. A direct `cl.exe /nologo /std:c++17 /W4 /O2 /EHsc <source> /link OneCore.lib` build also returned 0. In a temporary mutation that skipped the interior split, the fixture observed the original 327,680-byte reservation where it expected 131,072 bytes, and returned 1.
upstream-sync closed this pull request 2026-11-24 06:45:46 +00:00
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
R0Y00/Xbox2Windows!990
No description provided.