cpu: submit a placed vertex draw from a lifted PE entry #1320

Manually merged
github merged 2 commits from gh-pr/1320/head into gh-pr/1320/base 2026-11-26 22:57:53 +00:00
Owner

@⁠R0Y00 on GitHub · 2026-11-24 07:57 UTC · original
R0Y00:codex/pe-placed-view-draw → main · +708 −194 · 13 files · 2 commits · merged 2026-11-24 08:40 UTC

Refs #874. The production placed-view registration from #1316 is now in main. This branch includes main through bec0c399. Both the CPU-driven test and the existing stream consumer share the multi-target render setup and readback path, including typed render target views. The texture cache helper preserves the array-view and explicit vertex-binding options.

The source-built guest calculates two addresses 1 TiB apart, specifies the view extent and stride, records a draw, writes both final vertex words after recording, and then submits and releases. The CPU translator lifts the linked PE entry, its internal call, branches and IAT accesses. The pixel shader is a fixture that loads one DWORD. Each runner compares the AOT executable's exported source hash to the native/mapped executable. The fixture compares the actual draw-side adapter, driver, LUID and software flag across the three paths.

At 5bbfbc01 on Windows build 26200.9974, RTX 4060 Laptop 32.0.16.1656 and WARP 10.0.26100.9818 passed all five cases through Windows native loading, pe_map and AOT. The three draw cases matched all 32 RGBA pixels each, returned 42 and released both placements. Extending the last-DWORD view by four bytes produced red 0, compared with 41 and 135 for the two valid ranges. Rejecting the second placement or the submission published no pixels and returned 20, with one or two releases respectively. Render debug layer disabled.

cmake --build --preset release --target cpu_placed_draw_lifted cpu_shim_startup_lifted pe_map startup_stream_consumer
ctest --preset release --no-tests=error -R '^(cpu_(placed_draw|shim_compute)_|startup_(mrt_|placed_vertex_|stream_draw_|logical_view_|address_(srv|bc_view)_|xg_bc_(chain|array)_))' -j 2 --output-on-failure

21 passed, 0 failed and 1 capability skip (startup_logical_view_warp), including all four FXC/DXC multi-render-target tests, both placed-vertex tests, and the block-compressed texture arrays and mip chains. All inputs are source-built or generated.

**@⁠R0Y00** on GitHub · 2026-11-24 07:57 UTC · [original](https://github.com/R0Y00/Xbox2Windows/pull/1320) `R0Y00:codex/pe-placed-view-draw` → `main` · +708 −194 · 13 files · 2 commits · merged 2026-11-24 08:40 UTC Refs #874. The production placed-view registration from #1316 is now in main. This branch includes main through `bec0c399`. Both the CPU-driven test and the existing stream consumer share the multi-target render setup and readback path, including typed render target views. The texture cache helper preserves the array-view and explicit vertex-binding options. The source-built guest calculates two addresses 1 TiB apart, specifies the view extent and stride, records a draw, writes both final vertex words after recording, and then submits and releases. The CPU translator lifts the linked PE entry, its internal call, branches and IAT accesses. The pixel shader is a fixture that loads one DWORD. Each runner compares the AOT executable's exported source hash to the native/mapped executable. The fixture compares the actual draw-side adapter, driver, LUID and software flag across the three paths. At `5bbfbc01` on Windows build 26200.9974, RTX 4060 Laptop 32.0.16.1656 and WARP 10.0.26100.9818 passed all five cases through Windows native loading, `pe_map` and AOT. The three draw cases matched all 32 RGBA pixels each, returned 42 and released both placements. Extending the last-DWORD view by four bytes produced red 0, compared with 41 and 135 for the two valid ranges. Rejecting the second placement or the submission published no pixels and returned 20, with one or two releases respectively. Render debug layer disabled. ```powershell cmake --build --preset release --target cpu_placed_draw_lifted cpu_shim_startup_lifted pe_map startup_stream_consumer ctest --preset release --no-tests=error -R '^(cpu_(placed_draw|shim_compute)_|startup_(mrt_|placed_vertex_|stream_draw_|logical_view_|address_(srv|bc_view)_|xg_bc_(chain|array)_))' -j 2 --output-on-failure ``` 21 passed, 0 failed and 1 capability skip (`startup_logical_view_warp`), including all four FXC/DXC multi-render-target tests, both placed-vertex tests, and the block-compressed texture arrays and mip chains. All inputs are source-built or generated.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 22:57:51 +00:00
github manually merged commit 5bbfbc0195 into gh-pr/1320/base 2026-11-26 22:57:53 +00:00
Author
Owner

@⁠R0Y00 on GitHub · 2026-11-24 08:18 UTC · original

#1316 is on main at a166e42f. You can now refresh this draft against main. Please keep the lifted-entry draw and its range failure check while using the merged slot-133 registration and bounds test. The DXR build work in #1326 is separate from this vertex capture.

**@⁠R0Y00** on GitHub · 2026-11-24 08:18 UTC · [original](https://github.com/R0Y00/Xbox2Windows/pull/1320#issuecomment-7125975883) #1316 is on main at a166e42f. You can now refresh this draft against main. Please keep the lifted-entry draw and its range failure check while using the merged slot-133 registration and bounds test. The DXR build work in #1326 is separate from this vertex capture.
This discussion has been locked. Commenting is limited to contributors.
No description provided.