D3D12.X: promote R9G9B9E5_SHAREDEXP render/UAV targets to R11G11B10_FLOAT #605

Manually merged
github merged 1 commit from gh-pr/605/head into gh-pr/605/base 2026-11-26 04:26:57 +00:00
Owner

@⁠0x6461726B on GitHub · 2026-11-24 02:24 UTC · original
0x6461726B:d3d12x-r9g9b9e5-target → main · +19 −2 · 1 files · 1 commits · merged 2026-11-24 21:14 UTC

In Xbox Series S (lockhart) mode, a retail title creates a 1920x1080 render target / UAV (ALLOW_RENDER_TARGET | ALLOW_UNORDERED_ACCESS, flags 0x300005) with DXGI_FORMAT_R9G9B9E5_SHAREDEXP (67) during startup. PC D3D12 forbids render-target and UAV flags on format 67 and fails CreatePlacedResourceX with E_INVALIDARG (0x80070057), crashing the title (0x80000003) before presenting frames.

Promoting format-67 resources with RT/UAV flags and their RTV/UAV/SRV views to DXGI_FORMAT_R11G11B10_FLOAT (26, same 32 bpp unsigned HDR float with full PC RTV/UAV/SRV support), while keeping sampled-only format-67 textures as format 67, unblocks Series S startup without changing Anaconda behavior.

What is in it

  • Promote format 67 to 26 in pc_resource_desc when ALLOW_RENDER_TARGET or ALLOW_UNORDERED_ACCESS (flags & 5 != 0) is set, and map 67 => 26 in pc_target_format and (26, 67) => 26 in pc_shader_view_format (crates/xcl/src/hle/d3d12x/device_x.rs), plus unit test cases in console_depth_buffers_and_their_views_are_the_pcs.

Tested

  • Hardware & OS: NVIDIA GeForce RTX 2060 (driver 32.0.16.2135), Intel Core i5-10400F, Microsoft Windows 11 Pro (Build 26300), rustc 1.100.0 (0ef1bc386 2026-11-09)
  • cargo test --workspace -- --test-threads=4 (debug): 684 passed, 0 failed, 41 ignored
    • SKIPPED gpu::recomp::tests::gpu_geometry_wave32_prefix_count_over_a_mask: no wave64
    • SKIPPED gpu::recomp::tests::gpu_wave32_program_in_wave64_hardware: no wave64
  • Series S (lockhart) smoke run (retail title, 60 s, release): main crashed at startup (exit: 0x80000003, 2 crashes, no frame count logged); this branch ran the full 60 s with exit: 0x0, 916 frames shown (PresentX 916), 0 crashes, 0 device removals.

Regression run

xcl-smoke v1
commit: 9ce2070eccf436d7bd38601c90407da447df34f3
gpu: NVIDIA GeForce RTX 2060
title: 2c508222
seconds: 60
exit: 0x80000003
frames shown: none logged (the run did not reach its end)
presents per 2 s (last 3): 60 58 27
device removals: 0
crashes: 2
peak commit: 15460 MB
xcl-smoke v1
commit: c3d350a5729d7559d00554facc622c6d1c1b9bb6
gpu: NVIDIA GeForce RTX 2060
title: 2c508222
seconds: 60
exit: 0x0
frames shown: 916 (PresentX 916)
presents per 2 s (last 3): 58 39 18
device removals: 0
crashes: 0
peak commit: 15555 MB

Not tested

  • AMD GPUs and native wave64 hardware (no wave64 skipped the two wave64 GPU tests above).
  • Other Series S titles or titles with sampled-only vs RT/UAV R9G9B9E5 precision edge cases.

AI use

  • Google Antigravity (Gemini 4 Neon High): diagnosed the CreatePlacedResourceX format-67 E_INVALIDARG crash from the log, wrote the fix and unit test expansion in device_x.rs, ran the test suite and smoke runs, and drafted this description.
**@⁠0x6461726B** on GitHub · 2026-11-24 02:24 UTC · [original](https://github.com/xcl-dev/xcl/pull/605) `0x6461726B:d3d12x-r9g9b9e5-target` → `main` · +19 −2 · 1 files · 1 commits · merged 2026-11-24 21:14 UTC In Xbox Series S (`lockhart`) mode, a retail title creates a `1920x1080` render target / UAV (`ALLOW_RENDER_TARGET | ALLOW_UNORDERED_ACCESS`, flags `0x300005`) with `DXGI_FORMAT_R9G9B9E5_SHAREDEXP` (67) during startup. PC D3D12 forbids render-target and UAV flags on format 67 and fails `CreatePlacedResourceX` with `E_INVALIDARG` (`0x80070057`), crashing the title (`0x80000003`) before presenting frames. Promoting format-67 resources with RT/UAV flags and their RTV/UAV/SRV views to `DXGI_FORMAT_R11G11B10_FLOAT` (26, same 32 bpp unsigned HDR float with full PC RTV/UAV/SRV support), while keeping sampled-only format-67 textures as format 67, unblocks Series S startup without changing Anaconda behavior. **What is in it** - Promote format `67` to `26` in `pc_resource_desc` when `ALLOW_RENDER_TARGET` or `ALLOW_UNORDERED_ACCESS` (`flags & 5 != 0`) is set, and map `67 => 26` in `pc_target_format` and `(26, 67) => 26` in `pc_shader_view_format` (`crates/xcl/src/hle/d3d12x/device_x.rs`), plus unit test cases in `console_depth_buffers_and_their_views_are_the_pcs`. **Tested** - Hardware & OS: NVIDIA GeForce RTX 2060 (driver `32.0.16.2135`), Intel Core i5-10400F, Microsoft Windows 11 Pro (Build 26300), `rustc 1.100.0 (0ef1bc386 2026-11-09)` - `cargo test --workspace -- --test-threads=4` (debug): 684 passed, 0 failed, 41 ignored - `SKIPPED gpu::recomp::tests::gpu_geometry_wave32_prefix_count_over_a_mask: no wave64` - `SKIPPED gpu::recomp::tests::gpu_wave32_program_in_wave64_hardware: no wave64` - Series S (`lockhart`) smoke run (retail title, 60 s, release): `main` crashed at startup (`exit: 0x80000003`, 2 crashes, no frame count logged); this branch ran the full 60 s with `exit: 0x0`, 916 frames shown (`PresentX 916`), 0 crashes, 0 device removals. **Regression run** ``` xcl-smoke v1 commit: 9ce2070eccf436d7bd38601c90407da447df34f3 gpu: NVIDIA GeForce RTX 2060 title: 2c508222 seconds: 60 exit: 0x80000003 frames shown: none logged (the run did not reach its end) presents per 2 s (last 3): 60 58 27 device removals: 0 crashes: 2 peak commit: 15460 MB ``` ``` xcl-smoke v1 commit: c3d350a5729d7559d00554facc622c6d1c1b9bb6 gpu: NVIDIA GeForce RTX 2060 title: 2c508222 seconds: 60 exit: 0x0 frames shown: 916 (PresentX 916) presents per 2 s (last 3): 58 39 18 device removals: 0 crashes: 0 peak commit: 15555 MB ``` **Not tested** - AMD GPUs and native wave64 hardware (`no wave64` skipped the two wave64 GPU tests above). - Other Series S titles or titles with sampled-only vs RT/UAV `R9G9B9E5` precision edge cases. **AI use** - Google Antigravity (Gemini 4 Neon High): diagnosed the `CreatePlacedResourceX` format-67 `E_INVALIDARG` crash from the log, wrote the fix and unit test expansion in `device_x.rs`, ran the test suite and smoke runs, and drafted this description.
PC D3D12 rejects ALLOW_RENDER_TARGET and ALLOW_UNORDERED_ACCESS on DXGI_FORMAT_R9G9B9E5_SHAREDEXP (67) with E_INVALIDARG (0x80070057). In Series S (Lockhart) mode, a retail title creates a 1920x1080 format-67 target with flags 0x300005 during startup and aborts on the error.

Promote format-67 resources with RT/UAV flags and their RTV/UAV/SRV views to DXGI_FORMAT_R11G11B10_FLOAT (26, same 32 bpp unsigned HDR float with full PC RTV/UAV/SRV support), while keeping sampled-only format-67 textures unchanged.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 04:26:56 +00:00
github manually merged commit c3d350a572 into gh-pr/605/base 2026-11-26 04:26:57 +00:00
Author
Owner

@⁠MesshM on GitHub · 2026-11-24 02:28 UTC · original

Test run and review of c3d350a5729d7559d00554facc622c6d1c1b9bb6 on AMD RDNA4. The branch is based on 9ce2070, so I merged it onto current main cb868b2 locally (clean merge, only device_x.rs) and tested that tree.

Overlap: this fixes the same Series S start-up failure as #242 (still open), the same way except for the target format: #242 makes the format-67 targets R16G16B16A16_FLOAT (10), this PR R11G11B10_FLOAT (26). Only one of them should land; the numbers below may help pick.

Tested

  • AMD Radeon RX 9060 XT 16 GB (RDNA4), driver 32.0.32029.2010; Ryzen 7 5700X, 64 GB RAM, Windows 11 Pro build 26200, Rust 1.100.0 stable-x86_64-pc-windows-msvc, debug
  • .\scripts\test.ps1 (cargo build --workspace + cargo test --workspace -- --test-threads=4) on the merge: 685 passed, 0 failed, 41 ignored, exit code 0; xcl lib tests 645 passed, 0 failed, 21 ignored
  • 0 SKIPPED; console_depth_buffers_and_their_views_are_the_pcs (with the new cases) passes

Review

  1. R11G11B10_FLOAT does not hold R9G9B9E5's values. The description calls it "the same 32 bpp unsigned HDR float format", but the precision differs: R9G9B9E5 gives each channel a 9-bit mantissa (shared 5-bit exponent); R11G11B10 has 6-bit mantissas for R and G and 5 bits for B. Counted over every value an R9G9B9E5 channel can hold (m · 2^(e−24), m 0–511, e 0–31: 8 448 distinct values), exactly representable are:

    • R11 / G11: 1 984 of 8 448
    • B10: 992 of 8 448
    • fp16 (R16G16B16A16_FLOAT, #242): 8 448 of 8 448

    For example 1.00390625 (1 + 2⁻⁸) is an R9G9B9E5 value and an fp16 value, but rounds in R11/G11/B10. Max values also drop (R9G9B9E5 65 408, R11 65 024, B10 64 512). So a target the title writes and reads back loses precision here; with fp16 it does not, at twice the memory (8 bytes per texel instead of 4).

  2. The premise does not hold on every PC driver. The code comment says PC D3D12 forbids ALLOW_RENDER_TARGET and ALLOW_UNORDERED_ACCESS on format 67. On this RDNA4 card, CheckFeatureSupport(D3D12_FEATURE_FORMAT_SUPPORT) for DXGI_FORMAT_R9G9B9E5_SHAREDEXP reports RENDER_TARGET, TYPED_UNORDERED_ACCESS_VIEW and UAV_TYPED_STORE, and a 1920x1080 RT|UAV committed resource in that format is created with S_OK (measured for #242, same machine and driver). The E_INVALIDARG is driver-dependent (NVIDIA in the reports so far); the comment could say "some drivers".

  3. The view mappings are complete: RTVs and UAVs go through pc_shader_view_format(resource, view), SRVs through pc_srv, pipeline formats and clears through pc_target_format, and a sampled-only format-67 texture stays 67, as the new test checks.

Not tested: no retail title or Series S profile (I have no unpacked game), so the picture with either format was not compared on screen; no regression run, no XCL_SAMPLE_* tests, release build; the PR's head on its old base was not run, only its merge onto main.

Run and review by Claude Code (Claude Opus 5.5) on this machine; the value counts come from a short script over the three formats' definitions, the format support from the run on this adapter.

**@⁠MesshM** on GitHub · 2026-11-24 02:28 UTC · [original](https://github.com/xcl-dev/xcl/pull/605#issuecomment-7120187287) Test run and review of `c3d350a5729d7559d00554facc622c6d1c1b9bb6` on AMD RDNA4. The branch is based on `9ce2070`, so I merged it onto current `main` `cb868b2` locally (clean merge, only `device_x.rs`) and tested that tree. **Overlap:** this fixes the same Series S start-up failure as #242 (still open), the same way except for the target format: #242 makes the format-67 targets `R16G16B16A16_FLOAT` (10), this PR `R11G11B10_FLOAT` (26). Only one of them should land; the numbers below may help pick. **Tested** - AMD Radeon RX 9060 XT 16 GB (RDNA4), driver 32.0.32029.2010; Ryzen 7 5700X, 64 GB RAM, Windows 11 Pro build 26200, Rust 1.100.0 `stable-x86_64-pc-windows-msvc`, debug - `.\scripts\test.ps1` (`cargo build --workspace` + `cargo test --workspace -- --test-threads=4`) on the merge: **685 passed, 0 failed, 41 ignored**, exit code 0; `xcl` lib tests 645 passed, 0 failed, 21 ignored - **0 `SKIPPED`**; `console_depth_buffers_and_their_views_are_the_pcs` (with the new cases) passes **Review** 1. **R11G11B10_FLOAT does not hold R9G9B9E5's values.** The description calls it "the same 32 bpp unsigned HDR float format", but the precision differs: R9G9B9E5 gives each channel a 9-bit mantissa (shared 5-bit exponent); R11G11B10 has 6-bit mantissas for R and G and 5 bits for B. Counted over every value an R9G9B9E5 channel can hold (m · 2^(e−24), m 0–511, e 0–31: 8 448 distinct values), exactly representable are: - R11 / G11: 1 984 of 8 448 - B10: 992 of 8 448 - fp16 (`R16G16B16A16_FLOAT`, #242): 8 448 of 8 448 For example 1.00390625 (1 + 2⁻⁸) is an R9G9B9E5 value and an fp16 value, but rounds in R11/G11/B10. Max values also drop (R9G9B9E5 65 408, R11 65 024, B10 64 512). So a target the title writes and reads back loses precision here; with fp16 it does not, at twice the memory (8 bytes per texel instead of 4). 2. **The premise does not hold on every PC driver.** The code comment says PC D3D12 forbids `ALLOW_RENDER_TARGET` and `ALLOW_UNORDERED_ACCESS` on format 67. On this RDNA4 card, `CheckFeatureSupport(D3D12_FEATURE_FORMAT_SUPPORT)` for `DXGI_FORMAT_R9G9B9E5_SHAREDEXP` reports `RENDER_TARGET`, `TYPED_UNORDERED_ACCESS_VIEW` and `UAV_TYPED_STORE`, and a 1920x1080 RT|UAV committed resource in that format is created with `S_OK` (measured for #242, same machine and driver). The `E_INVALIDARG` is driver-dependent (NVIDIA in the reports so far); the comment could say "some drivers". 3. The view mappings are complete: RTVs and UAVs go through `pc_shader_view_format(resource, view)`, SRVs through `pc_srv`, pipeline formats and clears through `pc_target_format`, and a sampled-only format-67 texture stays 67, as the new test checks. **Not tested:** no retail title or Series S profile (I have no unpacked game), so the picture with either format was not compared on screen; no regression run, no `XCL_SAMPLE_*` tests, release build; the PR's head on its old base was not run, only its merge onto `main`. Run and review by Claude Code (Claude Opus 5.5) on this machine; the value counts come from a short script over the three formats' definitions, the format support from the run on this adapter.
Author
Owner

@⁠yyc160 on GitHub · 2026-11-24 04:45 UTC · original

I arrived at the same fix independently a few hours ago (#651, created ~02:24 UTC alongside this one) and my PR covers two things this one does not — while this PR covers something mine was missing. Posting the deltas here since the maintainer will have to pick one anyway, and both halves are worth keeping regardless of which PR carries them.

What #605 has that #651 was missing — pc_target_format promoting 67 itself. I only rewrote pc_resource_desc and pc_shader_view_format, so on my branch the graphics PSO mapper still returned 67 for the retyped resource (verified independently by @⁠CryingLaughing on an RTX 4080 in the #651 thread). I've added the same 67 => 26 line to pc_target_format in #651 (commit 42ec5f7) with the comment pointing here.

What #651 has that #605 does not — two clear-value fixes found on the real title, with probe data:

  1. A retyped resource's optimized clear value follows the new format. After the 67→26 resource promotion, pc_clear still mapped the title's clear value to 67, and the device refuses a resource whose clear value's format does not match — so the crash chain moved one door over instead of ending. #651's pc_clear takes the (console, PC) resource formats and follows. Note that pc_target_format(67) => 26 alone does not fully cover this: the depth case below produces a clear value in a typeless format, which no entry in pc_target_format fixes.

  2. A depth target's clear value in a typeless format. Console depth 118 maps to PC 44 (R24G8_TYPELESS), and the title's optimized clear value for it arrives in format 44 — typeless — which the PC refuses outright (E_INVALIDARG under ALLOW_DEPTH_STENCIL, verified under both COMMON and UNORDERED_ACCESS initial states; the correct format is the family's DSV format 45). #651's commit b212ecb handles the depth-typeless family (19→20, 39→40, 44→45, 53→55) and drops color-typeless clear values rather than guessing a typed format. Probe data for all of this is in the #651 thread.

End-to-end result on the title that motivates both PRs (RTX 5070 Ti, lockhart, idle GPU): 21.7 s breakpoint → 27.1 s breakpoint (67's resource fixed, depth clear still broken) → 120 s clean exit, 0 crashes, both refusals gone — with #651's three commits. #605 alone would fix the first refusal; the clear-value follow and the depth-typeless case are what got past the second.

Regression runs on the same hardware are in the #651 description (main 9ce2070 crashing at 21.7 s vs the branch surviving the full 120 s, plus eizispark's RX 9070 XT pass and CryingLaughing's RTX 4080 probe run above).

One scope note for whoever reviews: this title reaches the 67 target only under lockhart — under anaconda it never draws at all on NVIDIA (every activity line reads 0 draws, 0 dispatches; on @⁠eizispark's AMD card anaconda renders at 60 presents/2s). Happy to fold whatever the maintainer prefers into whichever PR they pick — the clear-value follow is a self-contained pc_clear change and would sit cleanly on top of this branch too.

**@⁠yyc160** on GitHub · 2026-11-24 04:45 UTC · [original](https://github.com/xcl-dev/xcl/pull/605#issuecomment-7122308488) I arrived at the same fix independently a few hours ago (#651, created ~02:24 UTC alongside this one) and my PR covers two things this one does not — while this PR covers something mine was missing. Posting the deltas here since the maintainer will have to pick one anyway, and both halves are worth keeping regardless of which PR carries them. **What #605 has that #651 was missing** — `pc_target_format` promoting 67 itself. I only rewrote `pc_resource_desc` and `pc_shader_view_format`, so on my branch the graphics PSO mapper still returned 67 for the retyped resource (verified independently by @⁠CryingLaughing on an RTX 4080 in the #651 thread). I've added the same `67 => 26` line to `pc_target_format` in #651 (commit `42ec5f7`) with the comment pointing here. **What #651 has that #605 does not** — two clear-value fixes found on the real title, with probe data: 1. **A retyped resource's optimized clear value follows the new format.** After the 67→26 resource promotion, `pc_clear` still mapped the title's clear value to 67, and the device refuses a resource whose clear value's format does not match — so the crash chain moved one door over instead of ending. #651's `pc_clear` takes the `(console, PC)` resource formats and follows. Note that `pc_target_format(67) => 26` alone does *not* fully cover this: the depth case below produces a clear value in a **typeless** format, which no entry in `pc_target_format` fixes. 2. **A depth target's clear value in a typeless format.** Console depth 118 maps to PC 44 (`R24G8_TYPELESS`), and the title's optimized clear value for it arrives in format 44 — typeless — which the PC refuses outright (`E_INVALIDARG` under `ALLOW_DEPTH_STENCIL`, verified under both COMMON and UNORDERED_ACCESS initial states; the correct format is the family's DSV format 45). #651's commit `b212ecb` handles the depth-typeless family (19→20, 39→40, 44→45, 53→55) and drops color-typeless clear values rather than guessing a typed format. Probe data for all of this is in the #651 thread. **End-to-end result on the title that motivates both PRs** (RTX 5070 Ti, lockhart, idle GPU): 21.7 s breakpoint → 27.1 s breakpoint (67's resource fixed, depth clear still broken) → **120 s clean exit, 0 crashes, both refusals gone** — with #651's three commits. #605 alone would fix the first refusal; the clear-value follow and the depth-typeless case are what got past the second. **Regression runs on the same hardware** are in the #651 description (main `9ce2070` crashing at 21.7 s vs the branch surviving the full 120 s, plus `eizispark`'s RX 9070 XT pass and `CryingLaughing`'s RTX 4080 probe run above). One scope note for whoever reviews: this title reaches the 67 target only under `lockhart` — under `anaconda` it never draws at all on NVIDIA (every activity line reads `0 draws, 0 dispatches`; on @⁠eizispark's AMD card `anaconda` renders at 60 presents/2s). Happy to fold whatever the maintainer prefers into whichever PR they pick — the clear-value follow is a self-contained `pc_clear` change and would sit cleanly on top of this branch too.
Author
Owner

@⁠MrEjecutor on GitHub · 2026-11-24 06:27 UTC · original

Test report on Windows + NVIDIA for c3d350a (this PR's head), Series S profile: no crash in 180 s

Tested

  • RTX 5060 Ti 16 GB (wave32), driver 621.24; Intel Core Ultra 5 225F; 32 GB; Windows 11 Pro 26200; Rust 1.100.0 stable-x86_64-pc-windows-msvc; DXC 1.8.2505.32 (SDK 10.0.28000); release
  • Tree: main e50836b + this PR + #495 (3ae0841), merged locally without conflicts (c096040). #495 is needed on this title to get past a later assert (+0xb18de7) on the Series S profile.
  • cargo test --workspace --release --no-fail-fast -- --test-threads=4: 705 passed, 0 failed, 41 ignored; SKIPPED (no wave64): gpu_geometry_wave32_prefix_count_over_a_mask, gpu_wave32_program_in_wave64_hardware
  • Retail title 1.0.2.1, device_type = "lockhart", XCL_NETWORK=0, 180 s: no refusal of the format-67 target, no assert, no device removal. On main the same setup stops at +0xcc2834 at 19 s (format 67, 0x80070057).
  • Same setup with #242 instead of this PR: also no crash (1169 frames). On this card the three format-67 PRs (#242, #605, #651) cannot be told apart by a run: none crashes and the window is black in all three (the black window is not specific to these PRs).
  • From the code (checked): R11G11B10_FLOAT keeps 7/7/6 significant bits per channel where R9G9B9E5 has 9, and it retypes format 67 also on adapters that support it natively (#242 probes FORMAT_SUPPORT first).

Regression run

xcl-smoke v1
commit: c09604072cb3177f4724b0c1a9bb7f570bbdaea1
gpu: NVIDIA GeForce RTX 5060 Ti
title: GTAVI
seconds: 180
exit: 0x0
frames shown: 1163 (PresentX 1163)
presents per 2 s (last 3): 7 8 8
device removals: 0
crashes: 0
peak commit: 18300 MB

From the local merge above, not from this PR's head alone.

Not tested

  • Rendered output (the window stays black on this card for reasons outside this PR); AMD GPUs and CPUs; the Series X profile; this PR without #495.

AI use

  • Claude Code (Claude Opus 5.5) ran the builds, tests and runs and wrote this report; a code comparison of #242 / #605 / #651 was drafted by Codex (gpt-6-sol) and only the points above that I checked in the code are included. Checked by mrejecutor.
**@⁠MrEjecutor** on GitHub · 2026-11-24 06:27 UTC · [original](https://github.com/xcl-dev/xcl/pull/605#issuecomment-7123951381) **Test report on Windows + NVIDIA for `c3d350a` (this PR's head), Series S profile: no crash in 180 s** **Tested** - RTX 5060 Ti 16 GB (wave32), driver 621.24; Intel Core Ultra 5 225F; 32 GB; Windows 11 Pro 26200; Rust 1.100.0 `stable-x86_64-pc-windows-msvc`; DXC 1.8.2505.32 (SDK 10.0.28000); release - Tree: `main` `e50836b` + this PR + #495 (`3ae0841`), merged locally without conflicts (`c096040`). #495 is needed on this title to get past a later assert (`+0xb18de7`) on the Series S profile. - `cargo test --workspace --release --no-fail-fast -- --test-threads=4`: 705 passed, 0 failed, 41 ignored; `SKIPPED` (no wave64): `gpu_geometry_wave32_prefix_count_over_a_mask`, `gpu_wave32_program_in_wave64_hardware` - Retail title 1.0.2.1, `device_type = "lockhart"`, `XCL_NETWORK=0`, 180 s: no refusal of the format-67 target, no assert, no device removal. On `main` the same setup stops at `+0xcc2834` at 19 s (format 67, `0x80070057`). - Same setup with #242 instead of this PR: also no crash (1169 frames). On this card the three format-67 PRs (#242, #605, #651) cannot be told apart by a run: none crashes and the window is black in all three (the black window is not specific to these PRs). - From the code (checked): R11G11B10_FLOAT keeps 7/7/6 significant bits per channel where R9G9B9E5 has 9, and it retypes format 67 also on adapters that support it natively (#242 probes `FORMAT_SUPPORT` first). **Regression run** ``` xcl-smoke v1 commit: c09604072cb3177f4724b0c1a9bb7f570bbdaea1 gpu: NVIDIA GeForce RTX 5060 Ti title: GTAVI seconds: 180 exit: 0x0 frames shown: 1163 (PresentX 1163) presents per 2 s (last 3): 7 8 8 device removals: 0 crashes: 0 peak commit: 18300 MB ``` From the local merge above, not from this PR's head alone. **Not tested** - Rendered output (the window stays black on this card for reasons outside this PR); AMD GPUs and CPUs; the Series X profile; this PR without #495. **AI use** - Claude Code (Claude Opus 5.5) ran the builds, tests and runs and wrote this report; a code comparison of #242 / #605 / #651 was drafted by Codex (gpt-6-sol) and only the points above that I checked in the code are included. Checked by mrejecutor.
Author
Owner

@⁠volkan12a-bot on GitHub · 2026-11-24 06:44 UTC · original

Test report: retail title, a run confirming the problem this PR fixes

Not a run of this PR's head (c3d350a): it is a run of my local patch with the same logic (format == 67 && flags & 5 != 0 → 26, pc_target_format 67 → 26, (26, 67) → 26), on main 7ebf1b8.

Hardware / build

  • NVIDIA GeForce RTX 4070 Laptop GPU 8 GB, driver 32.0.16.1692; Intel Core i7-14700HX, 40 GB RAM; Windows 11 Pro 26200
  • Rust 1.97.1, cargo build --release
  • Retail title 930.048.020, Lockhart (Series S) profile

Without the fix

  • CreatePlacedResourceX of a 1920x1080 format 67 texture, flags 0x300005, returned 0x80070057, and the title stopped on its own int3 (0x80000003).

With the fix

  • The log shows R9G9B9E5 target / UAV texture 1920x1080 (flags 0x300005) made R11G11B10_FLOAT.
  • A second 1920x1080 one, flags 0x4 (UAV without RT), took the same path.
  • 640x360 format 67 textures with flags 0 that alias format 42 memory stay 67.
  • The title went on past that point: one run reached 1006 s, about 21 000 frames, with no failure of this resource.
  • The patched mappings passed cargo test -p xcl --lib d3d12x::device_x: 5 passed, 0 failed.

Not tested

  • This PR's own commit.
  • Whether the picture that uses these buffers is correct: I did not compare it.
  • smoke.ps1 blocks; AMD GPUs.

I post the report here because this PR has the same condition as my patch. #651 does the same with more changes around it.

AI use

  • Claude Code with Claude Opus 5.5: diagnosed it from the log, wrote the local patch and this report. The runs are mine.
**@⁠volkan12a-bot** on GitHub · 2026-11-24 06:44 UTC · [original](https://github.com/xcl-dev/xcl/pull/605#issuecomment-7124248817) **Test report: retail title, a run confirming the problem this PR fixes** Not a run of this PR's head (`c3d350a`): it is a run of my local patch with the same logic (`format == 67 && flags & 5 != 0` → 26, `pc_target_format` 67 → 26, `(26, 67) → 26`), on `main` `7ebf1b8`. **Hardware / build** - NVIDIA GeForce RTX 4070 Laptop GPU 8 GB, driver 32.0.16.1692; Intel Core i7-14700HX, 40 GB RAM; Windows 11 Pro 26200 - Rust 1.97.1, `cargo build --release` - Retail title 930.048.020, Lockhart (Series S) profile **Without the fix** - `CreatePlacedResourceX` of a 1920x1080 format 67 texture, flags 0x300005, returned 0x80070057, and the title stopped on its own `int3` (0x80000003). **With the fix** - The log shows `R9G9B9E5 target / UAV texture 1920x1080 (flags 0x300005) made R11G11B10_FLOAT`. - A second 1920x1080 one, flags 0x4 (UAV without RT), took the same path. - 640x360 format 67 textures with flags 0 that alias format 42 memory stay 67. - The title went on past that point: one run reached 1006 s, about 21 000 frames, with no failure of this resource. - The patched mappings passed `cargo test -p xcl --lib d3d12x::device_x`: 5 passed, 0 failed. **Not tested** - This PR's own commit. - Whether the picture that uses these buffers is correct: I did not compare it. - `smoke.ps1` blocks; AMD GPUs. I post the report here because this PR has the same condition as my patch. #651 does the same with more changes around it. **AI use** - Claude Code with Claude Opus 5.5: diagnosed it from the log, wrote the local patch and this report. The runs are mine.
Author
Owner

@⁠yous0serious on GitHub · 2026-11-24 09:26 UTC · original

Test report on c3d350a (this PR's head): RTX 4090, Series X profile – the 8 pipelines with a format-67 target are no longer refused

The runs on this PR so far are on the Series S profile; the Series X profile reaches format 67 too, in pipelines (#914 expected it not to).

Tested

  • NVIDIA GeForce RTX 4090 (wave32), driver 621.01; Intel Core i7-13700KF; 32 GB; Windows 11 Pro 26200; Rust 1.100.0 stable-x86_64-pc-windows-msvc; release
  • Retail title 1.0.2.1, device_type = "anaconda" (Series X), XCL_NETWORK=0, scripts/smoke.ps1 -Seconds 60, no input, on this head and on its base 9ce2070
  • report.json d3d12.failed_pipelines: base 8, this PR 0 (fallback_pipelines 0, translated_pipelines 6 in both). On the base the 8 are pipeline streams with a console VS + PS and one render target in format 67, refused with 0x8007000e / 0x80070057, and their stand-in versions too (graphics PSO rejected …, the fallback version too), about 8 s after start.

Regression run

Base (9ce2070):

xcl-smoke v1
commit: 9ce2070eccf436d7bd38601c90407da447df34f3
gpu: NVIDIA GeForce RTX 4090
title: GTA6
seconds: 60
exit: 0x0
frames shown: 1575 (PresentX 1575)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 14812 MB

This PR (c3d350a):

xcl-smoke v1
commit: c3d350a5729d7559d00554facc622c6d1c1b9bb6
gpu: NVIDIA GeForce RTX 4090
title: GTA6
seconds: 60
exit: 0x0
frames shown: 1567 (PresentX 1567)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 14792 MB

Not tested

  • cargo test --workspace on this head
  • whether the 8 pipelines draw correctly; Series S profile; AMD
  • anything past the first-run screens (no input)

AI use

  • GitHub Copilot app with Claude Opus 5.5: ran the builds and runs, found the pipelines' render-target format with a temporary local log line (in no commit), wrote this report. Checked by me.
**@⁠yous0serious** on GitHub · 2026-11-24 09:26 UTC · [original](https://github.com/xcl-dev/xcl/pull/605#issuecomment-7127427226) **Test report on `c3d350a` (this PR's head): RTX 4090, Series X profile – the 8 pipelines with a format-67 target are no longer refused** The runs on this PR so far are on the Series S profile; the Series X profile reaches format 67 too, in pipelines (#914 expected it not to). **Tested** - NVIDIA GeForce RTX 4090 (wave32), driver 621.01; Intel Core i7-13700KF; 32 GB; Windows 11 Pro 26200; Rust 1.100.0 `stable-x86_64-pc-windows-msvc`; release - Retail title 1.0.2.1, `device_type = "anaconda"` (Series X), `XCL_NETWORK=0`, `scripts/smoke.ps1 -Seconds 60`, no input, on this head and on its base `9ce2070` - `report.json` `d3d12.failed_pipelines`: base **8**, this PR **0** (`fallback_pipelines` 0, `translated_pipelines` 6 in both). On the base the 8 are pipeline streams with a console VS + PS and one render target in format 67, refused with `0x8007000e` / `0x80070057`, and their stand-in versions too (`graphics PSO rejected …, the fallback version too`), about 8 s after start. **Regression run** Base (`9ce2070`): ``` xcl-smoke v1 commit: 9ce2070eccf436d7bd38601c90407da447df34f3 gpu: NVIDIA GeForce RTX 4090 title: GTA6 seconds: 60 exit: 0x0 frames shown: 1575 (PresentX 1575) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 14812 MB ``` This PR (`c3d350a`): ``` xcl-smoke v1 commit: c3d350a5729d7559d00554facc622c6d1c1b9bb6 gpu: NVIDIA GeForce RTX 4090 title: GTA6 seconds: 60 exit: 0x0 frames shown: 1567 (PresentX 1567) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 14792 MB ``` **Not tested** - `cargo test --workspace` on this head - whether the 8 pipelines draw correctly; Series S profile; AMD - anything past the first-run screens (no input) **AI use** - GitHub Copilot app with Claude Opus 5.5: ran the builds and runs, found the pipelines' render-target format with a temporary local log line (in no commit), wrote this report. Checked by me.
Author
Owner

@⁠raylitebull on GitHub · 2026-11-24 10:40 UTC · original

Code/CI review only (not independently runtime-tested by me): clean merge and PR description green (just awaiting CI workflow approval). Tight +19/-2 fix promoting R9G9B9E5_SHAREDEXP RT/UAV targets to R11G11B10_FLOAT — cleaner than duplicate #651. Recommend approving CI and merging, @⁠ivall.

**@⁠raylitebull** on GitHub · 2026-11-24 10:40 UTC · [original](https://github.com/xcl-dev/xcl/pull/605#issuecomment-7129088945) Code/CI review only (not independently runtime-tested by me): clean merge and `PR description` green (just awaiting CI workflow approval). Tight `+19/-2` fix promoting `R9G9B9E5_SHAREDEXP` RT/UAV targets to `R11G11B10_FLOAT` — cleaner than duplicate #651. Recommend approving CI and merging, @⁠ivall.
Author
Owner

@⁠MKmajster on GitHub · 2026-11-24 12:59 UTC · original

Confirming PR #605 on an RTX 3070 (8 GB VRAM) / 16 GB RAM, Windows 11.

Before #605, Series S (lockhart) aborted at startup: the title creates a 1920×1080 R9G9B9E5_SHAREDEXP (67) render target + UAV (flags 0x300005), the host refuses with 0x80070057, and the title hits int3 (0x80000003) after ~234 frames (~80 s) — matches #914.

With #605 cherry-picked (plus console_type_raw = 5 for lockhart), the assert is gone. Series S now runs to a clean exit (code 0), ~30 fps at 1920×1080, 2585 console frames / 19,610 translated draws, with no device-removed and no OOM — i.e. it fits 8 GB VRAM, where Series X 4K does not (that path exhausts the 8 GB and the GPU is removed after ~3.5 min).

Remaining on this setup: sampled frames stay black (0 non-black). ID3D12GraphicsCommandList10 #126 and #142 (~2585×/frame) and ID3D12CommandQueue #31 (CopyPageMappingsBatchX, #1031) are still stubbed, so the streamed/mapped content never reaches the GPU views. So #605 clears the Series S startup crash; a visible Series S frame additionally needs those console extensions.

Tested with Claude Code (AI-assisted). No game data attached.

**@⁠MKmajster** on GitHub · 2026-11-24 12:59 UTC · [original](https://github.com/xcl-dev/xcl/pull/605#issuecomment-7132183791) Confirming PR #605 on an RTX 3070 (8 GB VRAM) / 16 GB RAM, Windows 11. Before #605, Series S (lockhart) aborted at startup: the title creates a 1920×1080 R9G9B9E5_SHAREDEXP (67) render target + UAV (flags 0x300005), the host refuses with 0x80070057, and the title hits int3 (0x80000003) after ~234 frames (~80 s) — matches #914. With #605 cherry-picked (plus `console_type_raw = 5` for lockhart), the assert is gone. Series S now runs to a clean exit (code 0), ~30 fps at 1920×1080, 2585 console frames / 19,610 translated draws, with no device-removed and no OOM — i.e. it fits 8 GB VRAM, where Series X 4K does not (that path exhausts the 8 GB and the GPU is removed after ~3.5 min). Remaining on this setup: sampled frames stay black (0 non-black). ID3D12GraphicsCommandList10 #126 and #142 (~2585×/frame) and ID3D12CommandQueue #31 (CopyPageMappingsBatchX, #1031) are still stubbed, so the streamed/mapped content never reaches the GPU views. So #605 clears the Series S startup crash; a visible Series S frame additionally needs those console extensions. Tested with Claude Code (AI-assisted). No game data attached.
Author
Owner

@⁠rrrarrra9 on GitHub · 2026-11-24 16:16 UTC · original

Windows comparison on a GTX 1650 (4 GB)

I compared retail 1.0.2.1 in the Series S profile on main (b7aa9f3) and on the same base with this PR's c3d350a cherry-picked (e21849e, local).

Build First failure PresentX calls Peak process commit
main At 45.08 s, the 1920×1080 format-67 RT/UAV was refused with 0x80070057, followed by 0x80000003 at game+0xcc2834 299 14,446 MiB
main + #605 The run passed the format-67 allocation. At 82.63 s it hit 0x80000003 at game+0xb18de7 (#495). Final process exit was 0xc0000005 670 18,104 MiB

The last sampled frame in each run had 0 of 129,600 non-dark samples. This confirms that #605 clears the #914 startup assertion on this GPU. The #495 follow-up is in testing.

AI use

Codex (GPT-6) ran both builds and wrote the report from the generated logs.

**@⁠rrrarrra9** on GitHub · 2026-11-24 16:16 UTC · [original](https://github.com/xcl-dev/xcl/pull/605#issuecomment-7137390568) **Windows comparison on a GTX 1650 (4 GB)** I compared retail 1.0.2.1 in the Series S profile on `main` (`b7aa9f3`) and on the same base with this PR's `c3d350a` cherry-picked (`e21849e`, local). | Build | First failure | PresentX calls | Peak process commit | | --- | --- | ---: | ---: | | `main` | At 45.08 s, the 1920×1080 format-67 RT/UAV was refused with `0x80070057`, followed by `0x80000003` at `game+0xcc2834` | 299 | 14,446 MiB | | `main` + #605 | The run passed the format-67 allocation. At 82.63 s it hit `0x80000003` at `game+0xb18de7` (#495). Final process exit was `0xc0000005` | 670 | 18,104 MiB | The last sampled frame in each run had 0 of 129,600 non-dark samples. This confirms that #605 clears the #914 startup assertion on this GPU. The #495 follow-up is in testing. **AI use** Codex (GPT-6) ran both builds and wrote the report from the generated logs.
This discussion has been locked. Commenting is limited to contributors.
No description provided.