startup: compute input named by a resource heap record a root constant indexes #2524

Merged
NiiRoZz merged 60 commits from upstream-pr/2532 into main 2026-11-26 02:16:04 +00:00
NiiRoZz commented 2026-11-25 20:10:22 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by NiiRoZz on 2026-11-25T20:10:22Z.


Depends on #2490 (compute dispatch with textures and census; this branch is stacked on it). Refs #2274

What changes

One behaviour: a compute program may take a buffer input from the directly indexed resource heap (root flag 0x400) when the record index is a root constant.

Translator (tools/startup/gfx2hlsl.py) lowers exactly this form:

s_lshl_b32 R, <root constant word>, 5
s_load_dwordx4 D, s[H:H+1], R        ; s[H] the heap pointer, s[H+1] a constant zero, no offset: modifier

with no write of R and no branch target between the two. D becomes a buffer descriptor and the manifest names it

srv <i> buf heap rootconst <parameter> <word>

Everything else through the heap pointer keeps a refusal that names the form:

form refusal
index read from a buffer (s_buffer_load_* then << 5) s_load of a resource heap record whose index is read from a buffer
other shift, other index, index register written again, branch target in between, unshifted register, m0 ... whose offset is not a root constant shifted left by 5 since the last branch target
eight dwords (an image record) ... of 8 dwords
offset: modifier ... with offset:0x..
high word of the pointer pair not a constant zero ... through a pointer whose high word is not a constant zero
formatted load, store, or a non-buffer kind through such a record refused as before / in the manifest
graphics stages unchanged (s_load with a register offset through ('resheap',))

Dispatch (src/startup_stubs)

  • The list's view heap was not recorded in the general case: slot 32 kept the sampler source and, only for a heap with more logical than physical entries, the heap wrapper. Slot 32 now also records the title memory of the view heap it is given (Pass::title_view_heap, a ViewTable built with resolve_view_table, set and replaced where title_samplers is).
  • srv <i> buf heap rootconst <p> <w> is parsed into the existing slot list. At Dispatch the record address is title_view_heap.record(uint32(word(p, w)) << 5, 16); from there the descriptor is read and bound by the code a table <p> <byte> record uses. No second binding path.
  • A record outside the heap refuses the dispatch with a heap record is outside the list's view heap, before anything is bound, like the other refusals in that loop.

Tests

Commit under test: b6bc3c30 (two commits on f67f80a4, the head of #2490; the second only drops one fixture case and adds a sentence to the docs, and the runtime sources are those of f5c3c857, which the dispatch runs below were built from). Windows 10.0.26300, MSVC 14.44, LLVM 15 llvm-mc.

python -B tests/startup_gfx2hlsl_heap_record_check.py --llvm-mc llvm-mc-15

Result: heap record fixture: 45 instructions reassembled to the recorded words, then PASS (manifest and HLSL exact; 19 refused controls; graphics, manifest and translator-mutation checks). Expected: the same.

  • The manifest and the HLSL from the bindings to the end of main are compared whole.
  • 19 controls each change one thing in the program and must be refused with the reason in the table above.
  • Translator mutation: with the write tracking disabled for one instruction, the "index register written again" control translates; the check requires that, then requires the refusal again with the tracking restored.
cmake --build --preset dev --target startup_stream_consumer
ctest --preset dev --no-tests=error -R "^startup_compute_dispatch_|^startup_gfx2hlsl_heap_record$" -V

Result: 7 of 7 passed, no capability skip.

test adapter driver debug layer result
startup_gfx2hlsl_heap_record none pass
startup_compute_dispatch_warp Microsoft Basic Render Driver 10.0.26100.10068 enabled, no error message pass
startup_compute_dispatch_texture_warp Microsoft Basic Render Driver 10.0.26100.10068 enabled, no error message pass
startup_compute_dispatch_heap_warp (new) Microsoft Basic Render Driver 10.0.26100.10068 enabled, no error message pass
startup_compute_dispatch_hardware NVIDIA GeForce RTX 5090 32.0.16.2135 enabled, no error message pass
startup_compute_dispatch_texture_hardware NVIDIA GeForce RTX 5090 32.0.16.2135 enabled, no error message pass
startup_compute_dispatch_heap_hardware (new) NVIDIA GeForce RTX 5090 32.0.16.2135 enabled, no error message pass

The new dispatch test runs a source-built gfx1013 program (case A of startup_gfx2hlsl_compute_check.py with its input loaded from the heap) through the stand-in's list. The input descriptor is only in heap record 2; records 0 and 1 hold the output's descriptor. All 320 output words are read back from the aliased memory and compared.

Negative controls of the dispatch test:

  • before translation: refused: no translation, every word keeps its sentinel;
  • root constant 0x07ffffff (a record past the heap): one refused: a heap record is outside the list's view heap, the census names that reason, every word keeps its sentinel and the input is unchanged;
  • runtime mutations, each rebuilt and run once on WARP, then reverted: shift by 4 instead of 5, and index ignored. Both failed the test with word=0 got=c5c5c5c5 expected=ea74e376 (288 words differ) and refused: an output buffer is also an input.

Wider groups, same build: ctest --preset dev --no-tests=error -R "^startup_compute_|^startup_stream_|^startup_gfx2hlsl_heap_record$": 63 of 63 passed (61 in one run; the two startup_stream_depth_* tests passed once their executable was built), no capability skip.

Pure-Python checks: every check listed in AGENTS.md plus every tests/startup_gfx2hlsl_*_check.py and tests/startup_translator_check.py, each run with no argument: 152 exit 0, 1 exit 77 (startup_run_sh_check.py, a POSIX launcher check that skips on Windows; not a pass). git diff --check is clean.

Measured and not measured

Measured:

  • the translation and the dispatch of one synthetic program, on WARP and one physical adapter;
  • in a local set of 184 compute programs that hold a register-offset load through the heap pointer: every such load now lowers in 4 programs; 151 programs hold a load whose index is read from a buffer and 57 hold a load with another unmodelled offset (a program can hold both). None of the 184 translates with this change: the 4 stop at other instructions (s_pack_ll_b32_b16 in 3 of them, then v_fma_mix_f32, an SDWA v_cndmask_b32, buffer_store_format_xyzw and others).

Not measured, or a hypothesis:

  • no real program reaches a Dispatch through this path yet, so nothing is claimed about frames or startup;
  • the record offset is a literal byte offset into the title's heap memory, as a table offset is. The fixture writes its descriptors at those bytes itself. A caller that places records by the adapter's descriptor increment on an adapter whose increment is not 32 bytes is not covered (WARP is such an adapter, so its run covers the literal offset only); the same holds for table offsets today;
  • that the heap pointer SGPR follows the root parameters is the translator's existing inference for compute entry registers, not something this change verifies;
  • only a buffer read is modelled through a heap record. Image records (eight dwords), stores and formatted loads stay refused;
  • the translator cache revision is unchanged, so a cache that already holds a .fail for such a request keeps it until the request is translated again.

🤖 Generated with Claude Code

<!-- greyfinch-sync:R0Y00/Xbox2Windows:issue:6612806750 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2532). Originally posted by [NiiRoZz](https://github.com/NiiRoZz) on 2026-11-25T20:10:22Z. --- Depends on #2490 (compute dispatch with textures and census; this branch is stacked on it). Refs #2274 ## What changes One behaviour: a compute program may take a buffer input from the directly indexed resource heap (root flag 0x400) when the record index is a root constant. **Translator (`tools/startup/gfx2hlsl.py`)** lowers exactly this form: ``` s_lshl_b32 R, <root constant word>, 5 s_load_dwordx4 D, s[H:H+1], R ; s[H] the heap pointer, s[H+1] a constant zero, no offset: modifier ``` with no write of `R` and no branch target between the two. `D` becomes a buffer descriptor and the manifest names it ``` srv <i> buf heap rootconst <parameter> <word> ``` Everything else through the heap pointer keeps a refusal that names the form: | form | refusal | | --- | --- | | index read from a buffer (`s_buffer_load_*` then `<< 5`) | `s_load of a resource heap record whose index is read from a buffer` | | other shift, other index, index register written again, branch target in between, unshifted register, `m0` | `... whose offset is not a root constant shifted left by 5 since the last branch target` | | eight dwords (an image record) | `... of 8 dwords` | | `offset:` modifier | `... with offset:0x..` | | high word of the pointer pair not a constant zero | `... through a pointer whose high word is not a constant zero` | | formatted load, store, or a non-buffer kind through such a record | refused as before / in the manifest | | graphics stages | unchanged (`s_load with a register offset through ('resheap',)`) | **Dispatch (`src/startup_stubs`)** - The list's view heap was not recorded in the general case: slot 32 kept the sampler source and, only for a heap with more logical than physical entries, the heap wrapper. Slot 32 now also records the title memory of the view heap it is given (`Pass::title_view_heap`, a `ViewTable` built with `resolve_view_table`, set and replaced where `title_samplers` is). - `srv <i> buf heap rootconst <p> <w>` is parsed into the existing slot list. At Dispatch the record address is `title_view_heap.record(uint32(word(p, w)) << 5, 16)`; from there the descriptor is read and bound by the code a `table <p> <byte>` record uses. No second binding path. - A record outside the heap refuses the dispatch with `a heap record is outside the list's view heap`, before anything is bound, like the other refusals in that loop. ## Tests Commit under test: `b6bc3c30` (two commits on `f67f80a4`, the head of #2490; the second only drops one fixture case and adds a sentence to the docs, and the runtime sources are those of `f5c3c857`, which the dispatch runs below were built from). Windows 10.0.26300, MSVC 14.44, LLVM 15 `llvm-mc`. ```powershell python -B tests/startup_gfx2hlsl_heap_record_check.py --llvm-mc llvm-mc-15 ``` Result: `heap record fixture: 45 instructions reassembled to the recorded words`, then `PASS (manifest and HLSL exact; 19 refused controls; graphics, manifest and translator-mutation checks)`. Expected: the same. - The manifest and the HLSL from the bindings to the end of `main` are compared whole. - 19 controls each change one thing in the program and must be refused with the reason in the table above. - Translator mutation: with the write tracking disabled for one instruction, the "index register written again" control translates; the check requires that, then requires the refusal again with the tracking restored. ```powershell cmake --build --preset dev --target startup_stream_consumer ctest --preset dev --no-tests=error -R "^startup_compute_dispatch_|^startup_gfx2hlsl_heap_record$" -V ``` Result: 7 of 7 passed, no capability skip. | test | adapter | driver | debug layer | result | | --- | --- | --- | --- | --- | | `startup_gfx2hlsl_heap_record` | none | | | pass | | `startup_compute_dispatch_warp` | Microsoft Basic Render Driver | 10.0.26100.10068 | enabled, no error message | pass | | `startup_compute_dispatch_texture_warp` | Microsoft Basic Render Driver | 10.0.26100.10068 | enabled, no error message | pass | | `startup_compute_dispatch_heap_warp` (new) | Microsoft Basic Render Driver | 10.0.26100.10068 | enabled, no error message | pass | | `startup_compute_dispatch_hardware` | NVIDIA GeForce RTX 5090 | 32.0.16.2135 | enabled, no error message | pass | | `startup_compute_dispatch_texture_hardware` | NVIDIA GeForce RTX 5090 | 32.0.16.2135 | enabled, no error message | pass | | `startup_compute_dispatch_heap_hardware` (new) | NVIDIA GeForce RTX 5090 | 32.0.16.2135 | enabled, no error message | pass | The new dispatch test runs a source-built gfx1013 program (case A of `startup_gfx2hlsl_compute_check.py` with its input loaded from the heap) through the stand-in's list. The input descriptor is only in heap record 2; records 0 and 1 hold the output's descriptor. All 320 output words are read back from the aliased memory and compared. Negative controls of the dispatch test: - before translation: `refused: no translation`, every word keeps its sentinel; - root constant `0x07ffffff` (a record past the heap): one `refused: a heap record is outside the list's view heap`, the census names that reason, every word keeps its sentinel and the input is unchanged; - runtime mutations, each rebuilt and run once on WARP, then reverted: shift by 4 instead of 5, and index ignored. Both failed the test with `word=0 got=c5c5c5c5 expected=ea74e376 (288 words differ)` and `refused: an output buffer is also an input`. Wider groups, same build: `ctest --preset dev --no-tests=error -R "^startup_compute_|^startup_stream_|^startup_gfx2hlsl_heap_record$"`: 63 of 63 passed (61 in one run; the two `startup_stream_depth_*` tests passed once their executable was built), no capability skip. Pure-Python checks: every check listed in `AGENTS.md` plus every `tests/startup_gfx2hlsl_*_check.py` and `tests/startup_translator_check.py`, each run with no argument: 152 exit 0, 1 exit 77 (`startup_run_sh_check.py`, a POSIX launcher check that skips on Windows; not a pass). `git diff --check` is clean. ## Measured and not measured Measured: - the translation and the dispatch of one synthetic program, on WARP and one physical adapter; - in a local set of 184 compute programs that hold a register-offset load through the heap pointer: every such load now lowers in 4 programs; 151 programs hold a load whose index is read from a buffer and 57 hold a load with another unmodelled offset (a program can hold both). None of the 184 translates with this change: the 4 stop at other instructions (`s_pack_ll_b32_b16` in 3 of them, then `v_fma_mix_f32`, an SDWA `v_cndmask_b32`, `buffer_store_format_xyzw` and others). Not measured, or a hypothesis: - no real program reaches a Dispatch through this path yet, so nothing is claimed about frames or startup; - the record offset is a literal byte offset into the title's heap memory, as a table offset is. The fixture writes its descriptors at those bytes itself. A caller that places records by the adapter's descriptor increment on an adapter whose increment is not 32 bytes is not covered (WARP is such an adapter, so its run covers the literal offset only); the same holds for table offsets today; - that the heap pointer SGPR follows the root parameters is the translator's existing inference for compute entry registers, not something this change verifies; - only a buffer read is modelled through a heap record. Image records (eight dwords), stores and formatted loads stay refused; - the translator cache revision is unchanged, so a cache that already holds a `.fail` for such a request keeps it until the request is translated again. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
NiiRoZz commented 2026-11-25 21:01:30 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by NiiRoZz on 2026-11-25T20:22:01Z.


The Linux Python job failed at 5bade3c4 on tests/startup_gfx2hlsl_sload_const_offset_check.py, a check that landed on main after this branch was written. It calls the s_load handlers on a stage built without a kind, and the heap record branch read self.kind directly, so the eight-dword case raised AttributeError instead of the refusal.

Fixed in fdba7797 (with current main merged in, no conflict): the branch now reads the kind with getattr(self, 'kind', None), as the other handlers in the file do. No behaviour change for a real stage.

Run at fdba7797, Windows 10.0.26300, Python from out/pe-env:

python -B tests/startup_gfx2hlsl_sload_const_offset_check.py   # s_load constant offset checks: 0 failed
python -B tests/startup_gfx2hlsl_heap_record_check.py          # PASS (manifest and HLSL exact; 19 refused controls; ...)
python -B tests/startup_translator_check.py                    # startup translator checks: 0 failed
python -B tests/startup_gfx2hlsl_<each>_check.py               # every no-argument check exits 0

Not rerun after this commit: the dispatch tests (the runtime sources are unchanged) and the heap record check's --llvm-mc reassembly.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7173563329 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2532#issuecomment-7173563329). Originally posted by [NiiRoZz](https://github.com/NiiRoZz) on 2026-11-25T20:22:01Z. --- The Linux Python job failed at 5bade3c4 on `tests/startup_gfx2hlsl_sload_const_offset_check.py`, a check that landed on `main` after this branch was written. It calls the `s_load` handlers on a stage built without a `kind`, and the heap record branch read `self.kind` directly, so the eight-dword case raised `AttributeError` instead of the refusal. Fixed in fdba7797 (with current `main` merged in, no conflict): the branch now reads the kind with `getattr(self, 'kind', None)`, as the other handlers in the file do. No behaviour change for a real stage. Run at fdba7797, Windows 10.0.26300, Python from `out/pe-env`: ```powershell python -B tests/startup_gfx2hlsl_sload_const_offset_check.py # s_load constant offset checks: 0 failed python -B tests/startup_gfx2hlsl_heap_record_check.py # PASS (manifest and HLSL exact; 19 refused controls; ...) python -B tests/startup_translator_check.py # startup translator checks: 0 failed python -B tests/startup_gfx2hlsl_<each>_check.py # every no-argument check exits 0 ``` Not rerun after this commit: the dispatch tests (the runtime sources are unchanged) and the heap record check's `--llvm-mc` reassembly.
ChazY11 commented 2026-11-25 22:02:20 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by ChazY11 on 2026-11-25T21:38:18Z.


Seven mutations of the resource-heap record path, all caught — after I fixed two anchors that had matched the wrong function

The device-free check

python -B tests/startup_gfx2hlsl_heap_record_check.py
    startup_gfx2hlsl_heap_record: PASS (manifest and HLSL exact; 19 refused controls; graphics, manifest and translation …)

The other three checks in this PR (startup_compute_dispatch_check.py, …_heap_check.py, …_texture_check.py) exit 1
with no arguments — they want DXC, an adapter and a dispatch mode, so they are the GPU half and I did not run them. The
19 refused controls in the pure-Python one are the part that matters for the new symbolic matcher anyway.

Mutations

mutation in heap_record / the index tracking caught
the shift int(srcs[1], 0) == 5 → 4 (32-byte record becomes 16-byte) caught
a buffer-sourced index accepted instead of refused caught
an index that is not a rootconst accepted caught
count != 4 guard removed caught
the imm is not None (offset) guard removed caught
the high word must be a constant zero — guard removed caught

Two of these need a note about my own method, because I reported them wrong the first time and then fixed it: my anchors
if count != 4: and if imm is not None: matched the first occurrences in the file — s_load at line 3610 and the
SMEM literal-offset check at 3574 — not the ones inside heap_record at 3634/3636. Those two mutations were edits to
other functions, and "survived" said nothing about this PR. Re-running with the anchors that include the surrounding
what line (which only exists in heap_record) shows both are caught. A single generic if count != 4: is not a
usable anchor in a 6 000-line translator; the message text is what makes it unique.

What the shift guard means

index << 5 is the byte offset of a 32-byte record, and the fixture refuses the 16-byte reading. That is the one number
in this change whose wrongness would be silent: << 5 → << 4 still produces a plausible descriptor, just from the
wrong half of the record. It is caught.

The other half I did not touch

src/startup_stubs/d3d12_compute_dispatch.inl (+399), d3d12_draw.inl (+70), list_compute_root.h, list_dispatch.h,
root_constant_store.h and 229 lines of startup_stream_consumer.cpp are all on the dispatch/GPU side, exercised by
startup_compute_dispatch_{warp,hardware} — which are the three checks that need arguments. If you want a mutation pass
over that half too, say so and I will build the targets and run it the way I did for #2491.

AI-assisted; pure Python for the rows above, Windows 11 build 26300.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7175344338 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2532#issuecomment-7175344338). Originally posted by [ChazY11](https://github.com/ChazY11) on 2026-11-25T21:38:18Z. --- ## Seven mutations of the resource-heap record path, all caught — after I fixed two anchors that had matched the wrong function ### The device-free check ```text python -B tests/startup_gfx2hlsl_heap_record_check.py startup_gfx2hlsl_heap_record: PASS (manifest and HLSL exact; 19 refused controls; graphics, manifest and translation …) ``` The other three checks in this PR (`startup_compute_dispatch_check.py`, `…_heap_check.py`, `…_texture_check.py`) exit 1 with no arguments — they want DXC, an adapter and a dispatch mode, so they are the GPU half and I did not run them. The 19 refused controls in the pure-Python one are the part that matters for the new symbolic matcher anyway. ### Mutations | mutation in `heap_record` / the index tracking | caught | |---|---| | the shift `int(srcs[1], 0) == 5` → `4` (32-byte record becomes 16-byte) | **caught** | | a buffer-sourced index accepted instead of refused | **caught** | | an index that is not a `rootconst` accepted | **caught** | | `count != 4` guard removed | **caught** | | the `imm is not None` (offset) guard removed | **caught** | | the high word must be a constant zero — guard removed | **caught** | Two of these need a note about my own method, because I reported them wrong the first time and then fixed it: my anchors `if count != 4:` and `if imm is not None:` matched the **first** occurrences in the file — `s_load` at line 3610 and the SMEM literal-offset check at 3574 — not the ones inside `heap_record` at 3634/3636. Those two mutations were edits to *other* functions, and "survived" said nothing about this PR. Re-running with the anchors that include the surrounding `what` line (which only exists in `heap_record`) shows both are caught. A single generic `if count != 4:` is not a usable anchor in a 6 000-line translator; the message text is what makes it unique. ### What the shift guard means `index << 5` is the byte offset of a 32-byte record, and the fixture refuses the 16-byte reading. That is the one number in this change whose wrongness would be **silent**: `<< 5` → `<< 4` still produces a plausible descriptor, just from the wrong half of the record. It is caught. ### The other half I did not touch `src/startup_stubs/d3d12_compute_dispatch.inl` (+399), `d3d12_draw.inl` (+70), `list_compute_root.h`, `list_dispatch.h`, `root_constant_store.h` and 229 lines of `startup_stream_consumer.cpp` are all on the dispatch/GPU side, exercised by `startup_compute_dispatch_{warp,hardware}` — which are the three checks that need arguments. If you want a mutation pass over that half too, say so and I will build the targets and run it the way I did for #2491. AI-assisted; pure Python for the rows above, Windows 11 build 26300.
Makto94 commented 2026-11-25 23:02:04 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by Makto94 on 2026-11-25T22:13:51Z.


Hardware run at head b306d44e (build exit code 0). The PR is stacked on #2490.

Environment: NVIDIA GeForce RTX 3070 Ti, driver 32.0.16.2101 (NVIDIA 621.01) and Windows 11 Pro build 26300.9974 as reported by the system, dev preset (MSVC). The runs were serial (-j1).

  1. Command: ctest --preset dev --no-tests=error -j1 -V -R '^(startup_compute_dispatch.*|startup_root_constant_store|startup_list_dispatch.*|startup_compute_root|startup_gfx2hlsl_heap_record)$'

Result: 15/15 passed, 0 failed: 3 startup_compute_dispatch*_warp, 3 startup_compute_dispatch*_hardware, and the 9 other tests the diff adds (startup_root_constant_store, startup_list_dispatch and its 5 _control tests, startup_compute_root, startup_gfx2hlsl_heap_record). 0 capability skips (77).

  • startup_compute_dispatch_hardware, startup_compute_dispatch_texture_hardware and startup_compute_dispatch_heap_hardware print adapter=NVIDIA GeForce RTX 3070 Ti driver=32.0.16.2101 and debug layer: enabled, no error message.
  • startup_compute_dispatch: PASS on hardware (all 320 words match after translation and with the same root set again; untouched before translation, without a Dispatch and for 6 refusals)
  • startup_compute_dispatch_texture_hardware: texture output: all 1024 halves match after translation (64 changed) ... and texture input: all 320 words match after translation ...
  • startup_compute_dispatch_heap: PASS on hardware (all 320 words match through heap record 2; untouched before translation and for a record outside the heap)
  • The WARP tests print adapter=Microsoft Basic Render Driver with the same debug-layer line.
  1. Repeat run. A comment on #2470 reported an intermittent process-exit failure in the direct Dispatch case on an RTX 4060 (3 failures in 5 repetitions) and isolated it to the release of the cached desktop PSO. The #2470 thread says the fix (7a8d9c89) is on the branch as c821b4b2; c821b4b2 ("startup: avoid calling the compute driver after process termination begins") is an ancestor of this head. I repeated the hardware tests on a different NVIDIA GPU.

Command: ctest --preset dev --no-tests=error -j1 -V --repeat until-fail:20 -R '^startup_compute_dispatch(_texture|_heap)?_hardware$'

Result: each of the 3 tests passed 20/20 consecutive runs (60 PASS on hardware lines, 100% tests passed, 0 tests failed out of 3). This does not cover the RTX 4060.

This run covers NVIDIA and WARP only. Not covered: any test outside the filters above.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7176100834 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2532#issuecomment-7176100834). Originally posted by [Makto94](https://github.com/Makto94) on 2026-11-25T22:13:51Z. --- Hardware run at head `b306d44e` (build exit code 0). The PR is stacked on #2490. Environment: NVIDIA GeForce RTX 3070 Ti, driver 32.0.16.2101 (NVIDIA 621.01) and Windows 11 Pro build 26300.9974 as reported by the system, `dev` preset (MSVC). The runs were serial (`-j1`). 1. Command: `ctest --preset dev --no-tests=error -j1 -V -R '^(startup_compute_dispatch.*|startup_root_constant_store|startup_list_dispatch.*|startup_compute_root|startup_gfx2hlsl_heap_record)$'` Result: 15/15 passed, 0 failed: 3 `startup_compute_dispatch*_warp`, 3 `startup_compute_dispatch*_hardware`, and the 9 other tests the diff adds (`startup_root_constant_store`, `startup_list_dispatch` and its 5 `_control` tests, `startup_compute_root`, `startup_gfx2hlsl_heap_record`). 0 capability skips (77). - `startup_compute_dispatch_hardware`, `startup_compute_dispatch_texture_hardware` and `startup_compute_dispatch_heap_hardware` print `adapter=NVIDIA GeForce RTX 3070 Ti driver=32.0.16.2101` and `debug layer: enabled, no error message`. - `startup_compute_dispatch: PASS on hardware (all 320 words match after translation and with the same root set again; untouched before translation, without a Dispatch and for 6 refusals)` - `startup_compute_dispatch_texture_hardware`: `texture output: all 1024 halves match after translation (64 changed) ...` and `texture input: all 320 words match after translation ...` - `startup_compute_dispatch_heap: PASS on hardware (all 320 words match through heap record 2; untouched before translation and for a record outside the heap)` - The WARP tests print `adapter=Microsoft Basic Render Driver` with the same debug-layer line. 2. Repeat run. A comment on #2470 reported an intermittent process-exit failure in the direct Dispatch case on an RTX 4060 (3 failures in 5 repetitions) and isolated it to the release of the cached desktop PSO. The #2470 thread says the fix (`7a8d9c89`) is on the branch as `c821b4b2`; `c821b4b2` ("startup: avoid calling the compute driver after process termination begins") is an ancestor of this head. I repeated the hardware tests on a different NVIDIA GPU. Command: `ctest --preset dev --no-tests=error -j1 -V --repeat until-fail:20 -R '^startup_compute_dispatch(_texture|_heap)?_hardware$'` Result: each of the 3 tests passed 20/20 consecutive runs (60 `PASS on hardware` lines, `100% tests passed, 0 tests failed out of 3`). This does not cover the RTX 4060. This run covers NVIDIA and WARP only. Not covered: any test outside the filters above.
tedin7 commented 2026-11-26 02:05:12 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-26T01:38:11Z.


@NiiRoZz #2532 is now in conflict with main (merge state DIRTY at head 28c44d5f). It is the base of the stack #2580 -> #2585 / #2596 / #2624 / #2625, so none of those can be tested or merged until it is updated.

Could you merge (or rebase onto) current main on this branch? Once the head changes we will re-run the review and the Windows checks on it.

AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7179971577 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2532#issuecomment-7179971577). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-26T01:38:11Z. --- @NiiRoZz #2532 is now in conflict with `main` (merge state DIRTY at head `28c44d5f`). It is the base of the stack #2580 -> #2585 / #2596 / #2624 / #2625, so none of those can be tested or merged until it is updated. Could you merge (or rebase onto) current `main` on this branch? Once the head changes we will re-run the review and the Windows checks on it. AI-assisted; commands listed were executed locally.
upstream-sync closed this pull request 2026-11-26 03:02:58 +00:00
tedin7 commented 2026-11-26 03:03:21 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-26T02:09:52Z.


@NiiRoZz I merged current main into this branch (merge commit 29ee504b, no rebase, no force). One conflict in src/startup_stubs/d3d12_xs_device.cpp (main added the E_OUTOFMEMORY check after wrap); I kept both: the check first, then the compute request block. No other change to your code. This unblocks the stack #2580, #2585, #2596, #2624, #2625.

Verification:

  • Linux: python3 -B tests/startup_gfx2hlsl_heap_record_check.py, tests/startup_gfx2hlsl_sload_const_offset_check.py, tests/docs_links_check.py, tests/bidi_controls_check.py, git diff --check origin/main...HEAD: all pass.
  • Win2025 (WARP + hardware adapters), dev and release: x2w_pipe.py win2025 2532 --patch <merge diff> --targets startup_stream_consumer,d3d12_xs_shim --regex '^(startup_compute_.*|startup_stream_request_warp|startup_stream_adapter_filter)' gave 131/131 passed in each preset, including startup_compute_dispatch_{warp,hardware}, startup_compute_dispatch_heap_* and startup_compute_dispatch_texture_*.

AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7180523879 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2532#issuecomment-7180523879). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-26T02:09:52Z. --- @NiiRoZz I merged current `main` into this branch (merge commit 29ee504b, no rebase, no force). One conflict in `src/startup_stubs/d3d12_xs_device.cpp` (`main` added the `E_OUTOFMEMORY` check after `wrap`); I kept both: the check first, then the compute request block. No other change to your code. This unblocks the stack #2580, #2585, #2596, #2624, #2625. Verification: - Linux: `python3 -B tests/startup_gfx2hlsl_heap_record_check.py`, `tests/startup_gfx2hlsl_sload_const_offset_check.py`, `tests/docs_links_check.py`, `tests/bidi_controls_check.py`, `git diff --check origin/main...HEAD`: all pass. - Win2025 (WARP + hardware adapters), dev and release: `x2w_pipe.py win2025 2532 --patch <merge diff> --targets startup_stream_consumer,d3d12_xs_shim --regex '^(startup_compute_.*|startup_stream_request_warp|startup_stream_adapter_filter)'` gave 131/131 passed in each preset, including `startup_compute_dispatch_{warp,hardware}`, `startup_compute_dispatch_heap_*` and `startup_compute_dispatch_texture_*`. AI-assisted; commands listed were executed locally.
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!2524
No description provided.