Memory: the 16-window layout keeps 4 runtime sparse windows #3517

Open
CharlyRien wants to merge 1 commit from upstream-pr/3517 into main
CharlyRien commented 2026-11-30 10:48:58 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by CharlyRien on 2026-11-30T10:48:58Z.


The 16-window layout (XCL_UMA_WINDOWS=16) now keeps 4 runtime sparse windows instead of 3. The 4- and 8-window layouts keep 3. XCL_SPARSE_WINDOWS=<n> (1 to 8) overrides the count for any layout.

Why: a retail title's BVH builder works in a 3.39 GB MEM_RESERVE | MEM_64K_PAGES reservation (0xd4920000 bytes, protect 0x2404), made once sparse windows 1..2 are taken. With 3 sparse windows it finds no room and becomes plain write-watched memory, which shaders read as zeros, so every acceleration structure the title builds stays empty. With 4 it lands in window 3, where the GPU sees it. The 16-window layout already leaves 5 of its windows empty (3 sparse + 1 coherent + 6 view), so the 4th sparse window costs no address space: 4 + 1 + 6 = 11 of 16.

claudetools-gh found this and proposed the same XCL_SPARSE_WINDOWS switch on #505 (comment 7273597036): with main's root-constant clamp 82b7cb3e and a 4th sparse window, the title builds real BVHs without crashing and the room gets bounce light, on an RTX 5070 Ti. This PR is his switch with 4 as the 16-window default. main already has 82b7cb3e (#1319), so this PR needs nothing else.

Part of #505.

What is in it
One commit:

  • crates/xcl/src/gpu/uma.rs:
    • SIXTEEN_WINDOW_SPARSE_WINDOWS = 4, next to MAX_RUNTIME_SPARSE_WINDOWS = 3 (now the 4- and 8-window value);
    • runtime_sparse_windows(windows): XCL_SPARSE_WINDOWS (parsed and clamped to 1..=8), else the layout's default. It replaces the constant at the only two places that bound the sparse windows: max_coherent_windows (through max_coherent_windows_for) and reserve_runtime;
    • nothing else moves: the coherent and view windows follow the sparse ones as before (coherent window 4, views 5..10, 11..15 reserved and empty), and every runtime user finds them through committed_window() / is_sparse_window() / is_view_window(). A coherent plan in the 16-window layout can now take 6 windows instead of 7.
  • Tests (uma.rs):
    • new: sparse_windows_setting_parses_clamps_and_fits_the_layout (parse, clamp, per-layout default; for 1..=8 sparse windows the 16-window layout still fits), sixteen_windows_keep_four_sparse_windows (the 16-window layout's windows, the whole aperture reserved, the write-watch regions), a_bvh_scratch_reservation_lands_in_the_fourth_sparse_window (with windows 1..2 taken, a 0xd4920000 reservation lands in window 3, and 6.09 GB more takes no other window). The last two use only APIs main has, and fail on main, where the reservation gets no room;
    • existing layout tests follow the new indices (runtime_layout_supports_eight_and_sixteen_heap_windows, the_series_x_plan_is_pinned, sparse_alloc_above_keeps_window_0_for_the_title, sparse_reserve_keeps_single_window_reservations_inside_one_window, view_windows_hold_gpu_views, expanded_runtime_layout_splits_large_coherent_heaps_across_multiple_windows).
  • crates/xcl/src/hle/d3d12x/console_heap.rs (test only): title_memory_holds_a_heap_only_in_window_0 probes the coherent window and a view window at their new indices.
  • crates/xcl/src/gpu/recomp/tests.rs (test only): gpu_sparse_vram_descriptors_buffers_and_xmem runs a 4-root-UAV program that expects the coherent window at window 3. With XCL_UMA_WINDOWS=16 that is now window 4, so the test skips there (SKIPPED …: the coherent window is not window 3); XCL_SPARSE_WINDOWS=3 runs it with 16 windows. The default 4-window run is unchanged.
  • README.md: XCL_SPARSE_WINDOWS in the switch list.

+148 / −36 in 4 files; about 30 of them are runtime lines, the rest tests and docs.

Tested

  • Head 0b4283d1 on main 9dfbe3ea. RTX 3090 24 GB (Resizable BAR off), driver 616.56, Ryzen 9 5950X, 32 GB RAM, Windows 11 22631; Rust 1.100.0, release.

  • cargo check --release -p xcl --lib --bins --tests: 0 errors, no warning in the changed files.

  • cargo test --release -p xcl --lib -- gpu::uma:: title_memory_holds_a_heap_only_in_window_0 gpu_sparse_vram_descriptors_buffers_and_xmem root_views_in_a_gpu_view_are_wanted_with_their_bytes d3d12x::real::gpu_view_tests:: a_gpu_view_buffer_reaches_the_pc_at_its_windows_address a_view_across_a_window_end_is_bound_up_to_it a_wait_on_a_gpu_view_reads_its_cpu_view physical_home expanded_heap_window --test-threads=1 (XCL_REQUIRE_GPU=mesh): 35 passed, 0 failed, 0 ignored; SKIPPED: none. The two new layout tests fail with XCL_SPARSE_WINDOWS=3 (main's layout): 0 passed, 2 failed.

  • Not run: the whole suite (cargo test --workspace).

  • On the retail title, on our lab tree (not this PR's head), same binary, same shader cache, same switches except XCL_SPARSE_WINDOWS (two runs with 4 windows, one with 3):

    4, run 1 4, run 2 unset (3)
    the 3.39 GB 64K pages reservation sparse window 3 (0x1300000000), at 59.5 s sparse window 3, at 20 s plain write-watched memory
    the character's hair drawn missing (bald) missing (bald)
    the window (share of dark pixels in its box) 0 % 3-9 % from w+122 62-78 % from w+121
    presents/s, world + 20..180 s 0.71 0.88 0.85
    device removals, crashes, GPU wait timeouts 0, 0, 0 0, 0, 0 0, 0, 0
    video memory peak / budget 24,069 / 23,370 MB – 23,648 / 23,535 MB
    • Correction (30/11, after the re-run): the hair came back in 1 of 2 runs with 4 windows, so it is timing, not this change. With one run per side, the window's difference is not tied to this change either. What this change does reliably here: the reservation lands in a sparse window (3 of 3 runs with 4 windows, including one with #3535 on top), with no removal, crash or tile-mapping stall. The bounce light in the cell comes from claudetools-gh's runs on an RTX 5070 Ti (#505), not ours.
    • That tree: main 53e85fb1 + 42 of our commits (ports of #3089, #2798 / #2799 and the stencil part of #3290; #3094; #3281) + 82b7cb3e cherry-picked + a lab version of this switch (uma.rs only; default 3, so the A/B is the switch alone). Switches: XCL_UMA_WINDOWS=16 XCL_HEAP_WINDOWS=1 XCL_ALIAS_COPY=1 XCL_PLACE_RETIRE=0 XCL_DEPTH_UAV_TWIN=1 XCL_PAIR_PAGES=1 XCL_OUTSIDE_VIEW_USE=1 XCL_OUTSIDE_ONLY_BYTES=0x3200000,0x1900000 XCL_TWO_PASS_MB=2048 XCL_VIEW_REACH_MB=36 XCL_PREPARE=0 XCL_DRED=1 XCL_HUGE_PSO_CONCURRENCY=8 XCL_HUGE_PSO_WANTED_CONCURRENCY=8 XCL_PSO_WAIT_MS=5000 XCL_TRACE_MEM=5000.
    • The cost: about 420 MB more video memory at the peak, and over budget for longer; no tile-mapping stall (the reason the cap was 3).
    • Also seen with 4 windows: a bright outline around the hair (when drawn), grain on the crown, a white haze in the first seconds, vertical streaks in the view through the window, blocky rectangles on the right.

Regression run
Same machine as under Tested, same title, 60 s each, both through main d52ff48's scripts/smoke.ps1, XCL_PREPARE=0, the same scripted A presses (XCL_PRESS_A_AT), every other XCL_* unset (so the default 4-window layout, which this PR does not change: see Not tested). Each run started from its own copy of the same shader cache, made by another main commit, so cold for both. The head is on main 9dfbe3ea; the main run is of main d52ff48 (8 commits earlier): the check asks for a commit of main.

main d52ff48:

xcl-smoke v1
commit: d52ff48caade1f5350d513bfffd370396dadfeb6
gpu: NVIDIA GeForce RTX 3090
title: 16b5e5d4
seconds: 60
exit: 0x0
frames shown: 517 (PresentX 517)
presents per 2 s (last 3): 61 60 61
device removals: 0
crashes: 0
peak commit: 15968 MB

This PR's head 0b4283d1:

xcl-smoke v1
commit: 0b4283d147b7bd5f93a9cc3d83433cdcdef9762f
gpu: NVIDIA GeForce RTX 3090
title: 16b5e5d4
seconds: 60
exit: 0x0
frames shown: 593 (PresentX 593)
presents per 2 s (last 3): 61 61 60
device removals: 0
crashes: 0
peak commit: 15947 MB

Not tested

  • This PR's head on the retail title with XCL_UMA_WINDOWS=16: the A/B above is on our lab tree, not on this head, and the regression runs use the default 4-window layout, which this PR does not touch.
  • Other GPUs: AMD at all, NVIDIA cards with less than 24 GB (the extra video memory matters more there), the RTX 5070 Ti result is claudetools-gh's.
  • Other titles with 16 windows: a title whose large MEM_64K_PAGES reservations now fit in 16 GiB of sparse windows gets them in video memory, which is what the cap of 3 was there to avoid.
  • Acceleration-structure node counts from the GPU side on our card: our CPU-side log line (acceleration structure at …: 0 nodes) said 0 nodes in both runs; claudetools-gh's GPU-side read-back on an RTX 5070 Ti shows real trees, and that the CPU-side walk does not see the GPU's writes.
  • The whole suite with XCL_UMA_WINDOWS=16 XCL_HEAP_WINDOWS=1; Windows 10 and Wine.

AI use
AI use: the port of the switch, the new default, the tests, the A/B runs and their readings, and this description were done with Claude Code (Claude Opus 5.5), checked and posted by me. The switch itself is claudetools-gh's (#505).

🤖 Generated with Claude Code

<!-- greyfinch-sync:ivall/xcl:issue:5563752786 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517). Originally posted by [CharlyRien](https://github.com/CharlyRien) on 2026-11-30T10:48:58Z. --- The 16-window layout (`XCL_UMA_WINDOWS=16`) now keeps 4 runtime sparse windows instead of 3. The 4- and 8-window layouts keep 3. `XCL_SPARSE_WINDOWS=<n>` (1 to 8) overrides the count for any layout. Why: a retail title's BVH builder works in a 3.39 GB `MEM_RESERVE | MEM_64K_PAGES` reservation (`0xd4920000` bytes, protect `0x2404`), made once sparse windows 1..2 are taken. With 3 sparse windows it finds no room and becomes plain write-watched memory, which shaders read as zeros, so every acceleration structure the title builds stays empty. With 4 it lands in window 3, where the GPU sees it. The 16-window layout already leaves 5 of its windows empty (3 sparse + 1 coherent + 6 view), so the 4th sparse window costs no address space: 4 + 1 + 6 = 11 of 16. claudetools-gh found this and proposed the same `XCL_SPARSE_WINDOWS` switch on #505 (comment 7273597036): with `main`'s root-constant clamp `82b7cb3e` and a 4th sparse window, the title builds real BVHs without crashing and the room gets bounce light, on an RTX 5070 Ti. This PR is his switch with 4 as the 16-window default. `main` already has `82b7cb3e` (#1319), so this PR needs nothing else. Part of #505. **What is in it** One commit: - `crates/xcl/src/gpu/uma.rs`: - `SIXTEEN_WINDOW_SPARSE_WINDOWS = 4`, next to `MAX_RUNTIME_SPARSE_WINDOWS = 3` (now the 4- and 8-window value); - `runtime_sparse_windows(windows)`: `XCL_SPARSE_WINDOWS` (parsed and clamped to 1..=8), else the layout's default. It replaces the constant at the only two places that bound the sparse windows: `max_coherent_windows` (through `max_coherent_windows_for`) and `reserve_runtime`; - nothing else moves: the coherent and view windows follow the sparse ones as before (coherent window 4, views 5..10, 11..15 reserved and empty), and every runtime user finds them through `committed_window()` / `is_sparse_window()` / `is_view_window()`. A coherent plan in the 16-window layout can now take 6 windows instead of 7. - Tests (`uma.rs`): - new: `sparse_windows_setting_parses_clamps_and_fits_the_layout` (parse, clamp, per-layout default; for 1..=8 sparse windows the 16-window layout still fits), `sixteen_windows_keep_four_sparse_windows` (the 16-window layout's windows, the whole aperture reserved, the write-watch regions), `a_bvh_scratch_reservation_lands_in_the_fourth_sparse_window` (with windows 1..2 taken, a `0xd4920000` reservation lands in window 3, and 6.09 GB more takes no other window). The last two use only APIs `main` has, and fail on `main`, where the reservation gets no room; - existing layout tests follow the new indices (`runtime_layout_supports_eight_and_sixteen_heap_windows`, `the_series_x_plan_is_pinned`, `sparse_alloc_above_keeps_window_0_for_the_title`, `sparse_reserve_keeps_single_window_reservations_inside_one_window`, `view_windows_hold_gpu_views`, `expanded_runtime_layout_splits_large_coherent_heaps_across_multiple_windows`). - `crates/xcl/src/hle/d3d12x/console_heap.rs` (test only): `title_memory_holds_a_heap_only_in_window_0` probes the coherent window and a view window at their new indices. - `crates/xcl/src/gpu/recomp/tests.rs` (test only): `gpu_sparse_vram_descriptors_buffers_and_xmem` runs a 4-root-UAV program that expects the coherent window at window 3. With `XCL_UMA_WINDOWS=16` that is now window 4, so the test skips there (`SKIPPED …: the coherent window is not window 3`); `XCL_SPARSE_WINDOWS=3` runs it with 16 windows. The default 4-window run is unchanged. - `README.md`: `XCL_SPARSE_WINDOWS` in the switch list. +148 / −36 in 4 files; about 30 of them are runtime lines, the rest tests and docs. **Tested** - Head `0b4283d1` on `main` `9dfbe3ea`. RTX 3090 24 GB (Resizable BAR off), driver 616.56, Ryzen 9 5950X, 32 GB RAM, Windows 11 22631; Rust 1.100.0, release. - `cargo check --release -p xcl --lib --bins --tests`: 0 errors, no warning in the changed files. - `cargo test --release -p xcl --lib -- gpu::uma:: title_memory_holds_a_heap_only_in_window_0 gpu_sparse_vram_descriptors_buffers_and_xmem root_views_in_a_gpu_view_are_wanted_with_their_bytes d3d12x::real::gpu_view_tests:: a_gpu_view_buffer_reaches_the_pc_at_its_windows_address a_view_across_a_window_end_is_bound_up_to_it a_wait_on_a_gpu_view_reads_its_cpu_view physical_home expanded_heap_window --test-threads=1` (`XCL_REQUIRE_GPU=mesh`): **35 passed, 0 failed, 0 ignored**; SKIPPED: none. The two new layout tests fail with `XCL_SPARSE_WINDOWS=3` (main's layout): 0 passed, 2 failed. - Not run: the whole suite (`cargo test --workspace`). - On the retail title, on our lab tree (not this PR's head), same binary, same shader cache, same switches except `XCL_SPARSE_WINDOWS` (two runs with 4 windows, one with 3): | | 4, run 1 | 4, run 2 | unset (3) | |---|---|---|---| | the 3.39 GB `64K pages` reservation | sparse window 3 (`0x1300000000`), at 59.5 s | sparse window 3, at 20 s | plain write-watched memory | | the character's hair | drawn | missing (bald) | missing (bald) | | the window (share of dark pixels in its box) | 0 % | 3-9 % from w+122 | 62-78 % from w+121 | | presents/s, world + 20..180 s | 0.71 | 0.88 | 0.85 | | device removals, crashes, GPU wait timeouts | 0, 0, 0 | 0, 0, 0 | 0, 0, 0 | | video memory peak / budget | 24,069 / 23,370 MB | – | 23,648 / 23,535 MB | - **Correction (30/11, after the re-run):** the hair came back in 1 of 2 runs with 4 windows, so it is timing, not this change. With one run per side, the window's difference is not tied to this change either. What this change does reliably here: the reservation lands in a sparse window (3 of 3 runs with 4 windows, including one with #3535 on top), with no removal, crash or tile-mapping stall. The bounce light in the cell comes from claudetools-gh's runs on an RTX 5070 Ti (#505), not ours. - That tree: `main` `53e85fb1` + 42 of our commits (ports of #3089, #2798 / #2799 and the stencil part of #3290; #3094; #3281) + `82b7cb3e` cherry-picked + a lab version of this switch (`uma.rs` only; default 3, so the A/B is the switch alone). Switches: `XCL_UMA_WINDOWS=16 XCL_HEAP_WINDOWS=1 XCL_ALIAS_COPY=1 XCL_PLACE_RETIRE=0 XCL_DEPTH_UAV_TWIN=1 XCL_PAIR_PAGES=1 XCL_OUTSIDE_VIEW_USE=1 XCL_OUTSIDE_ONLY_BYTES=0x3200000,0x1900000 XCL_TWO_PASS_MB=2048 XCL_VIEW_REACH_MB=36 XCL_PREPARE=0 XCL_DRED=1 XCL_HUGE_PSO_CONCURRENCY=8 XCL_HUGE_PSO_WANTED_CONCURRENCY=8 XCL_PSO_WAIT_MS=5000 XCL_TRACE_MEM=5000`. - The cost: about 420 MB more video memory at the peak, and over budget for longer; no tile-mapping stall (the reason the cap was 3). - Also seen with 4 windows: a bright outline around the hair (when drawn), grain on the crown, a white haze in the first seconds, vertical streaks in the view through the window, blocky rectangles on the right. **Regression run** Same machine as under **Tested**, same title, 60 s each, both through `main` `d52ff48`'s `scripts/smoke.ps1`, `XCL_PREPARE=0`, the same scripted A presses (`XCL_PRESS_A_AT`), every other `XCL_*` unset (so the default 4-window layout, which this PR does not change: see **Not tested**). Each run started from its own copy of the same shader cache, made by another `main` commit, so cold for both. The head is on `main` `9dfbe3ea`; the `main` run is of `main` `d52ff48` (8 commits earlier): the check asks for a commit of `main`. `main` `d52ff48`: ``` xcl-smoke v1 commit: d52ff48caade1f5350d513bfffd370396dadfeb6 gpu: NVIDIA GeForce RTX 3090 title: 16b5e5d4 seconds: 60 exit: 0x0 frames shown: 517 (PresentX 517) presents per 2 s (last 3): 61 60 61 device removals: 0 crashes: 0 peak commit: 15968 MB ``` This PR's head `0b4283d1`: ``` xcl-smoke v1 commit: 0b4283d147b7bd5f93a9cc3d83433cdcdef9762f gpu: NVIDIA GeForce RTX 3090 title: 16b5e5d4 seconds: 60 exit: 0x0 frames shown: 593 (PresentX 593) presents per 2 s (last 3): 61 61 60 device removals: 0 crashes: 0 peak commit: 15947 MB ``` **Not tested** - This PR's head on the retail title with `XCL_UMA_WINDOWS=16`: the A/B above is on our lab tree, not on this head, and the regression runs use the default 4-window layout, which this PR does not touch. - Other GPUs: AMD at all, NVIDIA cards with less than 24 GB (the extra video memory matters more there), the RTX 5070 Ti result is claudetools-gh's. - Other titles with 16 windows: a title whose large `MEM_64K_PAGES` reservations now fit in 16 GiB of sparse windows gets them in video memory, which is what the cap of 3 was there to avoid. - Acceleration-structure node counts from the GPU side on our card: our CPU-side log line (`acceleration structure at …: 0 nodes`) said 0 nodes in both runs; claudetools-gh's GPU-side read-back on an RTX 5070 Ti shows real trees, and that the CPU-side walk does not see the GPU's writes. - The whole suite with `XCL_UMA_WINDOWS=16 XCL_HEAP_WINDOWS=1`; Windows 10 and Wine. **AI use** AI use: the port of the switch, the new default, the tests, the A/B runs and their readings, and this description were done with Claude Code (Claude Opus 5.5), checked and posted by me. The switch itself is claudetools-gh's (#505). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
andresd-cerebras commented 2026-11-30 21:49:28 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by andresd-cerebras on 2026-11-30T21:49:28Z.

Review: COMMENTED


Withdrawn.

<!-- greyfinch-sync:ivall/xcl:review:6121174069 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#pullrequestreview-6121174069). Originally posted by [andresd-cerebras](https://github.com/andresd-cerebras) on 2026-11-30T21:49:28Z. **Review:** COMMENTED --- Withdrawn.
andresd-cerebras commented 2026-11-30 21:49:29 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by andresd-cerebras on 2026-11-30T21:49:29Z.

Code review location: crates/xcl/src/gpu/uma.rs; line 48

@@ -34,12 +34,32 @@ pub const MAX_WINDOWS: usize = 4;
 /// Maximum number of windows addressable through the shared descriptor heap (`XCL_HEAP_WINDOWS=1`).
 pub const MAX_HEAP_WINDOWS: usize = 16;
 
-/// Maximum sparse VRAM windows reserved in runtime layouts (3 × 4 GiB = 12 GiB VA).
+/// Maximum sparse VRAM windows reserved in the 4- and 8-window runtime layouts (3 × 4 GiB = 12 GiB VA).
 /// Keeping sparse VA capped at 12 GiB prevents huge startup `MEM_64K_PAGES` title heaps from
 /// being pulled into sparse VRAM (which causes multi-minute tile-mapping stalls and multi-GB
 /// sparse pool bloat), while still giving expanded 8/16-window layouts extra coherent windows.
 const MAX_RUNTIME_SPARSE_WINDOWS: usize = 3;
 
+/// Sparse VRAM windows of the 16-window layout (4 × 4 GiB = 16 GiB VA): one more, taken from the
+/// windows it leaves empty (4 sparse + 1 coherent + 6 view windows of 16), so it costs no address
+/// space. A retail title's BVH builder works in a 3.5 GB `MEM_RESERVE | MEM_64K_PAGES` reservation
+/// made once windows 1..2 are taken: with 3 it found no room and became plain write-watched
+/// memory, which shaders read as zeros (every acceleration structure stayed empty).
+const SIXTEEN_WINDOW_SPARSE_WINDOWS: usize = 4;

With 4 sparse windows the coherent window moves from 3 to 4, out of the switch form's reach (root UAVs cover windows 0..3; see with_switch_fallback in real.rs). Pipelines rebuilt in the switch form after an E_OUTOFMEMORY (#156) would then read 0 from spilled root arguments and per-draw data. Could the 4th sparse window go after the coherent window instead?

<!-- greyfinch-sync:ivall/xcl:review-comment:4745982860 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#discussion_r4745982860). Originally posted by [andresd-cerebras](https://github.com/andresd-cerebras) on 2026-11-30T21:49:29Z. **Code review location:** `crates/xcl/src/gpu/uma.rs`; line 48 ~~~~diff @@ -34,12 +34,32 @@ pub const MAX_WINDOWS: usize = 4; /// Maximum number of windows addressable through the shared descriptor heap (`XCL_HEAP_WINDOWS=1`). pub const MAX_HEAP_WINDOWS: usize = 16; -/// Maximum sparse VRAM windows reserved in runtime layouts (3 × 4 GiB = 12 GiB VA). +/// Maximum sparse VRAM windows reserved in the 4- and 8-window runtime layouts (3 × 4 GiB = 12 GiB VA). /// Keeping sparse VA capped at 12 GiB prevents huge startup `MEM_64K_PAGES` title heaps from /// being pulled into sparse VRAM (which causes multi-minute tile-mapping stalls and multi-GB /// sparse pool bloat), while still giving expanded 8/16-window layouts extra coherent windows. const MAX_RUNTIME_SPARSE_WINDOWS: usize = 3; +/// Sparse VRAM windows of the 16-window layout (4 × 4 GiB = 16 GiB VA): one more, taken from the +/// windows it leaves empty (4 sparse + 1 coherent + 6 view windows of 16), so it costs no address +/// space. A retail title's BVH builder works in a 3.5 GB `MEM_RESERVE | MEM_64K_PAGES` reservation +/// made once windows 1..2 are taken: with 3 it found no room and became plain write-watched +/// memory, which shaders read as zeros (every acceleration structure stayed empty). +const SIXTEEN_WINDOW_SPARSE_WINDOWS: usize = 4; ~~~~ --- With 4 sparse windows the coherent window moves from 3 to 4, out of the switch form's reach (root UAVs cover windows 0..3; see `with_switch_fallback` in real.rs). Pipelines rebuilt in the switch form after an E_OUTOFMEMORY (#156) would then read 0 from spilled root arguments and per-draw data. Could the 4th sparse window go after the coherent window instead?
andresd-cerebras commented 2026-11-30 21:49:29 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by andresd-cerebras on 2026-11-30T21:49:29Z.

Code review location: crates/xcl/src/gpu/recomp/tests.rs; line 5273

@@ -5267,6 +5267,12 @@ fn gpu_sparse_vram_descriptors_buffers_and_xmem() {
     // 4 windows, or 16 with `XCL_UMA_WINDOWS=16` (windows 0..3 as with 4; then view windows and
     // windows without memory)
     assert_eq!(u.shader_windows(), crate::gpu::uma::configured_runtime_windows(), "runtime layout has the configured shader windows");
+    // 16 windows keep 4 sparse windows, so the coherent window is window 4, which this program's
+    // 4 root-UAV windows do not reach (`XCL_SPARSE_WINDOWS=3` runs it with 16 windows)
+    if u.committed_window() != Some(3) {
+        runner::skip_test("the coherent window is not window 3");

This skip is the regression from uma.rs L48 showing up: the 16-window GPU coverage of this path is gone rather than fixed.

<!-- greyfinch-sync:ivall/xcl:review-comment:4745982881 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#discussion_r4745982881). Originally posted by [andresd-cerebras](https://github.com/andresd-cerebras) on 2026-11-30T21:49:29Z. **Code review location:** `crates/xcl/src/gpu/recomp/tests.rs`; line 5273 ~~~~diff @@ -5267,6 +5267,12 @@ fn gpu_sparse_vram_descriptors_buffers_and_xmem() { // 4 windows, or 16 with `XCL_UMA_WINDOWS=16` (windows 0..3 as with 4; then view windows and // windows without memory) assert_eq!(u.shader_windows(), crate::gpu::uma::configured_runtime_windows(), "runtime layout has the configured shader windows"); + // 16 windows keep 4 sparse windows, so the coherent window is window 4, which this program's + // 4 root-UAV windows do not reach (`XCL_SPARSE_WINDOWS=3` runs it with 16 windows) + if u.committed_window() != Some(3) { + runner::skip_test("the coherent window is not window 3"); ~~~~ --- This skip is the regression from uma.rs L48 showing up: the 16-window GPU coverage of this path is gone rather than fixed.
andresd-cerebras commented 2026-11-30 21:49:29 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by andresd-cerebras on 2026-11-30T21:49:29Z.

Code review location: crates/xcl/src/gpu/uma.rs; line 1713

@@ -1651,6 +1680,79 @@ mod tests {
         assert!(u.watch_regions().iter().all(|&(a, n)| a + n <= c + c_len), "{:x?}", u.watch_regions());
     }
 
+    /// `XCL_SPARSE_WINDOWS`: a number from 1 to 8, the layout's default otherwise (4 with 16
+    /// windows, 3 below); and with any of them the 16-window layout's sparse, coherent and view
+    /// windows still fit in its 16 windows.
+    #[test]
+    fn sparse_windows_setting_parses_clamps_and_fits_the_layout() {
+        for (v, n) in [(None, 4), (Some(""), 4), (Some("four"), 4), (Some("-1"), 4), (Some(" 3 "), 3), (Some("0"), 1), (Some("8"), 8), (Some("99"), 8)] {
+            assert_eq!(sparse_windows_setting(v, MAX_HEAP_WINDOWS), n, "{v:?}");
+        }
+        for windows in [MAX_WINDOWS, 8] {
+            assert_eq!(sparse_windows_setting(None, windows), MAX_RUNTIME_SPARSE_WINDOWS);
+            assert_eq!(sparse_windows_setting(Some("5"), windows), 5);
+        }
+        for n in 1..=8 {
+            let max_coh = max_coherent_windows_for(MAX_HEAP_WINDOWS, n);
+            assert!(max_coh >= 1 && n + max_coh + VIEW_WINDOWS <= MAX_HEAP_WINDOWS, "{n} sparse: {max_coh} coherent");
+            for coh in 1..=max_coh {
+                let sparse = (MAX_HEAP_WINDOWS - coh).min(n);
+                assert!(sparse + coh + VIEW_WINDOWS <= MAX_HEAP_WINDOWS, "{n} sparse, {coh} coherent");
+            }
+        }
+        assert_eq!(max_coherent_windows_for(MAX_HEAP_WINDOWS, 3), 7);
+        assert_eq!(max_coherent_windows_for(MAX_HEAP_WINDOWS, 4), 6);
+        // a 5094 MB coherent plan still gets its 2 coherent windows (4 + 2 + 6 = 12 of 16)
+        assert_eq!(coherent_window_sizes(5094 << 20, 5094 << 20, MAX_HEAP_WINDOWS).len(), 2);
+    }
+
+    /// The 16-window layout: windows 0..3 sparse, the coherent window 4, the views 5..10, the rest
+    /// reserved and empty; the whole aperture stays reserved and the sparse windows are one
+    /// write-watched region.
+    #[test]
+    fn sixteen_windows_keep_four_sparse_windows() {

These tests go through runtime_sparse_windows, which reads XCL_SPARSE_WINDOWS. With the XCL_SPARSE_WINDOWS=3 the PR recommends for the GPU test, this and the BVH/expanded-layout tests fail. Pass the sparse count explicitly (as max_coherent_windows_for does) so the tests don't depend on the environment.

<!-- greyfinch-sync:ivall/xcl:review-comment:4745982889 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#discussion_r4745982889). Originally posted by [andresd-cerebras](https://github.com/andresd-cerebras) on 2026-11-30T21:49:29Z. **Code review location:** `crates/xcl/src/gpu/uma.rs`; line 1713 ~~~~diff @@ -1651,6 +1680,79 @@ mod tests { assert!(u.watch_regions().iter().all(|&(a, n)| a + n <= c + c_len), "{:x?}", u.watch_regions()); } + /// `XCL_SPARSE_WINDOWS`: a number from 1 to 8, the layout's default otherwise (4 with 16 + /// windows, 3 below); and with any of them the 16-window layout's sparse, coherent and view + /// windows still fit in its 16 windows. + #[test] + fn sparse_windows_setting_parses_clamps_and_fits_the_layout() { + for (v, n) in [(None, 4), (Some(""), 4), (Some("four"), 4), (Some("-1"), 4), (Some(" 3 "), 3), (Some("0"), 1), (Some("8"), 8), (Some("99"), 8)] { + assert_eq!(sparse_windows_setting(v, MAX_HEAP_WINDOWS), n, "{v:?}"); + } + for windows in [MAX_WINDOWS, 8] { + assert_eq!(sparse_windows_setting(None, windows), MAX_RUNTIME_SPARSE_WINDOWS); + assert_eq!(sparse_windows_setting(Some("5"), windows), 5); + } + for n in 1..=8 { + let max_coh = max_coherent_windows_for(MAX_HEAP_WINDOWS, n); + assert!(max_coh >= 1 && n + max_coh + VIEW_WINDOWS <= MAX_HEAP_WINDOWS, "{n} sparse: {max_coh} coherent"); + for coh in 1..=max_coh { + let sparse = (MAX_HEAP_WINDOWS - coh).min(n); + assert!(sparse + coh + VIEW_WINDOWS <= MAX_HEAP_WINDOWS, "{n} sparse, {coh} coherent"); + } + } + assert_eq!(max_coherent_windows_for(MAX_HEAP_WINDOWS, 3), 7); + assert_eq!(max_coherent_windows_for(MAX_HEAP_WINDOWS, 4), 6); + // a 5094 MB coherent plan still gets its 2 coherent windows (4 + 2 + 6 = 12 of 16) + assert_eq!(coherent_window_sizes(5094 << 20, 5094 << 20, MAX_HEAP_WINDOWS).len(), 2); + } + + /// The 16-window layout: windows 0..3 sparse, the coherent window 4, the views 5..10, the rest + /// reserved and empty; the whole aperture stays reserved and the sparse windows are one + /// write-watched region. + #[test] + fn sixteen_windows_keep_four_sparse_windows() { ~~~~ --- These tests go through `runtime_sparse_windows`, which reads `XCL_SPARSE_WINDOWS`. With the `XCL_SPARSE_WINDOWS=3` the PR recommends for the GPU test, this and the BVH/expanded-layout tests fail. Pass the sparse count explicitly (as `max_coherent_windows_for` does) so the tests don't depend on the environment.
andresd-cerebras commented 2026-11-30 21:49:29 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by andresd-cerebras on 2026-11-30T21:49:29Z.

Code review location: crates/xcl/src/gpu/uma.rs; line 60

@@ -34,12 +34,32 @@ pub const MAX_WINDOWS: usize = 4;
 /// Maximum number of windows addressable through the shared descriptor heap (`XCL_HEAP_WINDOWS=1`).
 pub const MAX_HEAP_WINDOWS: usize = 16;
 
-/// Maximum sparse VRAM windows reserved in runtime layouts (3 × 4 GiB = 12 GiB VA).
+/// Maximum sparse VRAM windows reserved in the 4- and 8-window runtime layouts (3 × 4 GiB = 12 GiB VA).
 /// Keeping sparse VA capped at 12 GiB prevents huge startup `MEM_64K_PAGES` title heaps from
 /// being pulled into sparse VRAM (which causes multi-minute tile-mapping stalls and multi-GB
 /// sparse pool bloat), while still giving expanded 8/16-window layouts extra coherent windows.
 const MAX_RUNTIME_SPARSE_WINDOWS: usize = 3;
 
+/// Sparse VRAM windows of the 16-window layout (4 × 4 GiB = 16 GiB VA): one more, taken from the
+/// windows it leaves empty (4 sparse + 1 coherent + 6 view windows of 16), so it costs no address
+/// space. A retail title's BVH builder works in a 3.5 GB `MEM_RESERVE | MEM_64K_PAGES` reservation
+/// made once windows 1..2 are taken: with 3 it found no room and became plain write-watched
+/// memory, which shaders read as zeros (every acceleration structure stayed empty).
+const SIXTEEN_WINDOW_SPARSE_WINDOWS: usize = 4;
+
+/// The sparse VRAM windows of a runtime layout of `windows` windows: `XCL_SPARSE_WINDOWS=<n>`
+/// (1..=8), else 4 with 16 windows and 3 below.
+fn runtime_sparse_windows(windows: usize) -> usize {
+    sparse_windows_setting(std::env::var("XCL_SPARSE_WINDOWS").ok().as_deref(), windows)
+}
+
+/// `runtime_sparse_windows` for the value `v` of `XCL_SPARSE_WINDOWS` (unset or not a number: the
+/// layout's default).
+fn sparse_windows_setting(v: Option<&str>, windows: usize) -> usize {
+    let default = if windows == MAX_HEAP_WINDOWS { SIXTEEN_WINDOW_SPARSE_WINDOWS } else { MAX_RUNTIME_SPARSE_WINDOWS };
+    v.and_then(|v| v.trim().parse::<usize>().ok()).map_or(default, |n| n.clamp(1, 8))

clamp(1, 8) regardless of layout: with 4 windows 4..8 silently become 3, and 1..2 leave root-UAV windows empty. Clamp to what the layout can hold, and say so in the README.

<!-- greyfinch-sync:ivall/xcl:review-comment:4745982901 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#discussion_r4745982901). Originally posted by [andresd-cerebras](https://github.com/andresd-cerebras) on 2026-11-30T21:49:29Z. **Code review location:** `crates/xcl/src/gpu/uma.rs`; line 60 ~~~~diff @@ -34,12 +34,32 @@ pub const MAX_WINDOWS: usize = 4; /// Maximum number of windows addressable through the shared descriptor heap (`XCL_HEAP_WINDOWS=1`). pub const MAX_HEAP_WINDOWS: usize = 16; -/// Maximum sparse VRAM windows reserved in runtime layouts (3 × 4 GiB = 12 GiB VA). +/// Maximum sparse VRAM windows reserved in the 4- and 8-window runtime layouts (3 × 4 GiB = 12 GiB VA). /// Keeping sparse VA capped at 12 GiB prevents huge startup `MEM_64K_PAGES` title heaps from /// being pulled into sparse VRAM (which causes multi-minute tile-mapping stalls and multi-GB /// sparse pool bloat), while still giving expanded 8/16-window layouts extra coherent windows. const MAX_RUNTIME_SPARSE_WINDOWS: usize = 3; +/// Sparse VRAM windows of the 16-window layout (4 × 4 GiB = 16 GiB VA): one more, taken from the +/// windows it leaves empty (4 sparse + 1 coherent + 6 view windows of 16), so it costs no address +/// space. A retail title's BVH builder works in a 3.5 GB `MEM_RESERVE | MEM_64K_PAGES` reservation +/// made once windows 1..2 are taken: with 3 it found no room and became plain write-watched +/// memory, which shaders read as zeros (every acceleration structure stayed empty). +const SIXTEEN_WINDOW_SPARSE_WINDOWS: usize = 4; + +/// The sparse VRAM windows of a runtime layout of `windows` windows: `XCL_SPARSE_WINDOWS=<n>` +/// (1..=8), else 4 with 16 windows and 3 below. +fn runtime_sparse_windows(windows: usize) -> usize { + sparse_windows_setting(std::env::var("XCL_SPARSE_WINDOWS").ok().as_deref(), windows) +} + +/// `runtime_sparse_windows` for the value `v` of `XCL_SPARSE_WINDOWS` (unset or not a number: the +/// layout's default). +fn sparse_windows_setting(v: Option<&str>, windows: usize) -> usize { + let default = if windows == MAX_HEAP_WINDOWS { SIXTEEN_WINDOW_SPARSE_WINDOWS } else { MAX_RUNTIME_SPARSE_WINDOWS }; + v.and_then(|v| v.trim().parse::<usize>().ok()).map_or(default, |n| n.clamp(1, 8)) ~~~~ --- `clamp(1, 8)` regardless of layout: with 4 windows 4..8 silently become 3, and 1..2 leave root-UAV windows empty. Clamp to what the layout can hold, and say so in the README.
thehollowedone commented 2026-12-01 00:15:05 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by thehollowedone on 2026-12-01T00:15:05Z.


Focused follow-up on head 0b4283d: the default 16-window layout puts coherent memory in window 4, while pso::in_switch_form translates only windows 0–3. That fallback is used when the driver refuses a heap-window pipeline with E_OUTOFMEMORY. It cannot access both the new sparse window 3 and coherent window 4; swapping their positions would only change which one it loses.

I added the test-only regression below to a clean merge of this head onto main d0832e6. cargo test --offline --locked -p xcl --lib first_coherent_window_remains_reachable_by_switch_fallback -- --test-threads=1 failed 0 passed, 1 failed, 0 ignored with the default 16-window layout: “the switch fallback translates 4 windows but coherent memory starts in window 4.” On the same merged code with XCL_SPARSE_WINDOWS=3, it passed 1 passed, 0 failed, 0 ignored. This checks the layout and translation reach; I did not force a GPU pipeline fallback or run the full suite or a title.

For the intended four-sparse-window behavior, the fallback needs a path that can address both sparse window 3 and coherent window 4. Please carry the wider reach through translation, root signature and binding, and test a forced fallback that reads distinct nonzero sentinels from both in one dispatch. Keeping three sparse windows as the default until that path works would avoid introducing the gap while the wider fallback is developed.

Test-only regression diff
diff --git a/crates/xcl/src/gpu/uma.rs b/crates/xcl/src/gpu/uma.rs
index 5d9df8ff..69ee1f26 100644
--- a/crates/xcl/src/gpu/uma.rs
+++ b/crates/xcl/src/gpu/uma.rs
@@ -1276,6 +1276,20 @@ pub fn get() -> Option<&'static Uma> {
 mod tests {
     use super::*;
 
+    #[test]
+    fn first_coherent_window_remains_reachable_by_switch_fallback() {
+        let u = Uma::for_runtime_windows(16 << 20, RUNTIME_COMMITTED_CAP, MAX_HEAP_WINDOWS)
+            .expect("16-window aperture");
+        let coherent = u.committed_window().expect("coherent window");
+        let reachable = crate::gpu::recomp::pso::in_switch_form(|| {
+            crate::gpu::recomp::pso::windows_for(u.shader_windows() as u32)
+        }) as usize;
+        assert!(
+            coherent < reachable,
+            "the switch fallback translates {reachable} windows but coherent memory starts in window {coherent}"
+        );
+    }
+
     /// Arena blocks come from XCL's pool while the title holds the rest of window 0, and go
     /// back to it when freed.
     #[test]

AI use: OpenAI Codex (GPT-6.2 Sol) wrote and ran the focused test and drafted this report; OpenAI Codex (GPT-6.2 Astra) reviewed the fallback design.

<!-- greyfinch-sync:ivall/xcl:comment:7296112422 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#issuecomment-7296112422). Originally posted by [thehollowedone](https://github.com/thehollowedone) on 2026-12-01T00:15:05Z. --- Focused follow-up on [head `0b4283d`](https://github.com/xcl-dev/xcl/commit/0b4283d147b7bd5f93a9cc3d83433cdcdef9762f): the default 16-window layout puts coherent memory in window 4, while `pso::in_switch_form` translates only windows 0–3. That fallback is used when the driver refuses a heap-window pipeline with `E_OUTOFMEMORY`. It cannot access both the new sparse window 3 and coherent window 4; swapping their positions would only change which one it loses. I added the test-only regression below to a clean merge of this head onto `main` `d0832e6`. `cargo test --offline --locked -p xcl --lib first_coherent_window_remains_reachable_by_switch_fallback -- --test-threads=1` failed **0 passed, 1 failed, 0 ignored** with the default 16-window layout: “the switch fallback translates 4 windows but coherent memory starts in window 4.” On the same merged code with `XCL_SPARSE_WINDOWS=3`, it passed **1 passed, 0 failed, 0 ignored**. This checks the layout and translation reach; I did not force a GPU pipeline fallback or run the full suite or a title. For the intended four-sparse-window behavior, the fallback needs a path that can address both sparse window 3 and coherent window 4. Please carry the wider reach through translation, root signature and binding, and test a forced fallback that reads distinct nonzero sentinels from both in one dispatch. Keeping three sparse windows as the default until that path works would avoid introducing the gap while the wider fallback is developed. <details> <summary>Test-only regression diff</summary> ```diff diff --git a/crates/xcl/src/gpu/uma.rs b/crates/xcl/src/gpu/uma.rs index 5d9df8ff..69ee1f26 100644 --- a/crates/xcl/src/gpu/uma.rs +++ b/crates/xcl/src/gpu/uma.rs @@ -1276,6 +1276,20 @@ pub fn get() -> Option<&'static Uma> { mod tests { use super::*; + #[test] + fn first_coherent_window_remains_reachable_by_switch_fallback() { + let u = Uma::for_runtime_windows(16 << 20, RUNTIME_COMMITTED_CAP, MAX_HEAP_WINDOWS) + .expect("16-window aperture"); + let coherent = u.committed_window().expect("coherent window"); + let reachable = crate::gpu::recomp::pso::in_switch_form(|| { + crate::gpu::recomp::pso::windows_for(u.shader_windows() as u32) + }) as usize; + assert!( + coherent < reachable, + "the switch fallback translates {reachable} windows but coherent memory starts in window {coherent}" + ); + } + /// Arena blocks come from XCL's pool while the title holds the rest of window 0, and go /// back to it when freed. #[test] ``` </details> AI use: OpenAI Codex (GPT-6.2 Sol) wrote and ran the focused test and drafted this report; OpenAI Codex (GPT-6.2 Astra) reviewed the fallback design.
Foniass commented 2026-12-01 08:45:02 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Foniass on 2026-12-01T08:45:02Z.


merge-check
base: 7d86c5d2b7
head: 0b4283d147
merge: clean
build: cargo build --workspace -> ok
tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 2899 passed, 0 failed, 51 ignored; SKIPPED: 28 (20 no wave64, 2 no d3d12SDKLayers.dll, 1 no D3D12 debug layer, 1 no heap windows, 1 cannot disable the driver cache, 3 others; the same set as on main); failing: none
review: read the whole diff (uma.rs +137/-35, console_heap.rs and recomp/tests.rs tests, README). Nothing changes by default: only XCL_UMA_WINDOWS=16 (which needs XCL_HEAP_WINDOWS=1) gets 4 sparse windows, with the coherent window moving to 4, the views to 5..10, and the coherent cap dropping from 7 to 6 windows; runtime users find windows by kind (committed_window() / is_sparse_window() / is_view_window()), so nothing is hard-wired to window 3. Findings: (1) nothing measures this head with XCL_UMA_WINDOWS=16: the PR's smoke pair uses the default 4-window layout this doesn't touch, and the retail A/B is from a lab tree. (2) #2905 places physical page homes from the top of the last sparse window (sparse_end()) down, which with this PR is window 3, the window the BVH reservation needs; both also edit the_series_x_plan_is_pinned, so whichever merges second needs a rebase that keeps both in mind. (3) recomp/tests.rs ~5273 suggests XCL_SPARSE_WINDOWS=3 to run that test with 16 windows, but that setting makes the new uma.rs layout tests fail in the same run. (4) On main, a_bvh_scratch_reservation_lands_in_the_fourth_sparse_window fails because the reservation fits in window 0, not because there's no room; the test doesn't fill window 0 as the retail title does. (5) With 4 windows, XCL_SPARSE_WINDOWS above 3 does nothing, while the README says 1 to 8. Fine: the layout fits 16 windows for 1..=8 sparse windows and the whole aperture stays reserved; no conflict with #3546.
performance: no smoke run (the default path doesn't reach this change); not measured. Nothing changes by default (the 16-window layout needs XCL_UMA_WINDOWS=16 and XCL_HEAP_WINDOWS=1), so no smoke run; the opt-in layout is unmeasured on this head.
verdict: safe to merge
hardware / tool and model: RTX 5070 Ti (driver 621.14), Ryzen 7 7800X3D, Windows 11 26300 / Claude Code with Claude Opus 5.5

AI-written and posted by Foniass without a human check of each point.

<!-- greyfinch-sync:ivall/xcl:comment:7305730447 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#issuecomment-7305730447). Originally posted by [Foniass](https://github.com/Foniass) on 2026-12-01T08:45:02Z. --- merge-check base: 7d86c5d2b7845695031eeea1327aa81b6c439323 head: 0b4283d147b7bd5f93a9cc3d83433cdcdef9762f merge: clean build: cargo build --workspace -> ok tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 2899 passed, 0 failed, 51 ignored; SKIPPED: 28 (20 no wave64, 2 no d3d12SDKLayers.dll, 1 no D3D12 debug layer, 1 no heap windows, 1 cannot disable the driver cache, 3 others; the same set as on main); failing: none review: read the whole diff (uma.rs +137/-35, console_heap.rs and recomp/tests.rs tests, README). Nothing changes by default: only `XCL_UMA_WINDOWS=16` (which needs `XCL_HEAP_WINDOWS=1`) gets 4 sparse windows, with the coherent window moving to 4, the views to 5..10, and the coherent cap dropping from 7 to 6 windows; runtime users find windows by kind (`committed_window()` / `is_sparse_window()` / `is_view_window()`), so nothing is hard-wired to window 3. Findings: (1) nothing measures this head with `XCL_UMA_WINDOWS=16`: the PR's smoke pair uses the default 4-window layout this doesn't touch, and the retail A/B is from a lab tree. (2) #2905 places physical page homes from the top of the last sparse window (`sparse_end()`) down, which with this PR is window 3, the window the BVH reservation needs; both also edit `the_series_x_plan_is_pinned`, so whichever merges second needs a rebase that keeps both in mind. (3) `recomp/tests.rs` ~5273 suggests `XCL_SPARSE_WINDOWS=3` to run that test with 16 windows, but that setting makes the new uma.rs layout tests fail in the same run. (4) On main, `a_bvh_scratch_reservation_lands_in_the_fourth_sparse_window` fails because the reservation fits in window 0, not because there's no room; the test doesn't fill window 0 as the retail title does. (5) With 4 windows, `XCL_SPARSE_WINDOWS` above 3 does nothing, while the README says 1 to 8. Fine: the layout fits 16 windows for 1..=8 sparse windows and the whole aperture stays reserved; no conflict with #3546. performance: no smoke run (the default path doesn't reach this change); not measured. Nothing changes by default (the 16-window layout needs `XCL_UMA_WINDOWS=16` and `XCL_HEAP_WINDOWS=1`), so no smoke run; the opt-in layout is unmeasured on this head. verdict: safe to merge hardware / tool and model: RTX 5070 Ti (driver 621.14), Ryzen 7 7800X3D, Windows 11 26300 / Claude Code with Claude Opus 5.5 AI-written and posted by Foniass without a human check of each point.
brainhay5 commented 2026-12-01 09:38:10 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by brainhay5 on 2026-12-01T09:38:10Z.


merge-check claim
head: 0b4283d147

<!-- greyfinch-sync:ivall/xcl:comment:7306985520 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#issuecomment-7306985520). Originally posted by [brainhay5](https://github.com/brainhay5) on 2026-12-01T09:38:10Z. --- merge-check claim head: 0b4283d147b7bd5f93a9cc3d83433cdcdef9762f
Foniass commented 2026-12-01 10:07:53 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Foniass on 2026-12-01T10:07:53Z.


Triage (#1607) – head 0b4283d

No other open PR changes the number of sparse windows. #3521/#3522 also target XboxBvhBuilder memory, but under XCL_SPARSE_LAZY=1 (tiles with no video memory), not a reservation that finds no room in the sparse windows; they do not overlap.
Notes on the diff: uma.rs:max_coherent_windows for 16 windows drops from 7 to 6, so a coherent need above 6 windows is now cut to 6 unless XCL_SPARSE_WINDOWS=3. The doc comment on MAX_RUNTIME_SPARSE_WINDOWS warns that more sparse VA pulls large startup MEM_64K_PAGES heaps into sparse VRAM (tile-mapping stalls); a 4th window brings that risk back for 16 windows. In recomp/tests.rs, gpu_sparse_vram_descriptors_buffers_and_xmem now calls skip_test whenever the coherent window is not window 3, so it skips by default with 16 windows: that is a configuration skip, not a missing-hardware skip. The README says 1 to 8, but with 4 windows more than 3 has no effect.
Recommendation: keep open.

AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.

<!-- greyfinch-sync:ivall/xcl:comment:7307715832 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#issuecomment-7307715832). Originally posted by [Foniass](https://github.com/Foniass) on 2026-12-01T10:07:53Z. --- **Triage (#1607)** – head 0b4283d No other open PR changes the number of sparse windows. #3521/#3522 also target XboxBvhBuilder memory, but under `XCL_SPARSE_LAZY=1` (tiles with no video memory), not a reservation that finds no room in the sparse windows; they do not overlap. Notes on the diff: `uma.rs:max_coherent_windows` for 16 windows drops from 7 to 6, so a coherent need above 6 windows is now cut to 6 unless `XCL_SPARSE_WINDOWS=3`. The doc comment on `MAX_RUNTIME_SPARSE_WINDOWS` warns that more sparse VA pulls large startup `MEM_64K_PAGES` heaps into sparse VRAM (tile-mapping stalls); a 4th window brings that risk back for 16 windows. In `recomp/tests.rs`, `gpu_sparse_vram_descriptors_buffers_and_xmem` now calls `skip_test` whenever the coherent window is not window 3, so it skips by default with 16 windows: that is a configuration skip, not a missing-hardware skip. The README says 1 to 8, but with 4 windows more than 3 has no effect. Recommendation: keep open. AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.
brainhay5 commented 2026-12-01 11:48:18 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by brainhay5 on 2026-12-01T11:48:18Z.


merge-check claim withdrawn
Our automated merge-check loop claimed this PR and then stopped before posting a check — two loops were running at once and both are now shut down. No check from us is coming, so this claim is void and the head is free for someone else to take.

AI use: an agent posted this withdrawal.

<!-- greyfinch-sync:ivall/xcl:comment:7310166824 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#issuecomment-7310166824). Originally posted by [brainhay5](https://github.com/brainhay5) on 2026-12-01T11:48:18Z. --- merge-check claim withdrawn Our automated merge-check loop claimed this PR and then stopped before posting a check — two loops were running at once and both are now shut down. No check from us is coming, so this claim is void and the head is free for someone else to take. *AI use: an agent posted this withdrawal.*
Hurtibabi commented 2026-12-01 16:39:01 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Hurtibabi on 2026-12-01T16:39:01Z.


merge-check
base: 6bfb5c5153
head: 0b4283d147
merge: clean
build: cargo build --workspace -> ok
tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 2907 passed, 0 failed, 51 ignored; SKIPPED: 28 (22 no wave64, 2 no d3d12SDKLayers.dll, 2 no heap windows, 1 no D3D12 debug layer, 1 cannot disable the driver cache without Developer Mode); failing: none
review: read the whole diff (uma.rs, recomp/tests.rs, console_heap.rs, README). (1) With XCL_UMA_WINDOWS=16 the coherent window moves from 3 to 4, but the switch form that with_switch_fallback (real.rs ~5175) uses when the driver refuses a heap-window pipeline (#156) reaches only windows 0..3 (pso::windows_for_mode, emit.rs ~5079). Such pipelines lose the coherent window (title coherent memory, per-draw args, readback buffers) and read it as 0. This confirms thehollowedone's finding; I ran their test-only regression (first_coherent_window_remains_reachable_by_switch_fallback, added to the merge and removed again, not part of the counts above): cargo test -p xcl --lib first_coherent_window_remains_reachable_by_switch_fallback -- --test-threads=1 -> 0 passed, 1 failed ("the switch fallback translates 4 windows but coherent memory starts in window 4"); with XCL_SPARSE_WINDOWS=3 -> 1 passed, 0 failed. The PR does not mention this, and gpu_sparse_vram_descriptors_buffers_and_xmem now skips exactly this case with a configuration reason, not a missing-hardware one. (2) The new layout tests read XCL_SPARSE_WINDOWS through for_runtime_windows, so the XCL_SPARSE_WINDOWS=3 run suggested in recomp/tests.rs makes sixteen_windows_keep_four_sparse_windows and a_bvh_scratch_reservation_lands_in_the_fourth_sparse_window fail in that run (from the code, not run). (3) With 4 windows, values above 3 have no effect (reserve_runtime takes (windows - coh_wins).min(n)), while the README says 1 to 8. Nothing changes in the default 4-window layout. No duplicate: no open or merged PR changes the sparse window count (#1998 introduced the cap of 3; #3097 was closed), and #1607 has no group for it. Not tested: this head with XCL_UMA_WINDOWS=16 XCL_HEAP_WINDOWS=1 on a title, a forced switch-form fallback on the GPU, AMD.
performance: default layout unchanged, so no frame-time or memory cost by default (reasoned, no smoke run). With XCL_UMA_WINDOWS=16 more title memory can land in sparse VRAM; not measured here (the PR reports about 420 MB more video memory at the peak on its lab tree).
verdict: not yet: with 16 windows the switch-form fallback (#156) no longer reaches the coherent window (finding 1, reproduced with a test); not covered by the PR's tests or description
hardware / tool and model: NVIDIA GeForce RTX 4090 (driver 621.40 / 32.0.16.2140), Intel Core i7-14700K, Windows 11 Pro 10.0.26200.9974, rustc 1.100.1, debug / Claude Code, Claude Opus 5.5 (claude-opus-5-5)

<!-- greyfinch-sync:ivall/xcl:comment:7317963120 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#issuecomment-7317963120). Originally posted by [Hurtibabi](https://github.com/Hurtibabi) on 2026-12-01T16:39:01Z. --- merge-check base: 6bfb5c5153ccc23517daf30aa1071ddb0fadb53c head: 0b4283d147b7bd5f93a9cc3d83433cdcdef9762f merge: clean build: cargo build --workspace -> ok tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 2907 passed, 0 failed, 51 ignored; SKIPPED: 28 (22 no wave64, 2 no d3d12SDKLayers.dll, 2 no heap windows, 1 no D3D12 debug layer, 1 cannot disable the driver cache without Developer Mode); failing: none review: read the whole diff (uma.rs, recomp/tests.rs, console_heap.rs, README). (1) With `XCL_UMA_WINDOWS=16` the coherent window moves from 3 to 4, but the switch form that `with_switch_fallback` (`real.rs` ~5175) uses when the driver refuses a heap-window pipeline (#156) reaches only windows 0..3 (`pso::windows_for_mode`, `emit.rs` ~5079). Such pipelines lose the coherent window (title coherent memory, per-draw args, readback buffers) and read it as 0. This confirms thehollowedone's finding; I ran their test-only regression (`first_coherent_window_remains_reachable_by_switch_fallback`, added to the merge and removed again, not part of the counts above): `cargo test -p xcl --lib first_coherent_window_remains_reachable_by_switch_fallback -- --test-threads=1` -> 0 passed, 1 failed ("the switch fallback translates 4 windows but coherent memory starts in window 4"); with `XCL_SPARSE_WINDOWS=3` -> 1 passed, 0 failed. The PR does not mention this, and `gpu_sparse_vram_descriptors_buffers_and_xmem` now skips exactly this case with a configuration reason, not a missing-hardware one. (2) The new layout tests read `XCL_SPARSE_WINDOWS` through `for_runtime_windows`, so the `XCL_SPARSE_WINDOWS=3` run suggested in `recomp/tests.rs` makes `sixteen_windows_keep_four_sparse_windows` and `a_bvh_scratch_reservation_lands_in_the_fourth_sparse_window` fail in that run (from the code, not run). (3) With 4 windows, values above 3 have no effect (`reserve_runtime` takes `(windows - coh_wins).min(n)`), while the README says 1 to 8. Nothing changes in the default 4-window layout. No duplicate: no open or merged PR changes the sparse window count (#1998 introduced the cap of 3; #3097 was closed), and #1607 has no group for it. Not tested: this head with `XCL_UMA_WINDOWS=16 XCL_HEAP_WINDOWS=1` on a title, a forced switch-form fallback on the GPU, AMD. performance: default layout unchanged, so no frame-time or memory cost by default (reasoned, no smoke run). With `XCL_UMA_WINDOWS=16` more title memory can land in sparse VRAM; not measured here (the PR reports about 420 MB more video memory at the peak on its lab tree). verdict: not yet: with 16 windows the switch-form fallback (#156) no longer reaches the coherent window (finding 1, reproduced with a test); not covered by the PR's tests or description hardware / tool and model: NVIDIA GeForce RTX 4090 (driver 621.40 / 32.0.16.2140), Intel Core i7-14700K, Windows 11 Pro 10.0.26200.9974, rustc 1.100.1, debug / Claude Code, Claude Opus 5.5 (claude-opus-5-5)
Decodere commented 2026-12-02 08:46:36 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Decodere on 2026-12-02T08:46:36Z.


Diff review (head 0b4283d14, read-only code review — not a test report):

Clean layout math in uma.rs for adding a 4th sparse window to the 16-window aperture without disturbing the default 4-window layout. Two concrete issues remain on 0b4283d14:

  1. with_switch_fallback still caps shaders at 4 windows (0..3), cutting off coherent window 4 in the 16-window layout (crates/xcl/src/gpu/uma.rs:48, :59, :360-362; crates/xcl/src/hle/d3d12x/real.rs:5146-5159; crates/xcl/src/gpu/recomp/pso.rs:147-161, :176-185; crates/xcl/src/hle/d3d12x/bind.rs:5287-5290):
    With XCL_UMA_WINDOWS=16 (MAX_HEAP_WINDOWS), raising the default sparse window count to SIXTEEN_WINDOW_SPARSE_WINDOWS = 4 (uma.rs:48, :59) moves the first coherent window from window 3 to window 4 (uma.rs:360-362, :379). Whenever the driver refuses a heap-window pipeline with E_OUTOFMEMORY, with_switch_fallback (real.rs:5146-5159) rebuilds it inside pso::in_switch_form (pso.rs:176-185), where windows_for_mode(n, false) (pso.rs:148, :155-160) caps translation to MAX_WINDOWS = 4 (root UAVs 0..3 bound at bind.rs:5287-5290). Any pipeline taking switch fallback in the 16-window layout can no longer address coherent memory in window 4 (reads return 0), which is also why gpu_sparse_vram_descriptors_buffers_and_xmem had to skip when u.committed_window() != Some(3) (crates/xcl/src/gpu/recomp/tests.rs:5270-5275). Either keeping the coherent window within switch-fallback reach or extending fallback addressing to cover window 4 avoids silent data loss on driver OOM fallback.

  2. Unit tests are sensitive to ambient XCL_SPARSE_WINDOWS (crates/xcl/src/gpu/uma.rs:52-54, :77-79, :96-97, :349-362, :1507-1587, :1713-1755, :1810-1830):
    Uma::for_runtime_windows, max_coherent_windows, and coherent_window_sizes all call runtime_sparse_windows(windows) (uma.rs:52-54), which reads live std::env::var("XCL_SPARSE_WINDOWS"). However, the updated/new tests (runtime_layout_supports_eight_and_sixteen_heap_windows at uma.rs:1507, the_series_x_plan_is_pinned at :1558, sixteen_windows_keep_four_sparse_windows at :1713, a_bvh_scratch_reservation_lands_in_the_fourth_sparse_window at :1741, and expanded_runtime_layout_splits_large_coherent_heaps_across_multiple_windows at :1810) assert the default 4-sparse-window layout. Running cargo test with XCL_SPARSE_WINDOWS=3 (as suggested in crates/xcl/src/gpu/recomp/tests.rs:5271) therefore fails those 5 unit tests in the same run. Passing an explicit sparse-window count into reserve_runtime / test helpers (reading XCL_SPARSE_WINDOWS only in uma::get()) decouples unit tests from the environment.

Minor note: README.md:360-363 documents XCL_SPARSE_WINDOWS as 1 to 8, whereas in the 4-window layout reserve_runtime caps sparse_wins at windows - coh_wins = 3 (uma.rs:362), so values above 3 have no effect with 4 windows (and values above 7 have none with 8).

AI use: Antigravity (Gemini 4 Neon) audited the full diff against main and drafted this review.

<!-- greyfinch-sync:ivall/xcl:comment:7339911807 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#issuecomment-7339911807). Originally posted by [Decodere](https://github.com/Decodere) on 2026-12-02T08:46:36Z. --- Diff review (head `0b4283d14`, read-only code review — not a test report): Clean layout math in `uma.rs` for adding a 4th sparse window to the 16-window aperture without disturbing the default 4-window layout. Two concrete issues remain on `0b4283d14`: 1. **`with_switch_fallback` still caps shaders at 4 windows (`0..3`), cutting off coherent window `4` in the 16-window layout** (`crates/xcl/src/gpu/uma.rs:48`, `:59`, `:360-362`; `crates/xcl/src/hle/d3d12x/real.rs:5146-5159`; `crates/xcl/src/gpu/recomp/pso.rs:147-161`, `:176-185`; `crates/xcl/src/hle/d3d12x/bind.rs:5287-5290`): With `XCL_UMA_WINDOWS=16` (`MAX_HEAP_WINDOWS`), raising the default sparse window count to `SIXTEEN_WINDOW_SPARSE_WINDOWS = 4` (`uma.rs:48`, `:59`) moves the first coherent window from window `3` to window `4` (`uma.rs:360-362`, `:379`). Whenever the driver refuses a heap-window pipeline with `E_OUTOFMEMORY`, `with_switch_fallback` (`real.rs:5146-5159`) rebuilds it inside `pso::in_switch_form` (`pso.rs:176-185`), where `windows_for_mode(n, false)` (`pso.rs:148`, `:155-160`) caps translation to `MAX_WINDOWS = 4` (root UAVs `0..3` bound at `bind.rs:5287-5290`). Any pipeline taking switch fallback in the 16-window layout can no longer address coherent memory in window `4` (reads return `0`), which is also why `gpu_sparse_vram_descriptors_buffers_and_xmem` had to skip when `u.committed_window() != Some(3)` (`crates/xcl/src/gpu/recomp/tests.rs:5270-5275`). Either keeping the coherent window within switch-fallback reach or extending fallback addressing to cover window `4` avoids silent data loss on driver OOM fallback. 2. **Unit tests are sensitive to ambient `XCL_SPARSE_WINDOWS`** (`crates/xcl/src/gpu/uma.rs:52-54`, `:77-79`, `:96-97`, `:349-362`, `:1507-1587`, `:1713-1755`, `:1810-1830`): `Uma::for_runtime_windows`, `max_coherent_windows`, and `coherent_window_sizes` all call `runtime_sparse_windows(windows)` (`uma.rs:52-54`), which reads live `std::env::var("XCL_SPARSE_WINDOWS")`. However, the updated/new tests (`runtime_layout_supports_eight_and_sixteen_heap_windows` at `uma.rs:1507`, `the_series_x_plan_is_pinned` at `:1558`, `sixteen_windows_keep_four_sparse_windows` at `:1713`, `a_bvh_scratch_reservation_lands_in_the_fourth_sparse_window` at `:1741`, and `expanded_runtime_layout_splits_large_coherent_heaps_across_multiple_windows` at `:1810`) assert the default `4`-sparse-window layout. Running `cargo test` with `XCL_SPARSE_WINDOWS=3` (as suggested in `crates/xcl/src/gpu/recomp/tests.rs:5271`) therefore fails those 5 unit tests in the same run. Passing an explicit sparse-window count into `reserve_runtime` / test helpers (reading `XCL_SPARSE_WINDOWS` only in `uma::get()`) decouples unit tests from the environment. Minor note: `README.md:360-363` documents `XCL_SPARSE_WINDOWS` as `1 to 8`, whereas in the 4-window layout `reserve_runtime` caps `sparse_wins` at `windows - coh_wins = 3` (`uma.rs:362`), so values above 3 have no effect with 4 windows (and values above 7 have none with 8). AI use: Antigravity (Gemini 4 Neon) audited the full diff against `main` and drafted this review.
Gevroska commented 2026-12-02 10:46:45 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Gevroska on 2026-12-02T10:46:45Z.


I compared the production sparse allocator on main 1c8b5514 and head 0b4283d1 using native Windows VirtualAlloc. With the 16-window layout active, I held windows 1 and 2 and requested a 3.32 GiB reservation.

Window 0 at the time of the request Main PR head
Available Reserved in window 0 Reserved in window 3
1 GiB already held No sparse reservation Reserved in window 3

Setting XCL_SPARSE_WINDOWS=3 on the PR restored the main result in both cases. An independent repeat reproduced all six process-level controls.

This identifies a case where the fourth sparse window preserves a reservation that main cannot satisfy. The fixture exercised the CPU allocator only. The separate question raised above about a fallback shader reaching coherent window 4 still needs GPU validation.

OpenAI Codex GPT-6.2 Sol ran the test, a separate GPT-6.2 Sol agent repeated it, and GPT-6.2 Astra drafted this comment.

I reviewed and approved this comment before posting.

<!-- greyfinch-sync:ivall/xcl:comment:7342968007 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#issuecomment-7342968007). Originally posted by [Gevroska](https://github.com/Gevroska) on 2026-12-02T10:46:45Z. --- I compared the production sparse allocator on main `1c8b5514` and head `0b4283d1` using native Windows `VirtualAlloc`. With the 16-window layout active, I held windows 1 and 2 and requested a 3.32 GiB reservation. | Window 0 at the time of the request | Main | PR head | |---|---|---| | Available | Reserved in window 0 | Reserved in window 3 | | 1 GiB already held | No sparse reservation | Reserved in window 3 | Setting `XCL_SPARSE_WINDOWS=3` on the PR restored the main result in both cases. An independent repeat reproduced all six process-level controls. This identifies a case where the fourth sparse window preserves a reservation that main cannot satisfy. The fixture exercised the CPU allocator only. The separate question raised above about a fallback shader reaching coherent window 4 still needs GPU validation. OpenAI Codex GPT-6.2 Sol ran the test, a separate GPT-6.2 Sol agent repeated it, and GPT-6.2 Astra drafted this comment. I reviewed and approved this comment before posting.
bmjask commented 2026-12-02 10:46:55 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by bmjask on 2026-12-02T10:46:55Z.

Code review location: crates/xcl/src/gpu/uma.rs; line 47

@@ -34,12 +34,32 @@ pub const MAX_WINDOWS: usize = 4;
 /// Maximum number of windows addressable through the shared descriptor heap (`XCL_HEAP_WINDOWS=1`).
 pub const MAX_HEAP_WINDOWS: usize = 16;
 
-/// Maximum sparse VRAM windows reserved in runtime layouts (3 × 4 GiB = 12 GiB VA).
+/// Maximum sparse VRAM windows reserved in the 4- and 8-window runtime layouts (3 × 4 GiB = 12 GiB VA).
 /// Keeping sparse VA capped at 12 GiB prevents huge startup `MEM_64K_PAGES` title heaps from
 /// being pulled into sparse VRAM (which causes multi-minute tile-mapping stalls and multi-GB
 /// sparse pool bloat), while still giving expanded 8/16-window layouts extra coherent windows.
 const MAX_RUNTIME_SPARSE_WINDOWS: usize = 3;
 
+/// Sparse VRAM windows of the 16-window layout (4 × 4 GiB = 16 GiB VA): one more, taken from the
+/// windows it leaves empty (4 sparse + 1 coherent + 6 view windows of 16), so it costs no address
+/// space. A retail title's BVH builder works in a 3.5 GB `MEM_RESERVE | MEM_64K_PAGES` reservation
+/// made once windows 1..2 are taken: with 3 it found no room and became plain write-watched
+/// memory, which shaders read as zeros (every acceleration structure stayed empty).

With 4 sparse windows, the 16-window layout's coherent window moves from window 3 to window 4, which pipelines in the switch form (4 root UAVs, windows 0..3 only) can't reach. With XCL_UMA_WINDOWS=16 and XCL_HEAP_WINDOWS=1 on NVIDIA, a big program that gets E_OUTOFMEMORY with heap windows is rebuilt in the switch form by real::with_switch_fallback (real.rs:5145-5158). The same happens to every pipeline when console_heap::window_views_failed() turns pso::heap_windows() off. Window 3 is now an empty sparse window, so per-draw arguments, readback buffers, spilled root tables and coherent-window GPU heaps read 0 in those pipelines, and their writes are dropped. The skip added to gpu_sparse_vram_descriptors_buffers_and_xmem ("4 root-UAV windows do not reach" window 4) shows the regression rather than testing it.

<!-- greyfinch-sync:ivall/xcl:review-comment:4768348150 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#discussion_r4768348150). Originally posted by [bmjask](https://github.com/bmjask) on 2026-12-02T10:46:55Z. **Code review location:** `crates/xcl/src/gpu/uma.rs`; line 47 ~~~~diff @@ -34,12 +34,32 @@ pub const MAX_WINDOWS: usize = 4; /// Maximum number of windows addressable through the shared descriptor heap (`XCL_HEAP_WINDOWS=1`). pub const MAX_HEAP_WINDOWS: usize = 16; -/// Maximum sparse VRAM windows reserved in runtime layouts (3 × 4 GiB = 12 GiB VA). +/// Maximum sparse VRAM windows reserved in the 4- and 8-window runtime layouts (3 × 4 GiB = 12 GiB VA). /// Keeping sparse VA capped at 12 GiB prevents huge startup `MEM_64K_PAGES` title heaps from /// being pulled into sparse VRAM (which causes multi-minute tile-mapping stalls and multi-GB /// sparse pool bloat), while still giving expanded 8/16-window layouts extra coherent windows. const MAX_RUNTIME_SPARSE_WINDOWS: usize = 3; +/// Sparse VRAM windows of the 16-window layout (4 × 4 GiB = 16 GiB VA): one more, taken from the +/// windows it leaves empty (4 sparse + 1 coherent + 6 view windows of 16), so it costs no address +/// space. A retail title's BVH builder works in a 3.5 GB `MEM_RESERVE | MEM_64K_PAGES` reservation +/// made once windows 1..2 are taken: with 3 it found no room and became plain write-watched +/// memory, which shaders read as zeros (every acceleration structure stayed empty). ~~~~ --- With 4 sparse windows, the 16-window layout's coherent window moves from window 3 to window 4, which pipelines in the switch form (4 root UAVs, windows 0..3 only) can't reach. With XCL_UMA_WINDOWS=16 and XCL_HEAP_WINDOWS=1 on NVIDIA, a big program that gets E_OUTOFMEMORY with heap windows is rebuilt in the switch form by `real::with_switch_fallback` (real.rs:5145-5158). The same happens to every pipeline when `console_heap::window_views_failed()` turns `pso::heap_windows()` off. Window 3 is now an empty sparse window, so per-draw arguments, readback buffers, spilled root tables and coherent-window GPU heaps read 0 in those pipelines, and their writes are dropped. The skip added to `gpu_sparse_vram_descriptors_buffers_and_xmem` ("4 root-UAV windows do not reach" window 4) shows the regression rather than testing it.
bmjask commented 2026-12-02 10:46:55 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by bmjask on 2026-12-02T10:46:55Z.

Code review location: crates/xcl/src/gpu/uma.rs; line 60

@@ -34,12 +34,32 @@ pub const MAX_WINDOWS: usize = 4;
 /// Maximum number of windows addressable through the shared descriptor heap (`XCL_HEAP_WINDOWS=1`).
 pub const MAX_HEAP_WINDOWS: usize = 16;
 
-/// Maximum sparse VRAM windows reserved in runtime layouts (3 × 4 GiB = 12 GiB VA).
+/// Maximum sparse VRAM windows reserved in the 4- and 8-window runtime layouts (3 × 4 GiB = 12 GiB VA).
 /// Keeping sparse VA capped at 12 GiB prevents huge startup `MEM_64K_PAGES` title heaps from
 /// being pulled into sparse VRAM (which causes multi-minute tile-mapping stalls and multi-GB
 /// sparse pool bloat), while still giving expanded 8/16-window layouts extra coherent windows.
 const MAX_RUNTIME_SPARSE_WINDOWS: usize = 3;
 
+/// Sparse VRAM windows of the 16-window layout (4 × 4 GiB = 16 GiB VA): one more, taken from the
+/// windows it leaves empty (4 sparse + 1 coherent + 6 view windows of 16), so it costs no address
+/// space. A retail title's BVH builder works in a 3.5 GB `MEM_RESERVE | MEM_64K_PAGES` reservation
+/// made once windows 1..2 are taken: with 3 it found no room and became plain write-watched
+/// memory, which shaders read as zeros (every acceleration structure stayed empty).
+const SIXTEEN_WINDOW_SPARSE_WINDOWS: usize = 4;
+
+/// The sparse VRAM windows of a runtime layout of `windows` windows: `XCL_SPARSE_WINDOWS=<n>`
+/// (1..=8), else 4 with 16 windows and 3 below.
+fn runtime_sparse_windows(windows: usize) -> usize {
+    sparse_windows_setting(std::env::var("XCL_SPARSE_WINDOWS").ok().as_deref(), windows)
+}
+
+/// `runtime_sparse_windows` for the value `v` of `XCL_SPARSE_WINDOWS` (unset or not a number: the
+/// layout's default).
+fn sparse_windows_setting(v: Option<&str>, windows: usize) -> usize {
+    let default = if windows == MAX_HEAP_WINDOWS { SIXTEEN_WINDOW_SPARSE_WINDOWS } else { MAX_RUNTIME_SPARSE_WINDOWS };
+    v.and_then(|v| v.trim().parse::<usize>().ok()).map_or(default, |n| n.clamp(1, 8))

XCL_SPARSE_WINDOWS is clamped to 1..=8, so 7 or 8 sparse windows give the title 27.5+ GiB of sparse space, and its 24 GiB MEM_64K_PAGES CPU view then lands in sparse VRAM. With XCL_UMA_WINDOWS=16 (or 8) and XCL_SPARSE_WINDOWS=7, kernelx::VirtualAlloc sends the retail title's 24 GiB CPU-view reservation to sparse_reserve, which now finds room, so 24 GiB becomes tiled video memory, which the view windows were built to prevent (see the sparse_end doc). The upper bound has to depend on the layout (below 6 for 16 windows, similar for 8). Values outside it are clamped or ignored with no log line.

<!-- greyfinch-sync:ivall/xcl:review-comment:4768348162 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#discussion_r4768348162). Originally posted by [bmjask](https://github.com/bmjask) on 2026-12-02T10:46:55Z. **Code review location:** `crates/xcl/src/gpu/uma.rs`; line 60 ~~~~diff @@ -34,12 +34,32 @@ pub const MAX_WINDOWS: usize = 4; /// Maximum number of windows addressable through the shared descriptor heap (`XCL_HEAP_WINDOWS=1`). pub const MAX_HEAP_WINDOWS: usize = 16; -/// Maximum sparse VRAM windows reserved in runtime layouts (3 × 4 GiB = 12 GiB VA). +/// Maximum sparse VRAM windows reserved in the 4- and 8-window runtime layouts (3 × 4 GiB = 12 GiB VA). /// Keeping sparse VA capped at 12 GiB prevents huge startup `MEM_64K_PAGES` title heaps from /// being pulled into sparse VRAM (which causes multi-minute tile-mapping stalls and multi-GB /// sparse pool bloat), while still giving expanded 8/16-window layouts extra coherent windows. const MAX_RUNTIME_SPARSE_WINDOWS: usize = 3; +/// Sparse VRAM windows of the 16-window layout (4 × 4 GiB = 16 GiB VA): one more, taken from the +/// windows it leaves empty (4 sparse + 1 coherent + 6 view windows of 16), so it costs no address +/// space. A retail title's BVH builder works in a 3.5 GB `MEM_RESERVE | MEM_64K_PAGES` reservation +/// made once windows 1..2 are taken: with 3 it found no room and became plain write-watched +/// memory, which shaders read as zeros (every acceleration structure stayed empty). +const SIXTEEN_WINDOW_SPARSE_WINDOWS: usize = 4; + +/// The sparse VRAM windows of a runtime layout of `windows` windows: `XCL_SPARSE_WINDOWS=<n>` +/// (1..=8), else 4 with 16 windows and 3 below. +fn runtime_sparse_windows(windows: usize) -> usize { + sparse_windows_setting(std::env::var("XCL_SPARSE_WINDOWS").ok().as_deref(), windows) +} + +/// `runtime_sparse_windows` for the value `v` of `XCL_SPARSE_WINDOWS` (unset or not a number: the +/// layout's default). +fn sparse_windows_setting(v: Option<&str>, windows: usize) -> usize { + let default = if windows == MAX_HEAP_WINDOWS { SIXTEEN_WINDOW_SPARSE_WINDOWS } else { MAX_RUNTIME_SPARSE_WINDOWS }; + v.and_then(|v| v.trim().parse::<usize>().ok()).map_or(default, |n| n.clamp(1, 8)) ~~~~ --- `XCL_SPARSE_WINDOWS` is clamped to 1..=8, so 7 or 8 sparse windows give the title 27.5+ GiB of sparse space, and its 24 GiB MEM_64K_PAGES CPU view then lands in sparse VRAM. With XCL_UMA_WINDOWS=16 (or 8) and XCL_SPARSE_WINDOWS=7, `kernelx::VirtualAlloc` sends the retail title's 24 GiB CPU-view reservation to `sparse_reserve`, which now finds room, so 24 GiB becomes tiled video memory, which the view windows were built to prevent (see the `sparse_end` doc). The upper bound has to depend on the layout (below 6 for 16 windows, similar for 8). Values outside it are clamped or ignored with no log line.
bmjask commented 2026-12-02 10:46:55 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by bmjask on 2026-12-02T10:46:55Z.

Code review location: crates/xcl/src/gpu/uma.rs; line 86

@@ -52,11 +72,16 @@ fn view_windows(windows: usize) -> usize {
 }
 
 /// Maximum number of committed coherent windows in an expanded runtime layout.
-/// Always leaves 3 sparse VRAM windows (12 GiB) and the view windows: 1 coherent for 4-window,
-/// 5 for 8-window, 7 for 16-window.
+/// Always leaves the sparse VRAM windows (`runtime_sparse_windows`) and the view windows:
+/// 1 coherent for 4-window, 5 for 8-window, 6 for 16-window.
 fn max_coherent_windows(windows: usize) -> usize {
+    max_coherent_windows_for(windows, runtime_sparse_windows(windows))
+}
+
+/// `max_coherent_windows` with `sparse` sparse windows.
+fn max_coherent_windows_for(windows: usize, sparse: usize) -> usize {
     if windows > MAX_WINDOWS {
-        windows.saturating_sub(MAX_RUNTIME_SPARSE_WINDOWS + view_windows(windows)).max(1)
+        windows.saturating_sub(sparse + view_windows(windows)).max(1)
     } else {
         1

Not certain about this one: the 16-window coherent cap drops from 7 to 6 windows, so stored coherent needs between ~24 and ~28 GB are now cut down. A title whose coherent_file holds a ~26 GB need (with enough commit) used to get 7 coherent windows. Now coherent_window_sizes stops at 6 x 4095 MB, and the GPU heaps past that leave the coherent window. note_coherent_need / settle_coherent_need also report the smaller cap.

<!-- greyfinch-sync:ivall/xcl:review-comment:4768348172 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#discussion_r4768348172). Originally posted by [bmjask](https://github.com/bmjask) on 2026-12-02T10:46:55Z. **Code review location:** `crates/xcl/src/gpu/uma.rs`; line 86 ~~~~diff @@ -52,11 +72,16 @@ fn view_windows(windows: usize) -> usize { } /// Maximum number of committed coherent windows in an expanded runtime layout. -/// Always leaves 3 sparse VRAM windows (12 GiB) and the view windows: 1 coherent for 4-window, -/// 5 for 8-window, 7 for 16-window. +/// Always leaves the sparse VRAM windows (`runtime_sparse_windows`) and the view windows: +/// 1 coherent for 4-window, 5 for 8-window, 6 for 16-window. fn max_coherent_windows(windows: usize) -> usize { + max_coherent_windows_for(windows, runtime_sparse_windows(windows)) +} + +/// `max_coherent_windows` with `sparse` sparse windows. +fn max_coherent_windows_for(windows: usize, sparse: usize) -> usize { if windows > MAX_WINDOWS { - windows.saturating_sub(MAX_RUNTIME_SPARSE_WINDOWS + view_windows(windows)).max(1) + windows.saturating_sub(sparse + view_windows(windows)).max(1) } else { 1 ~~~~ --- Not certain about this one: the 16-window coherent cap drops from 7 to 6 windows, so stored coherent needs between ~24 and ~28 GB are now cut down. A title whose `coherent_file` holds a ~26 GB need (with enough commit) used to get 7 coherent windows. Now `coherent_window_sizes` stops at 6 x 4095 MB, and the GPU heaps past that leave the coherent window. `note_coherent_need` / `settle_coherent_need` also report the smaller cap.
bmjask commented 2026-12-02 10:46:55 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by bmjask on 2026-12-02T10:46:55Z.

Review: COMMENTED


Review of 0b4283d1: 3 finding(s). 3 are inline.


These findings come from an AI-assisted review (Claude Code) and focus on correctness. Each is a candidate; please check it before acting on it.

<!-- greyfinch-sync:ivall/xcl:review:6149278584 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#pullrequestreview-6149278584). Originally posted by [bmjask](https://github.com/bmjask) on 2026-12-02T10:46:55Z. **Review:** COMMENTED --- Review of `0b4283d1`: 3 finding(s). 3 are inline. --- _These findings come from an AI-assisted review (Claude Code) and focus on correctness. Each is a candidate; please check it before acting on it._
Pipodi commented 2026-12-02 11:23:37 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Pipodi on 2026-12-02T11:23:37Z.


merge-check
base: 1c8b551475
head: 0b4283d147
merge: clean
build: cargo build --workspace -> ok (and cargo build --release -p xcl -> ok)
tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 2912 passed, 0 failed, 51 ignored; SKIPPED: 25 (22 no wave64, 2 no heap windows, 1 cannot disable the driver cache); failing: none. Fail-without: on the merge with XCL_SPARSE_WINDOWS=3 (main's 3-window layout), cargo test -p xcl --lib gpu::uma::tests -> 15 passed, 7 failed, including the new sixteen_windows_keep_four_sparse_windows and a_bvh_scratch_reservation_lands_in_the_fourth_sparse_window.
review: read the whole diff (uma.rs, recomp/tests.rs, console_heap.rs, README). (1) Confirmed, and it is what the two checks weigh differently: with XCL_UMA_WINDOWS=16 the coherent window moves from 3 to 4, and the switch form that with_switch_fallback (real.rs ~5178) builds when the driver refuses a heap-window pipeline reaches only windows 0..3 (pso::windows_for_mode), so such a pipeline reads title coherent memory, per-draw args and readback buffers as 0. thehollowedone's test-only regression on this merge (added, then removed; not in the counts above): default -> 0 passed, 1 failed ("the switch fallback translates 4 windows but coherent memory starts in window 4"); XCL_SPARSE_WINDOWS=3 -> 1 passed. In the runs below and in earlier 16-window runs here the fallback never fired (0 "building it in the switch form" lines on the RTX 4090), so it bites only where the driver returns E_OUTOFMEMORY, but then silently. Both earlier checks agree nothing changes by default; the PR exists for the 16-window layout, and there it opens this gap, which its tests skip (gpu_sparse_vram_descriptors_buffers_and_xmem skips with a configuration reason). (2) The 4th window takes more than the BVH scratch: with 16 windows the title's 99776-page (6236 MiB) physical-page block now fits the sparse windows, so its homes go there instead of plain memory (the run with XCL_SPARSE_WINDOWS=3 logs "AllocateTitlePhysicalPages(99776): no room in unified memory – their home is plain memory"; the default 16-window run does not). Every home committed there also takes a video-memory tile. (3) The layout tests read XCL_SPARSE_WINDOWS from the environment: a suite run with XCL_SPARSE_WINDOWS=3, as recomp/tests.rs suggests for that GPU test, fails 7 uma.rs tests (measured above). (4) README "1 to 8": with 4 windows values above 3 change nothing.
performance: default 4-window layout unchanged (measured: smoke pair below). Opt-in 16-window layout costs memory: 60 s smoke runs of this merge on the retail title with XCL_DIRECT_DXIL=1 XCL_HEAP_WINDOWS=1 XCL_UMA_WINDOWS=16 XCL_UMA_SHADOW=1 XCL_COHERENT_HEAPS=sparse:16: default (4 sparse) vs XCL_SPARSE_WINDOWS=3, at 60 s sparse CPU copy 6722 vs 6085 MB and sparse tiles (video) 6768 vs 6131 MB (+637 MB each); peak commit 25104 vs 27072 MB and frames 1522 vs 1605, both within noise of one run each, no removal or crash. In an earlier local run on the retail title's intro cinematic (older base, same 16-window settings) the same change grew from there to about +4 GB sparse CPU copy and +4 GB video tiles (27 GB of video memory against a 23 GB budget), a 24 % dearer write-watch look, and peak commit reaching our 52 GB kill cap; XCL_SPARSE_WINDOWS=3 avoided it. Not measured on this head past 60 s.
verdict: not yet: (1) with 16 windows the switch-form fallback no longer reaches the coherent window (reproduced with a test, not covered by the PR's tests or description); (2) the 4th window also takes the title's 6.2 GB physical-page homes into video memory, which needs a measurement past the menu or a limit to the BVH scratch case
hardware / tool and model: NVIDIA GeForce RTX 4090 24 GB, driver 621.40; Intel Core i9-13900K, 32 GB; Windows 11 build 26300; rustc 1.100.0, debug (tests) / release (smoke) / Claude Code, Claude Opus 5.5

Regression run (default layout, 60 s, standard presses, gamesave moved aside, one warm-up first)
main:

xcl-smoke v1
commit: 1c8b551475e1e7bfe48f94448492a4c3544a2e0f
gpu: NVIDIA GeForce RTX 4090
title: 21222967
seconds: 60
exit: 0x0
frames shown: 1611 (PresentX 1611)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 19846 MB

this merge (main 1c8b5514 + head 0b4283d1):

xcl-smoke v1
commit: c47e3bdc37a3e6b8dc6fd4d632d0999e0c652062
gpu: NVIDIA GeForce RTX 4090
title: 21222967
seconds: 60
exit: 0x0
frames shown: 1559 (PresentX 1559)
presents per 2 s (last 3): 60 61 60
device removals: 0
crashes: 0
peak commit: 20053 MB

AI-written (Claude Code, Claude Opus 5.5) and posted by Pipodi.

<!-- greyfinch-sync:ivall/xcl:comment:7343857128 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#issuecomment-7343857128). Originally posted by [Pipodi](https://github.com/Pipodi) on 2026-12-02T11:23:37Z. --- merge-check base: 1c8b551475e1e7bfe48f94448492a4c3544a2e0f head: 0b4283d147b7bd5f93a9cc3d83433cdcdef9762f merge: clean build: cargo build --workspace -> ok (and `cargo build --release -p xcl` -> ok) tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 2912 passed, 0 failed, 51 ignored; SKIPPED: 25 (22 no wave64, 2 no heap windows, 1 cannot disable the driver cache); failing: none. Fail-without: on the merge with `XCL_SPARSE_WINDOWS=3` (main's 3-window layout), `cargo test -p xcl --lib gpu::uma::tests` -> 15 passed, 7 failed, including the new `sixteen_windows_keep_four_sparse_windows` and `a_bvh_scratch_reservation_lands_in_the_fourth_sparse_window`. review: read the whole diff (uma.rs, recomp/tests.rs, console_heap.rs, README). (1) Confirmed, and it is what the two checks weigh differently: with `XCL_UMA_WINDOWS=16` the coherent window moves from 3 to 4, and the switch form that `with_switch_fallback` (real.rs ~5178) builds when the driver refuses a heap-window pipeline reaches only windows 0..3 (`pso::windows_for_mode`), so such a pipeline reads title coherent memory, per-draw args and readback buffers as 0. thehollowedone's test-only regression on this merge (added, then removed; not in the counts above): default -> 0 passed, 1 failed ("the switch fallback translates 4 windows but coherent memory starts in window 4"); `XCL_SPARSE_WINDOWS=3` -> 1 passed. In the runs below and in earlier 16-window runs here the fallback never fired (0 "building it in the switch form" lines on the RTX 4090), so it bites only where the driver returns E_OUTOFMEMORY, but then silently. Both earlier checks agree nothing changes by default; the PR exists for the 16-window layout, and there it opens this gap, which its tests skip (`gpu_sparse_vram_descriptors_buffers_and_xmem` skips with a configuration reason). (2) The 4th window takes more than the BVH scratch: with 16 windows the title's 99776-page (6236 MiB) physical-page block now fits the sparse windows, so its homes go there instead of plain memory (the run with `XCL_SPARSE_WINDOWS=3` logs "AllocateTitlePhysicalPages(99776): no room in unified memory – their home is plain memory"; the default 16-window run does not). Every home committed there also takes a video-memory tile. (3) The layout tests read `XCL_SPARSE_WINDOWS` from the environment: a suite run with `XCL_SPARSE_WINDOWS=3`, as recomp/tests.rs suggests for that GPU test, fails 7 uma.rs tests (measured above). (4) README "1 to 8": with 4 windows values above 3 change nothing. performance: default 4-window layout unchanged (measured: smoke pair below). Opt-in 16-window layout costs memory: 60 s smoke runs of this merge on the retail title with `XCL_DIRECT_DXIL=1 XCL_HEAP_WINDOWS=1 XCL_UMA_WINDOWS=16 XCL_UMA_SHADOW=1 XCL_COHERENT_HEAPS=sparse:16`: default (4 sparse) vs `XCL_SPARSE_WINDOWS=3`, at 60 s sparse CPU copy 6722 vs 6085 MB and sparse tiles (video) 6768 vs 6131 MB (+637 MB each); peak commit 25104 vs 27072 MB and frames 1522 vs 1605, both within noise of one run each, no removal or crash. In an earlier local run on the retail title's intro cinematic (older base, same 16-window settings) the same change grew from there to about +4 GB sparse CPU copy and +4 GB video tiles (27 GB of video memory against a 23 GB budget), a 24 % dearer write-watch look, and peak commit reaching our 52 GB kill cap; `XCL_SPARSE_WINDOWS=3` avoided it. Not measured on this head past 60 s. verdict: not yet: (1) with 16 windows the switch-form fallback no longer reaches the coherent window (reproduced with a test, not covered by the PR's tests or description); (2) the 4th window also takes the title's 6.2 GB physical-page homes into video memory, which needs a measurement past the menu or a limit to the BVH scratch case hardware / tool and model: NVIDIA GeForce RTX 4090 24 GB, driver 621.40; Intel Core i9-13900K, 32 GB; Windows 11 build 26300; rustc 1.100.0, debug (tests) / release (smoke) / Claude Code, Claude Opus 5.5 **Regression run** (default layout, 60 s, standard presses, gamesave moved aside, one warm-up first) main: ``` xcl-smoke v1 commit: 1c8b551475e1e7bfe48f94448492a4c3544a2e0f gpu: NVIDIA GeForce RTX 4090 title: 21222967 seconds: 60 exit: 0x0 frames shown: 1611 (PresentX 1611) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 19846 MB ``` this merge (main 1c8b5514 + head 0b4283d1): ``` xcl-smoke v1 commit: c47e3bdc37a3e6b8dc6fd4d632d0999e0c652062 gpu: NVIDIA GeForce RTX 4090 title: 21222967 seconds: 60 exit: 0x0 frames shown: 1559 (PresentX 1559) presents per 2 s (last 3): 60 61 60 device removals: 0 crashes: 0 peak commit: 20053 MB ``` AI-written (Claude Code, Claude Opus 5.5) and posted by Pipodi.
bmjask commented 2026-12-02 14:12:09 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by bmjask on 2026-12-02T14:12:09Z.


@Prime1997 could you take a look at this one for review and merge? My automated review notes are above, if any.

<!-- greyfinch-sync:ivall/xcl:comment:7348154776 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/3517#issuecomment-7348154776). Originally posted by [bmjask](https://github.com/bmjask) on 2026-12-02T14:12:09Z. --- @Prime1997 could you take a look at this one for review and merge? My automated review notes are above, if any.
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/3517:upstream-pr/3517'
git switch 'upstream-pr/3517'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/3517'
git switch 'upstream-pr/3517'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/3517'
git switch 'upstream-pr/3517'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/3517'
git switch 'main'
git merge --squash 'upstream-pr/3517'
git switch 'main'
git merge --ff-only 'upstream-pr/3517'
git switch 'main'
git merge 'upstream-pr/3517'
git push origin 'main'
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
xcl-dev/xcl!3517
No description provided.