runtime: bind 3D and 1D texture UAVs and write them in the C++ compute manifest #2975

Closed
Leyukaka wants to merge 4 commits from upstream-pr/2975 into main
Leyukaka commented 2026-11-27 01:01:17 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by Leyukaka on 2026-11-27T01:01:17Z.


Part 1 of #2974 (steps 1 and 2). Part of #2935. Target branch main. Step 3, binding these views on the in-process native route, will be a separate pull request.

Change:

  • Runtime (src/startup_stubs/d3d12_compute_dispatch.inl, src/startup_stubs/d3d12_xs_device.cpp, tests/startup_stream_consumer.cpp): the runtime half of #2902, which is open on main, taken unchanged, so a later merge of main should merge cleanly there.
    • The manifest reader accepts uav N tex3d|tex1d float table P OFF channels C.
    • Dispatch creates the UAV as TEXTURE3D/TEXTURE1D from the title's view record.
    • The mip and W range checks are kept, also in slot 19.
    • The consumer gains the texture-volume, texture-line, texture-volume-bad-w and texture-line-bad-mip modes.
    • If you would rather wait for #2902 to merge and reach cpp-migration, say so and I will drop these hunks.
  • Offline route (src/direct_compute_cache.cpp): format_compute_runtime_manifest writes tex3d and tex1d for a texture_uav/half4_texture_uav with image dimension 2 or 0, next to the existing tex2d/tex2da. Other dimensions and kinds stay refused, so compile_dxil --requests publishes a manifest the runtime accepts for 3D and 1D stores.
  • Test (tests/startup_compute_dispatch_texture_check.py, CMakeLists.txt): the 3D, 3D NSA and 1D store cases from #2902 now run through compile_dxil instead of gfx2hlsl.py, since the Python half of #2902 is not on this branch. CMake passes compile_dxil and the DXC directory to the existing WARP and hardware entries when they exist.

Tests. The setup was Windows 11 with an NVIDIA GeForce RTX 5080 and DXC from the Windows SDK 10.0.26100, on cpp-migration 2b678fd3 plus this commit.

  • startup_compute_dispatch_texture_hardware passed.
    • The first Dispatch publishes the request and is refused with no translation.
    • compile_dxil then writes <key>.txt with uav 0 tex3d or tex1d float table 1 64 channels 4, and <key>.cs.cso.
    • The next Dispatch matches the CPU expectation on mip one: 6,144 words for 3D and for 3D NSA, 128 for 1D.
    • The mismatched view, 3D W range and 1D mip controls are refused with the sentinels intact.
  • startup_compute_dispatch_texture_warp passed. WARP refused the PSO, so for the 3D/1D cases only the manifest was checked there.

Mutation checks, run by hand; each fails the hardware test:

  • writing a 3D UAV as tex2d in the formatter fails the manifest assertion;
  • dropping the W range check fails the texture-volume-bad-w control.

Measured on a local capture (counts and instruction shape only) with compile_dxil --jobs 8 gfx1013-direct-cs@36 --requests.

  • Of 2,689 compute requests, the number with a runtime manifest goes from 161 on 2b678fd3 to 177; the number compiled is unchanged at 388.
  • One of the 16 new manifests is for a per-frame compute pipeline of the title. It is identical, line for line, to the one the Python translator writes with #2902 applied (srv 0/1 buf, srv 2 tex2d, uav 0 tex3d float ... channels 4).
  • In a start-up run on cpp-migration b260984f, that pipeline was dispatched 17,408 times and never translated. In a later run with this change and compile_dxil, it was translated and dispatched about 17,400 times. (An earlier version of this line also linked the title staying on its first screen to this pipeline; that was not shown, see #2974.)

AI-assisted.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:issue:5519367118 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975). Originally posted by [Leyukaka](https://github.com/Leyukaka) on 2026-11-27T01:01:17Z. --- Part 1 of #2974 (steps 1 and 2). Part of #2935. Target branch `main`. Step 3, binding these views on the in-process native route, will be a separate pull request. **Change:** - **Runtime** (`src/startup_stubs/d3d12_compute_dispatch.inl`, `src/startup_stubs/d3d12_xs_device.cpp`, `tests/startup_stream_consumer.cpp`): the runtime half of #2902, which is open on `main`, taken unchanged, so a later merge of `main` should merge cleanly there. - The manifest reader accepts `uav N tex3d|tex1d float table P OFF channels C`. - Dispatch creates the UAV as `TEXTURE3D`/`TEXTURE1D` from the title's view record. - The mip and W range checks are kept, also in slot 19. - The consumer gains the `texture-volume`, `texture-line`, `texture-volume-bad-w` and `texture-line-bad-mip` modes. - If you would rather wait for #2902 to merge and reach `cpp-migration`, say so and I will drop these hunks. - **Offline route** (`src/direct_compute_cache.cpp`): `format_compute_runtime_manifest` writes `tex3d` and `tex1d` for a `texture_uav`/`half4_texture_uav` with image dimension 2 or 0, next to the existing `tex2d`/`tex2da`. Other dimensions and kinds stay refused, so `compile_dxil --requests` publishes a manifest the runtime accepts for 3D and 1D stores. - **Test** (`tests/startup_compute_dispatch_texture_check.py`, `CMakeLists.txt`): the 3D, 3D NSA and 1D store cases from #2902 now run through `compile_dxil` instead of `gfx2hlsl.py`, since the Python half of #2902 is not on this branch. CMake passes `compile_dxil` and the DXC directory to the existing WARP and hardware entries when they exist. **Tests.** The setup was Windows 11 with an NVIDIA GeForce RTX 5080 and DXC from the Windows SDK 10.0.26100, on `cpp-migration` `2b678fd3` plus this commit. - `startup_compute_dispatch_texture_hardware` passed. - The first Dispatch publishes the request and is refused with `no translation`. - `compile_dxil` then writes `<key>.txt` with `uav 0 tex3d` or `tex1d float table 1 64 channels 4`, and `<key>.cs.cso`. - The next Dispatch matches the CPU expectation on mip one: 6,144 words for 3D and for 3D NSA, 128 for 1D. - The mismatched view, 3D W range and 1D mip controls are refused with the sentinels intact. - `startup_compute_dispatch_texture_warp` passed. WARP refused the PSO, so for the 3D/1D cases only the manifest was checked there. **Mutation checks**, run by hand; each fails the hardware test: - writing a 3D UAV as `tex2d` in the formatter fails the manifest assertion; - dropping the W range check fails the `texture-volume-bad-w` control. **Measured on a local capture** (counts and instruction shape only) with `compile_dxil --jobs 8 gfx1013-direct-cs@36 --requests`. - Of 2,689 compute requests, the number with a runtime manifest goes from 161 on `2b678fd3` to 177; the number compiled is unchanged at 388. - One of the 16 new manifests is for a per-frame compute pipeline of the title. It is identical, line for line, to the one the Python translator writes with #2902 applied (`srv 0/1 buf`, `srv 2 tex2d`, `uav 0 tex3d float ... channels 4`). - In a start-up run on `cpp-migration` `b260984f`, that pipeline was dispatched 17,408 times and never translated. In a later run with this change and `compile_dxil`, it was translated and dispatched about 17,400 times. (An earlier version of this line also linked the title staying on its first screen to this pipeline; that was not shown, see #2974.) AI-assisted.
Jess-Doit commented 2026-11-27 01:25:38 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by Jess-Doit on 2026-11-27T01:25:38Z.


The view checks are scoped clearly. Please distinguish unsupported native wave-size capability from unexpected PSO failure, so a passing WARP job tells us whether the new cases actually ran. A portable shader fixture could cover the binding path independently. Ready for more review

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7207278386 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#issuecomment-7207278386). Originally posted by [Jess-Doit](https://github.com/Jess-Doit) on 2026-11-27T01:25:38Z. --- The view checks are scoped clearly. Please distinguish unsupported native wave-size capability from unexpected PSO failure, so a passing WARP job tells us whether the new cases actually ran. A portable shader fixture could cover the binding path independently. Ready for more review
Leyukaka commented 2026-11-27 01:42:57 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by Leyukaka on 2026-11-27T01:42:57Z.


Thanks. Both done in the new commit.

Wave size versus PSO failure.

  • After a published compute translation fails PSO creation, the stand-in now checks the adapter's wave capabilities, with the same OPTIONS1 test the native route uses. It logs pipeline creation failed: the adapter has no 32-lane waves when they rule out a WaveSize(32) module.
  • The texture check skips the native 3D/1D dispatch cases on WARP only for that reason, and says so. A PSO failure without that label fails the check, on WARP too.
  • The manifest records no wave size, so on an adapter without 32-lane waves any PSO failure of a published translation gets that label.

Portable fixture. The 3D and 1D cases now also run with a cs_6_0 store compiled by dxc (no WaveSize) and a hand-written manifest. It uses the same uav 0 tex3d|tex1d float table 1 64 channels 4 line and the same request key. So the binding path, the mip-one readback and the mismatched-view, bad-W and bad-mip refusals run on WARP independently of the C++ compiler.

Results on an RTX 5080 and on WARP (Windows 11, DXC from the Windows SDK 10.0.26100):

Adapter Portable 3D Portable 1D Native 3D, 3D NSA, 1D
Hardware 6,144 words 128 words match, refusals as before
WARP 6,144 words 128 words skipped: "the adapter has no 32-lane waves"

A manual mutant that never names the wave reason makes the WARP check fail.

AI-assisted.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7207518479 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#issuecomment-7207518479). Originally posted by [Leyukaka](https://github.com/Leyukaka) on 2026-11-27T01:42:57Z. --- Thanks. Both done in the new commit. **Wave size versus PSO failure.** - After a published compute translation fails PSO creation, the stand-in now checks the adapter's wave capabilities, with the same `OPTIONS1` test the native route uses. It logs `pipeline creation failed: the adapter has no 32-lane waves` when they rule out a `WaveSize(32)` module. - The texture check skips the native 3D/1D dispatch cases on WARP only for that reason, and says so. A PSO failure without that label fails the check, on WARP too. - The manifest records no wave size, so on an adapter without 32-lane waves any PSO failure of a published translation gets that label. **Portable fixture.** The 3D and 1D cases now also run with a `cs_6_0` store compiled by `dxc` (no `WaveSize`) and a hand-written manifest. It uses the same `uav 0 tex3d|tex1d float table 1 64 channels 4` line and the same request key. So the binding path, the mip-one readback and the mismatched-view, bad-W and bad-mip refusals run on WARP independently of the C++ compiler. Results on an RTX 5080 and on WARP (Windows 11, DXC from the Windows SDK 10.0.26100): | Adapter | Portable 3D | Portable 1D | Native 3D, 3D NSA, 1D | |---|---|---|---| | Hardware | 6,144 words | 128 words | match, refusals as before | | WARP | 6,144 words | 128 words | skipped: "the adapter has no 32-lane waves" | A manual mutant that never names the wave reason makes the WARP check fail. AI-assisted.
Jess-Doit commented 2026-11-27 02:04:54 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by Jess-Doit on 2026-11-27T02:04:54Z.


The two portable shader and manifest checks passed locally. The new portable fixture covers the binding path independently of native wave size. One diagnostic issue remains. A published shader with no wave-size requirement can still get a missing-32-lane-waves label if its PSO fails on that adapter, and a failed capability query gets the same label. Please keep the generic PSO failure as the primary reason and report the observed capability separately, or limit the specific reason to shaders known to require that wave size. Ready for more review

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7207815429 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#issuecomment-7207815429). Originally posted by [Jess-Doit](https://github.com/Jess-Doit) on 2026-11-27T02:04:54Z. --- The two portable shader and manifest checks passed locally. The new portable fixture covers the binding path independently of native wave size. One diagnostic issue remains. A published shader with no wave-size requirement can still get a missing-32-lane-waves label if its PSO fails on that adapter, and a failed capability query gets the same label. Please keep the generic PSO failure as the primary reason and report the observed capability separately, or limit the specific reason to shaders known to require that wave size. Ready for more review
Leyukaka commented 2026-11-27 02:13:53 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by Leyukaka on 2026-11-27T02:13:53Z.


Thanks, done in the new commit. I took the first option; the wave-size-specific reading now lives only in the test, which knows its modules declare WaveSize(32).

  • A failed published compute PSO keeps pipeline creation failed as the reason. The stand-in only adds the adapter's 32-lane wave capability next to it, as observed: pipeline creation failed (adapter has no 32-lane waves), or pipeline creation failed (adapter wave capability query failed) when CheckFeatureSupport fails. The manifest records no wave size, so the runtime no longer suggests that the shader needed one.
  • The texture check knows its native modules declare WaveSize(32), so it alone treats the no-waves observation as the explanation: it skips the native 3D, 3D NSA and 1D cases on WARP only for that line. A bare PSO failure or the query-failed form fails it.
  • The in-process native route is unchanged: it still refuses when the query fails or the capability is missing.

On the RTX 5080 and on WARP, the results are the same as in my last comment. With a mutant that drops the observation, the WARP check fails on the bare pipeline creation failed. I could not make CheckFeatureSupport fail on either adapter, so the query-failed form is not exercised by a test.

AI-assisted.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7207943047 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#issuecomment-7207943047). Originally posted by [Leyukaka](https://github.com/Leyukaka) on 2026-11-27T02:13:53Z. --- Thanks, done in the new commit. I took the first option; the wave-size-specific reading now lives only in the test, which knows its modules declare `WaveSize(32)`. - A failed published compute PSO keeps `pipeline creation failed` as the reason. The stand-in only adds the adapter's 32-lane wave capability next to it, as observed: `pipeline creation failed (adapter has no 32-lane waves)`, or `pipeline creation failed (adapter wave capability query failed)` when `CheckFeatureSupport` fails. The manifest records no wave size, so the runtime no longer suggests that the shader needed one. - The texture check knows its native modules declare `WaveSize(32)`, so it alone treats the no-waves observation as the explanation: it skips the native 3D, 3D NSA and 1D cases on WARP only for that line. A bare PSO failure or the query-failed form fails it. - The in-process native route is unchanged: it still refuses when the query fails or the capability is missing. On the RTX 5080 and on WARP, the results are the same as in my last comment. With a mutant that drops the observation, the WARP check fails on the bare `pipeline creation failed`. I could not make `CheckFeatureSupport` fail on either adapter, so the query-failed form is not exercised by a test. AI-assisted.
Jess-Doit commented 2026-11-27 03:15:54 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by Jess-Doit on 2026-11-27T03:15:54Z.


The diagnostic finding is resolved. Five scripted checks passed, including the separate capability-query failure note. The Release dispatch checks passed on both adapters, and both portable UAV cases passed on the GTX 1060. The WARP texture failure reproduced on clean main, and the native GTX 1060 pipeline failure reproduced on the prior PR head. The isolated WARP run stalled, so it adds no coverage. Ready to merge from our side

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7208842627 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#issuecomment-7208842627). Originally posted by [Jess-Doit](https://github.com/Jess-Doit) on 2026-11-27T03:15:54Z. --- The diagnostic finding is resolved. Five scripted checks passed, including the separate capability-query failure note. The Release dispatch checks passed on both adapters, and both portable UAV cases passed on the GTX 1060. The WARP texture failure reproduced on clean main, and the native GTX 1060 pipeline failure reproduced on the prior PR head. The isolated WARP run stalled, so it adds no coverage. Ready to merge from our side
R0Y00 commented 2026-11-27 04:01:26 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-27T04:01:26Z.

Review: APPROVED


Reviewed e18549cafe7f9412b896fd43cf261fdc6750498a. The published PSO failure remains the primary diagnostic; the independent adapter-capability result no longer claims a wave requirement on the shader. I rebuilt startup_stream_consumer d3d12_xs_shim compile_dxil with the Release preset and ran ctest --preset release --no-tests=error --output-on-failure -R '^startup_compute_dispatch_texture_(warp|hardware)$' on Windows 11 build 26200.9974. Both CTest entries passed. WARP (10.0.26100.9818) and RTX 4060 Laptop (32.0.16.1656) each matched 6,144 portable volume words and 128 portable line words; the incompatible views left sentinels intact. RTX also matched 6,144 words each for native volume and volume NSA and 128 for native line. WARP capability-skipped those three native subcases. The texture-input check reports the D3D12 debug layer enabled with no errors on both adapters. The merge trial with cpp-migration at e0d83759 was clean, and #2993 contains this head as an ancestor.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review:6083319304 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#pullrequestreview-6083319304). Originally posted by [R0Y00](https://github.com/R0Y00) on 2026-11-27T04:01:26Z. **Review:** APPROVED --- Reviewed `e18549cafe7f9412b896fd43cf261fdc6750498a`. The published PSO failure remains the primary diagnostic; the independent adapter-capability result no longer claims a wave requirement on the shader. I rebuilt `startup_stream_consumer d3d12_xs_shim compile_dxil` with the Release preset and ran `ctest --preset release --no-tests=error --output-on-failure -R '^startup_compute_dispatch_texture_(warp|hardware)$'` on Windows 11 build 26200.9974. Both CTest entries passed. WARP (10.0.26100.9818) and RTX 4060 Laptop (32.0.16.1656) each matched 6,144 portable volume words and 128 portable line words; the incompatible views left sentinels intact. RTX also matched 6,144 words each for native volume and volume NSA and 128 for native line. WARP capability-skipped those three native subcases. The texture-input check reports the D3D12 debug layer enabled with no errors on both adapters. The merge trial with `cpp-migration` at `e0d83759` was clean, and #2993 contains this head as an ancestor.
KelboLive commented 2026-11-27 04:26:06 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by KelboLive on 2026-11-27T04:26:06Z.

Review: COMMENTED


PR #2975 adds 3D and 1D texture UAV support to the C++ compute manifest. Good incremental work.

What works

  • Minimal diff: the direct_compute_cache.cpp switch expands the old two-case if/else to a full switch on image_dimension with default: nullopt.
  • Runtime dispatch: volume_uav_range_error() extracts 3D W-range validation into a reusable inline function.
  • ComputeTranslation struct replaces bool array with D3D12_UAV_DIMENSION uav_dimension, giving a typed discriminator.
  • Test fixture gains texture-volume, texture-line, texture-volume-bad-w, texture-line-bad-mip modes.
  • CMakeLists.txt conditionally passes compile_dxil and DXC SDK paths to the texture test when the tools exist.

Issues

  1. std::min type deduction: (std::min)(view.MipSlice, 15u) mixes UINT and unsigned int. Consider static_cast(15u) for portability.
  2. adapter_32_lane_waves() caching: ensure the static local returns a cached value rather than re-querying on every Dispatch.
  3. Stale manifest compatibility: uav_dimension defaults to UNKNOWN (zero-initialized). The dispatch path must check this field rather than array for 3D/1D dispatches.
  4. Test 3D resource: MipLevels=2, view on mip 1 where depth=3. FirstWSlice=1, WSize=~0u covers slices 1 and 2. The bad-w case uses WSize=6 which correctly triggers refusal (6 > 3-1=2).

Recommendations

  • Add comment near uav_dimension noting it replaces array.
  • Ensure adapter_32_lane_waves() caches its result.
  • Consider a one-time runtime log when tex3d/tex1d manifests are accepted.

Overall: clean, correct change. The dimension switch is easier to maintain than the previous binary condition.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review:6083479272 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#pullrequestreview-6083479272). Originally posted by [KelboLive](https://github.com/KelboLive) on 2026-11-27T04:26:06Z. **Review:** COMMENTED --- PR #2975 adds 3D and 1D texture UAV support to the C++ compute manifest. Good incremental work. ## What works - Minimal diff: the direct_compute_cache.cpp switch expands the old two-case if/else to a full switch on image_dimension with default: nullopt. - Runtime dispatch: volume_uav_range_error() extracts 3D W-range validation into a reusable inline function. - ComputeTranslation struct replaces bool array with D3D12_UAV_DIMENSION uav_dimension, giving a typed discriminator. - Test fixture gains texture-volume, texture-line, texture-volume-bad-w, texture-line-bad-mip modes. - CMakeLists.txt conditionally passes compile_dxil and DXC SDK paths to the texture test when the tools exist. ## Issues 1. std::min type deduction: (std::min)(view.MipSlice, 15u) mixes UINT and unsigned int. Consider static_cast<UINT>(15u) for portability. 2. adapter_32_lane_waves() caching: ensure the static local returns a cached value rather than re-querying on every Dispatch. 3. Stale manifest compatibility: uav_dimension defaults to UNKNOWN (zero-initialized). The dispatch path must check this field rather than array for 3D/1D dispatches. 4. Test 3D resource: MipLevels=2, view on mip 1 where depth=3. FirstWSlice=1, WSize=~0u covers slices 1 and 2. The bad-w case uses WSize=6 which correctly triggers refusal (6 > 3-1=2). ## Recommendations - Add comment near uav_dimension noting it replaces array. - Ensure adapter_32_lane_waves() caches its result. - Consider a one-time runtime log when tex3d/tex1d manifests are accepted. Overall: clean, correct change. The dimension switch is easier to maintain than the previous binary condition.
KelboLive commented 2026-11-27 04:26:58 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by KelboLive on 2026-11-27T04:26:58Z.

Review: COMMENTED


PR #2975 adds 3D and 1D texture UAV support to the C++ compute manifest.

What works

  • Minimal diff: direct_compute_cache.cpp switch replaces binary if/else with a full dimension switch, default: nullopt keeps unmapped dims refused.
  • runtime: volume_uav_range_error() extracts 3D W-range validation into a reusable inline function.
  • struct ComputeTranslation: replaces bool array with D3D12_UAV_DIMENSION uav_dimension, typed discriminator.
  • test fixture gains texture-volume, texture-line, texture-volume-bad-w, texture-line-bad-mip modes.
  • CMakeLists.txt conditionally passes compile_dxil and DXC SDK paths to texture test when tools exist.

Issues

  1. std::min type deduction: (std::min)(view.MipSlice, 15u) mixes UINT and unsigned int. Consider static_cast(15u) for portability.
  2. adapter_32_lane_waves() caching: ensure the static local returns cached value rather than re-querying each Dispatch.
  3. Stale manifest compatibility: uav_dimension defaults to UNKNOWN (zero-init). The dispatch path must check this field, not array, for tex3d/tex1d dispatches.
  4. Test resource: MipLevels=2, view on mip 1 where depth=3. FirstWSlice=1, WSize=~0u covers slices 1-2 (correct). bad-w uses WSize=6, 6 > 2 triggers refusal (correct).

Recommendations

  • Add comment near uav_dimension noting it replaces array.
  • Ensure adapter_32_lane_waves() caches its result.
  • One-time runtime log when tex3d/tex1d manifests are accepted.

Overall: clean, correct change. The dimension switch is easier to maintain.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review:6083483783 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#pullrequestreview-6083483783). Originally posted by [KelboLive](https://github.com/KelboLive) on 2026-11-27T04:26:58Z. **Review:** COMMENTED --- PR #2975 adds 3D and 1D texture UAV support to the C++ compute manifest. ## What works - Minimal diff: direct_compute_cache.cpp switch replaces binary if/else with a full dimension switch, default: nullopt keeps unmapped dims refused. - runtime: volume_uav_range_error() extracts 3D W-range validation into a reusable inline function. - struct ComputeTranslation: replaces bool array with D3D12_UAV_DIMENSION uav_dimension, typed discriminator. - test fixture gains texture-volume, texture-line, texture-volume-bad-w, texture-line-bad-mip modes. - CMakeLists.txt conditionally passes compile_dxil and DXC SDK paths to texture test when tools exist. ## Issues 1. std::min type deduction: (std::min)(view.MipSlice, 15u) mixes UINT and unsigned int. Consider static_cast<UINT>(15u) for portability. 2. adapter_32_lane_waves() caching: ensure the static local returns cached value rather than re-querying each Dispatch. 3. Stale manifest compatibility: uav_dimension defaults to UNKNOWN (zero-init). The dispatch path must check this field, not array, for tex3d/tex1d dispatches. 4. Test resource: MipLevels=2, view on mip 1 where depth=3. FirstWSlice=1, WSize=~0u covers slices 1-2 (correct). bad-w uses WSize=6, 6 > 2 triggers refusal (correct). ## Recommendations - Add comment near uav_dimension noting it replaces array. - Ensure adapter_32_lane_waves() caches its result. - One-time runtime log when tex3d/tex1d manifests are accepted. Overall: clean, correct change. The dimension switch is easier to maintain.
Leyukaka commented 2026-11-27 04:29:15 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by Leyukaka on 2026-11-27T04:29:15Z.


Thanks. Answers to the three points:

  1. UINT is unsigned int in the Windows headers, so both arguments of (std::min)(view.MipSlice, 15u) have the same type.
  2. adapter_32_lane_waves() is not queried per Dispatch. It runs only after a published translation's PSO creation fails, and at most once per key on the in-process route, which tries each key once.
  3. Among output slots, uav_dimension stays UNKNOWN only for raw buffer UAVs. Both the manifest reader and the in-process route (#2993) set a known dimension for every texture UAV slot, and the dispatch path picks the view from that field.

AI-assisted.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7209836722 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#issuecomment-7209836722). Originally posted by [Leyukaka](https://github.com/Leyukaka) on 2026-11-27T04:29:15Z. --- Thanks. Answers to the three points: 1. `UINT` is `unsigned int` in the Windows headers, so both arguments of `(std::min)(view.MipSlice, 15u)` have the same type. 2. `adapter_32_lane_waves()` is not queried per Dispatch. It runs only after a published translation's PSO creation fails, and at most once per key on the in-process route, which tries each key once. 3. Among output slots, `uav_dimension` stays `UNKNOWN` only for raw buffer UAVs. Both the manifest reader and the in-process route (#2993) set a known dimension for every texture UAV slot, and the dispatch path picks the view from that field. AI-assisted.
MasterDomino commented 2026-11-27 05:00:46 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by MasterDomino on 2026-11-27T05:00:46Z.


Title-run results for e18549ca, before merging. This is not a code review; R0Y00's approval and my test results above stand. I am holding the merge on one start-up result that needs your eyes.

Setup: Windows 11 26300.9974, RX 9070 XT (driver 32.0.32029.2010), release. Each run lasts 300 s with the same scripted inputs. The shader cache is the same local rev-28 cache, copied fresh for each run.

  • "PR" builds are cpp-migration e0d83759 + this PR + #2986, #2996, #2998 and #3003 (all four have since merged).
  • "inject" runs first run compile_dxil gfx1013-direct-cs@0 --requests over a copy of the request files into a separate directory. Then, for each compute key the cache has no <key>.txt for, they copy that key's <key>.txt and <key>.cs.cso into the run's cache.

Start-up progress is measured as file opens by the title over time. The .txt count includes requests published during the run.

Run Build Injected manifests (with tex3d/tex1d) File opens at 120 / 180 / 240 / 290 s Compute keys dispatched at the end
base e0d83759 none 5,509 / 5,568 / 5,640 / 6,371 9
default PR none 5,497 / 5,557 / 5,629 / 6,371 10
base-inject e0d83759 64 (0) 5,508 / 5,567 / 5,639 / 6,380 10
inject2 PR 64 (0) 5,500 / 5,559 / 5,631 / 6,361 9
inject-no3d PR 65 (0) 5,515 / 5,575 / 5,647 / 6,378 564
inject PR 81 (16) 5,425 / 5,425 / 5,444 / 5,444 3
inject3 PR 81 (16) 5,430 / 5,430 / 5,442 / 6,108 10
  • Default runs: this PR changes nothing in the default configuration (base vs default), and natively published manifests without 3D/1D outputs are fine on both builds.
  • The two stalled runs: both are the runs that also loaded the 16 manifests with a tex3d/tex1d output. In both, the title stops opening files at about 110 s. One run never recovers within 300 s, and the other resumes at about 250 s. Frames keep being presented at about 28 fps in every run.

What the stand-in does in the stalled runs: three pipelines now load as translated. They are the per-frame compute pipeline you described on #2974 (srv 0/1 buf, srv 2 tex2d, uav 0 tex3d float table 1 32 channels 4) and two pipelines dispatched next to it (srv 0/1 buf, uav 0 tex1d float table 1 32 channels 4). On this branch gfx2hlsl.py refuses all three with image_store on SQ_RSRC_IMG_3D/1D: only 2D images are lowered. Every one of their Dispatches is then refused: an input is in a placed buffer that does not alias title memory. So the native program never runs. On e0d83759 the same three keys are refused earlier with no translation. Both paths leave the outputs untouched as far as I can see, yet only the first one coincides with the stall.

I have not found the cause. It could be:

  • something the translated-but-refused path does that the untranslated path does not, such as resource or view creation for the 3D UAV, or state left behind;
  • timing in that refusal path;
  • something specific to these manifests.

Why I'm holding it: without this PR, compile_dxil cannot publish these manifests, so the stall cannot happen. With it, compile_dxil --requests/--watch publishing into the runtime cache reaches it. That is the workflow this PR and #2993 build on. Could you check whether the refused-after-translation path for a 3D UAV binding has a side effect the no translation path does not? With your capture, the same injection should reproduce it.

AI-assisted; the runs above were done locally, counts only.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7210275146 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#issuecomment-7210275146). Originally posted by [MasterDomino](https://github.com/MasterDomino) on 2026-11-27T05:00:46Z. --- Title-run results for `e18549ca`, before merging. This is not a code review; R0Y00's approval and my test results above stand. I am holding the merge on one start-up result that needs your eyes. **Setup:** Windows 11 26300.9974, RX 9070 XT (driver 32.0.32029.2010), release. Each run lasts 300 s with the same scripted inputs. The shader cache is the same local rev-28 cache, copied fresh for each run. - **"PR" builds** are `cpp-migration` `e0d83759` + this PR + #2986, #2996, #2998 and #3003 (all four have since merged). - **"inject" runs** first run `compile_dxil gfx1013-direct-cs@0 --requests` over a copy of the request files into a separate directory. Then, for each compute key the cache has no `<key>.txt` for, they copy that key's `<key>.txt` and `<key>.cs.cso` into the run's cache. Start-up progress is measured as file opens by the title over time. The `.txt` count includes requests published during the run. | Run | Build | Injected manifests (with `tex3d`/`tex1d`) | File opens at 120 / 180 / 240 / 290 s | Compute keys dispatched at the end | |---|---|---|---|---| | base | `e0d83759` | none | 5,509 / 5,568 / 5,640 / 6,371 | 9 | | default | PR | none | 5,497 / 5,557 / 5,629 / 6,371 | 10 | | base-inject | `e0d83759` | 64 (0) | 5,508 / 5,567 / 5,639 / 6,380 | 10 | | inject2 | PR | 64 (0) | 5,500 / 5,559 / 5,631 / 6,361 | 9 | | inject-no3d | PR | 65 (0) | 5,515 / 5,575 / 5,647 / 6,378 | 564 | | **inject** | PR | **81 (16)** | **5,425 / 5,425 / 5,444 / 5,444** | 3 | | **inject3** | PR | **81 (16)** | **5,430 / 5,430 / 5,442 / 6,108** | 10 | - **Default runs:** this PR changes nothing in the default configuration (base vs default), and natively published manifests without 3D/1D outputs are fine on both builds. - **The two stalled runs:** both are the runs that also loaded the 16 manifests with a `tex3d`/`tex1d` output. In both, the title stops opening files at about 110 s. One run never recovers within 300 s, and the other resumes at about 250 s. Frames keep being presented at about 28 fps in every run. **What the stand-in does in the stalled runs:** three pipelines now load as translated. They are the per-frame compute pipeline you described on #2974 (`srv 0/1 buf`, `srv 2 tex2d`, `uav 0 tex3d float table 1 32 channels 4`) and two pipelines dispatched next to it (`srv 0/1 buf`, `uav 0 tex1d float table 1 32 channels 4`). On this branch `gfx2hlsl.py` refuses all three with `image_store on SQ_RSRC_IMG_3D/1D: only 2D images are lowered`. Every one of their Dispatches is then refused: `an input is in a placed buffer that does not alias title memory`. So the native program never runs. On `e0d83759` the same three keys are refused earlier with `no translation`. Both paths leave the outputs untouched as far as I can see, yet only the first one coincides with the stall. I have not found the cause. It could be: - something the translated-but-refused path does that the untranslated path does not, such as resource or view creation for the 3D UAV, or state left behind; - timing in that refusal path; - something specific to these manifests. **Why I'm holding it:** without this PR, `compile_dxil` cannot publish these manifests, so the stall cannot happen. With it, `compile_dxil --requests`/`--watch` publishing into the runtime cache reaches it. That is the workflow this PR and #2993 build on. Could you check whether the refused-after-translation path for a 3D UAV binding has a side effect the `no translation` path does not? With your capture, the same injection should reproduce it. AI-assisted; the runs above were done locally, counts only.
Leyukaka commented 2026-11-27 05:14:05 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by Leyukaka on 2026-11-27T05:14:05Z.


Thanks for the runs. I compared the two paths in the stand-in at e18549ca: a key whose manifest loads and whose every Dispatch is then refused, against a key with no manifest. I found no side effect of the refusal that the title could wait on, so I cannot explain the stall yet.

The refusal path.

  • In record_translated_dispatch, the binding loop stops at the first reason. For this layout that is input 0 or 1: srv 0/1 buf table, refused by indirect_table_buffer with "an input is in a placed buffer that does not alias title memory".
  • The helpers it calls before that only read: the table record, list_upload_range, placed_buffer_range and list_copied_gpu_range.
  • The 2D input, the 3D/1D output, upload_texture, require_state, the descriptor heap writes and the Dispatch are never reached. The function returns the reason with nothing recorded on the list.
  • The stand-in keeps first_refusal, a counter, one "first refused input" log line per key and up to 16 shared "refused" lines.
  • list_dispatch discards the reason. The ExecuteIndirect caller only counts and logs it, as it does for no translation.
  • Nothing else in src/startup_stubs reads a compute key's translation state.
  • Once per key, the loaded path creates a root signature and a PSO under draw_lock.

One difference: manifest polling.

  • A key with no manifest keeps retry_manifest_at set, so it reopens <key>.txt on a Dispatch at most once per second.
  • A key whose manifest was read, usable or not, never retries. So loading manifests for those three keys removes up to one open per key per second.
  • files.txt from run.ps1 records the stand-in's own opens as well. In one of my runs, 199,667 of its 208,352 lines are NtCreateFile opens of <key>.txt in the shader cache, spread over 1,650 keys (draw and compute).

If your count includes those paths, this could account for the missing ~1 open per second between 120 and 240 s, at most. It does not explain the missing step of about 730 opens after 240 s, nor the 3 keys dispatched at the end of inject. Could you check whether your count excludes the shader cache directory? Either way, the stall needs a closer look at what the title waits for after 110 s in those runs. I will try to reproduce it with my capture.

AI-assisted.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7210461948 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#issuecomment-7210461948). Originally posted by [Leyukaka](https://github.com/Leyukaka) on 2026-11-27T05:14:05Z. --- Thanks for the runs. I compared the two paths in the stand-in at `e18549ca`: a key whose manifest loads and whose every Dispatch is then refused, against a key with no manifest. I found no side effect of the refusal that the title could wait on, so I cannot explain the stall yet. **The refusal path.** - In `record_translated_dispatch`, the binding loop stops at the first reason. For this layout that is input 0 or 1: `srv 0/1 buf table`, refused by `indirect_table_buffer` with "an input is in a placed buffer that does not alias title memory". - The helpers it calls before that only read: the table record, `list_upload_range`, `placed_buffer_range` and `list_copied_gpu_range`. - The 2D input, the 3D/1D output, `upload_texture`, `require_state`, the descriptor heap writes and the Dispatch are never reached. The function returns the reason with nothing recorded on the list. - The stand-in keeps `first_refusal`, a counter, one "first refused input" log line per key and up to 16 shared "refused" lines. - `list_dispatch` discards the reason. The ExecuteIndirect caller only counts and logs it, as it does for `no translation`. - Nothing else in `src/startup_stubs` reads a compute key's translation state. - Once per key, the loaded path creates a root signature and a PSO under `draw_lock`. **One difference: manifest polling.** - A key with no manifest keeps `retry_manifest_at` set, so it reopens `<key>.txt` on a Dispatch at most once per second. - A key whose manifest was read, usable or not, never retries. So loading manifests for those three keys removes up to one open per key per second. - `files.txt` from `run.ps1` records the stand-in's own opens as well. In one of my runs, 199,667 of its 208,352 lines are `NtCreateFile` opens of `<key>.txt` in the shader cache, spread over 1,650 keys (draw and compute). If your count includes those paths, this could account for the missing ~1 open per second between 120 and 240 s, at most. It does not explain the missing step of about 730 opens after 240 s, nor the 3 keys dispatched at the end of `inject`. Could you check whether your count excludes the shader cache directory? Either way, the stall needs a closer look at what the title waits for after 110 s in those runs. I will try to reproduce it with my capture. AI-assisted.
sydney-0o commented 2026-11-27 11:11:22 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by sydney-0o on 2026-11-27T11:11:22Z.


I opened draft #3049 on main to combine this work with #2993, preserving your commit authorship. #2902 is already in the base, so the draft adds the C++ tex1d/tex3d manifest support and reuses the existing runtime view checks. Offline readback passed on a GTX 1080 Ti with app-local Agility SDK 1.620.2, including the bad mip, W range and mismatched-view controls. The startup stall reported here still needs a separate before/after run.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7216783983 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#issuecomment-7216783983). Originally posted by [sydney-0o](https://github.com/sydney-0o) on 2026-11-27T11:11:22Z. --- I opened draft #3049 on `main` to combine this work with #2993, preserving your commit authorship. #2902 is already in the base, so the draft adds the C++ `tex1d`/`tex3d` manifest support and reuses the existing runtime view checks. Offline readback passed on a GTX 1080 Ti with app-local Agility SDK 1.620.2, including the bad mip, W range and mismatched-view controls. The startup stall reported here still needs a separate before/after run.
R0Y00 commented 2026-11-27 11:18:55 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-27T11:18:55Z.


Retargeted to main. My local integration on e04217f4 preserves #2902, compute root SRVs and the Python-published 1D/3D fixtures while adding separate compile_dxil publication coverage. I also saw #3049, which integrates both original PRs and preserves Leyukaka's commits. I am checking it as the combined integration candidate. The original-program startup observation with injected manifests is still open. For a comparable run on current main, please report title file opens separately from shader-cache paths, and record translated/refused dispatch counts for the three keys.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7216930888 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#issuecomment-7216930888). Originally posted by [R0Y00](https://github.com/R0Y00) on 2026-11-27T11:18:55Z. --- Retargeted to main. My local integration on e04217f4 preserves #2902, compute root SRVs and the Python-published 1D/3D fixtures while adding separate compile_dxil publication coverage. I also saw #3049, which integrates both original PRs and preserves Leyukaka's commits. I am checking it as the combined integration candidate. The original-program startup observation with injected manifests is still open. For a comparable run on current main, please report title file opens separately from shader-cache paths, and record translated/refused dispatch counts for the three keys.
Jess-Doit commented 2026-11-27 15:59:00 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by Jess-Doit on 2026-11-27T15:59:00Z.


I checked the copied-buffer refusal on the current head with source-built 1D and 3D output manifests. On the GTX 1060 and in-box WARP, both manifests refused the first input, recorded zero translated dispatches, and left all 320 fixture readback words identical to the no-manifest control. This verifies early refusal and write suppression in the fixture. The startup stall and the effect of manifest polling remain open on current main. Ready for more review

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7222715254 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#issuecomment-7222715254). Originally posted by [Jess-Doit](https://github.com/Jess-Doit) on 2026-11-27T15:59:00Z. --- I checked the copied-buffer refusal on the current head with source-built 1D and 3D output manifests. On the GTX 1060 and in-box WARP, both manifests refused the first input, recorded zero translated dispatches, and left all 320 fixture readback words identical to the no-manifest control. This verifies early refusal and write suppression in the fixture. The startup stall and the effect of manifest polling remain open on current main. Ready for more review
R0Y00 commented 2026-11-27 16:06:36 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-27T16:06:36Z.


Thanks for checking the copied-buffer refusal on both adapters. The GTX 1060 and inbox WARP results cover the early-refusal control: both 1D and 3D manifests forward zero translated dispatches and preserve all 320 words. I’m keeping that fixture result separate from the open startup and manifest-polling comparison. #3049 is still the combined integration candidate on main; keep this PR linked for the original contribution and review.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7222867475 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#issuecomment-7222867475). Originally posted by [R0Y00](https://github.com/R0Y00) on 2026-11-27T16:06:36Z. --- Thanks for checking the copied-buffer refusal on both adapters. The GTX 1060 and inbox WARP results cover the early-refusal control: both 1D and 3D manifests forward zero translated dispatches and preserve all 320 words. I’m keeping that fixture result separate from the open startup and manifest-polling comparison. #3049 is still the combined integration candidate on `main`; keep this PR linked for the original contribution and review.
JohnConnorNPC commented 2026-11-28 07:33:55 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by JohnConnorNPC on 2026-11-28T07:33:55Z.


Thanks for this. I reviewed head e18549ca against current main (c3204a9c). The runtime half is already on main through #2902, so what's new here is the 4-channel tex3d/tex1d manifest lines and the wave note on PSO failure. Three things need fixing before this can land:

  1. It conflicts with main. git merge-tree --write-tree --name-only origin/main e18549ca exits 1 in 3 files: dispatch.inl, stream_consumer.cpp and texture_check.py. The first two can take main's side (root SRVs, bufhalf, uint atomics, channels 1–4). texture_check.py needs a redesign: both sides define store_3d1d with different signatures, and main expects len(sys.argv) not in (4, 5) with two-mips while this PR expects (4, 6) with compile_dxil + sdk.
  2. A clean-merged hunk loses a #3268 refusal reason. The new switch ends with default: return std::nullopt;, where main has return refuse(view_shape("UAV", b));. On the merged tree, main's tests/native_compute_manifest_reasons.cpp case "UAV kind texture_uav cube" (image_dimension = 3) would get an empty reason and exit 1. I traced this from source and didn't build it. default: return refuse(view_shape("UAV", b)); would fix it.
  3. The 11:18 request is still open: report title file opens separately from shader-cache paths, and record translated/refused dispatch counts for the three keys, on current main.

Non-blocking:

  • No CPU check pins the new lines. native_compute_manifest_reasons.cpp calls the formatter without a GPU, so accepted cases for texture_uav dim 0 → uav 0 tex1d … channels 4 and dim 2 → tex3d, each with a mutant, would cover them. CI's ctest --preset pr log has 0 startup_compute_dispatch_texture lines.
  • docs/startup-runtime.md still says the runtime half "is ported to cpp-migration". It has been on main since #2902.
  • #3049 re-applies this PR as 127d8823 (git merge-base --is-ancestor e18549ca <#3049 head> → 1), so only one of the two should merge.

Environment: Linux, static review and merge-tree only. I did no build, WARP or GPU run.

This comment was AI-assisted.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7236021076 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#issuecomment-7236021076). Originally posted by [JohnConnorNPC](https://github.com/JohnConnorNPC) on 2026-11-28T07:33:55Z. --- Thanks for this. I reviewed head `e18549ca` against current `main` (`c3204a9c`). The runtime half is already on `main` through #2902, so what's new here is the 4-channel `tex3d`/`tex1d` manifest lines and the wave note on PSO failure. Three things need fixing before this can land: 1. **It conflicts with `main`.** `git merge-tree --write-tree --name-only origin/main e18549ca` exits 1 in 3 files: dispatch.inl, stream_consumer.cpp and texture_check.py. The first two can take main's side (root SRVs, bufhalf, uint atomics, channels 1–4). texture_check.py needs a redesign: both sides define `store_3d1d` with different signatures, and main expects `len(sys.argv) not in (4, 5)` with `two-mips` while this PR expects `(4, 6)` with compile_dxil + sdk. 2. **A clean-merged hunk loses a #3268 refusal reason.** The new switch ends with `default: return std::nullopt;`, where main has `return refuse(view_shape("UAV", b));`. On the merged tree, main's `tests/native_compute_manifest_reasons.cpp` case "UAV kind texture_uav cube" (`image_dimension = 3`) would get an empty reason and exit 1. I traced this from source and didn't build it. `default: return refuse(view_shape("UAV", b));` would fix it. 3. **The 11:18 request is still open:** report title file opens separately from shader-cache paths, and record translated/refused dispatch counts for the three keys, on current `main`. Non-blocking: - No CPU check pins the new lines. native_compute_manifest_reasons.cpp calls the formatter without a GPU, so accepted cases for texture_uav dim 0 → `uav 0 tex1d … channels 4` and dim 2 → `tex3d`, each with a mutant, would cover them. CI's `ctest --preset pr` log has 0 `startup_compute_dispatch_texture` lines. - docs/startup-runtime.md still says the runtime half "is ported to `cpp-migration`". It has been on `main` since #2902. - #3049 re-applies this PR as 127d8823 (`git merge-base --is-ancestor e18549ca <#3049 head>` → 1), so only one of the two should merge. Environment: Linux, static review and merge-tree only. I did no build, WARP or GPU run. This comment was AI-assisted.
Leyukaka commented 2026-11-29 09:17:44 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by Leyukaka on 2026-11-29T09:17:44Z.


Merged main (a99e05f4) into the branch; new head 8364ecd1. A merge rather than a rebase, so the approved commits stay as they are and only the resolution is new (git show --remerge-diff 8364ecd1). The approval is on e18549ca, so the new head needs a re-review.

Conflicts (main already has the 3D/1D dispatch path and its fixtures from #2902):

  • src/direct_compute_cache.cpp: kept our tex1d/tex2d/tex3d/tex2da switch for texture_uav and half4_texture_uav; its default: now returns main's refuse(view_shape("UAV", b)).
  • src/startup_stubs/d3d12_compute_dispatch.inl, tests/startup_stream_consumer.cpp: took main's side in every hunk, ours was a subset. The 32-lane wave note on PSO failures merged without conflict.
  • tests/startup_compute_dispatch_texture_check.py: dropped our hand-written portable cs_6_0 fixture for main's gfx2hlsl.py translation (store_3d1d, V.FORMS); kept the native compile_dxil cases, now run through main's store_3d1d. The docs paragraph follows.

Tests on 8364ecd1: startup_compute_dispatch_texture_{warp,hardware}, startup_compute_dispatch_two_mips_{warp,hardware} and native_compute_manifest_reasons pass (5/5). On a hardware adapter the translated and native volume, volume-nsa (6144 words) and line (128 words) readbacks match; on WARP the native 3D/1D cases skip (no 32-lane waves) and the translated ones match.

Mutation: case 0: tex = "tex1d" -> "tex2d" in direct_compute_cache.cpp fails startup_compute_dispatch_texture_hardware at assert f'uav 0 tex{dim} float table 1 64 channels 4' in manifest (the manifest has uav 0 tex2d float table 1 64 channels 4).

git merge-tree --write-tree of 8364ecd1 with current main (1a0120ba) is clean; the tests above ran with a99e05f4 merged, not 1a0120ba.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7253667531 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#issuecomment-7253667531). Originally posted by [Leyukaka](https://github.com/Leyukaka) on 2026-11-29T09:17:44Z. --- Merged `main` (a99e05f4) into the branch; new head 8364ecd1. A merge rather than a rebase, so the approved commits stay as they are and only the resolution is new (`git show --remerge-diff 8364ecd1`). The approval is on e18549ca, so the new head needs a re-review. Conflicts (`main` already has the 3D/1D dispatch path and its fixtures from #2902): - `src/direct_compute_cache.cpp`: kept our tex1d/tex2d/tex3d/tex2da switch for `texture_uav` and `half4_texture_uav`; its `default:` now returns main's `refuse(view_shape("UAV", b))`. - `src/startup_stubs/d3d12_compute_dispatch.inl`, `tests/startup_stream_consumer.cpp`: took main's side in every hunk, ours was a subset. The 32-lane wave note on PSO failures merged without conflict. - `tests/startup_compute_dispatch_texture_check.py`: dropped our hand-written portable `cs_6_0` fixture for main's `gfx2hlsl.py` translation (`store_3d1d`, `V.FORMS`); kept the native `compile_dxil` cases, now run through main's `store_3d1d`. The docs paragraph follows. Tests on 8364ecd1: `startup_compute_dispatch_texture_{warp,hardware}`, `startup_compute_dispatch_two_mips_{warp,hardware}` and `native_compute_manifest_reasons` pass (5/5). On a hardware adapter the translated and native volume, volume-nsa (6144 words) and line (128 words) readbacks match; on WARP the native 3D/1D cases skip (no 32-lane waves) and the translated ones match. Mutation: `case 0: tex = "tex1d"` -> `"tex2d"` in `direct_compute_cache.cpp` fails `startup_compute_dispatch_texture_hardware` at `assert f'uav 0 tex{dim} float table 1 64 channels 4' in manifest` (the manifest has `uav 0 tex2d float table 1 64 channels 4`). `git merge-tree --write-tree` of 8364ecd1 with current `main` (1a0120ba) is clean; the tests above ran with a99e05f4 merged, not 1a0120ba.
Leyukaka commented 2026-11-29 12:24:02 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by Leyukaka on 2026-11-29T12:24:02Z.


Closing in favour of #3398, which carries this PR's changes: the tex1d/tex2d/tex3d/tex2da switch in the C++ manifest formatter, the adapter wave capability reported next to a PSO creation failure, and the native 3D/1D store fixture.
Two differences: in #3398 the native 3D/1D cases run as a separate startup_compute_dispatch_texture_native_<adapter> test instead of inside startup_compute_dispatch_texture_<adapter>, and the hardware result paragraph this PR adds to docs/startup-runtime.md is not carried over.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7255784584 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2975#issuecomment-7255784584). Originally posted by [Leyukaka](https://github.com/Leyukaka) on 2026-11-29T12:24:02Z. --- Closing in favour of #3398, which carries this PR's changes: the `tex1d`/`tex2d`/`tex3d`/`tex2da` switch in the C++ manifest formatter, the adapter wave capability reported next to a PSO creation failure, and the native 3D/1D store fixture. Two differences: in #3398 the native 3D/1D cases run as a separate `startup_compute_dispatch_texture_native_<adapter>` test instead of inside `startup_compute_dispatch_texture_<adapter>`, and the hardware result paragraph this PR adds to `docs/startup-runtime.md` is not carried over.

Pull request closed

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!2975
No description provided.