List: title copies name a held host copy's levels, and are fitted to the host's textures #3062

Closed
github-bot wants to merge 2 commits from github-bot/gh-3062 into main AGit
Owner

@⁠Adriwin06 on GitHub · 2026-11-29 19:52 UTC · original
Adriwin06:held-copies → main · +457 −4 · 2 files · 2 commits · closed without merging

What it changes

A host copy made of only the levels a placed texture's views show
(resource::held_only, on by default on cards over 8 GB) begins at the
title's level base, but copy_texture_region, its read backs and
copy_resource handed the title's subresource index to the host as it
was, so a copy from the title's level 0 read the host copy's first
level, which is a smaller one, with the title's box.

held_sub maps the title's index to the host copy's. A copy naming a
level the host copy lacks first asks for one with every level
(want_level, as the placed twins' copies do), and is left out with a
warning only if the host copy is kept (one the host wrote). Whole copies
ask the same of both sides and are left out if they still begin at
other levels. The placed twins and bakes still read the title's indices.

Every region copy (and read back, and copy into a placed twin) is also
fitted to the host's subresources before it is recorded (fit_copy: the
source box cut to the source, the copy to the destination's room from
its corner, blocks counted for block-compressed formats). A copy that is
cut or left out is logged with both textures as the title and the host
have them, instead of recording a CopyTextureRegion the debug layer
calls invalid (which leaves the list unclosable with E_INVALIDARG).
Whole copies between host textures of two shapes are left out the
same way.

Tests: resource::a_copy_names_the_levels_a_held_copy_has, list::fit_tests.

How it was tested

  • GPU and profile: RTX 4070 SUPER, Ryzen 7 5800X. Not measured in the title on these commits by themselves: they come from a fork of mine that carries them with the rest of this set, and the title ran there. What is below is the unit tests on this branch.
  • Before: n/a (no in-title measurement on this branch)
  • After: n/a
  • cargo test passed for the crates it touches:
    • this change: yes, cargo test -p victory-gpu --lib -- list:: resource::: 67 passed
  • cargo clippy --workspace --all-targets --locked: no finding that main does not already have (main has 34 of its own, which is why the Clippy step of CI is red on main itself).
  • cargo xtask policy: no new finding (main fails it on crates/victory-loader/src/heap_sites/frame_users.rs).
  • With all eleven of my pull requests merged together: cargo clippy also with --all-features adds no finding, and cargo test --workspace --locked fails only tests main also fails on this machine: the five shader tests that fail on main here too (WARP's SM 6.2 and the validator) (barycentric_tests::first_half_values_render_on_hardware_and_warp, hw_tests::split_lds_wave32_read_after_read_barrier_coalescing_and_parity, intersect_tests::flat_global_stores_and_atomics_fence_uavs_at_group_barriers_across_waves, rect::tests::rectangles_are_drawn_whole, rect::tests::the_rectangle_stage_is_a_geometry_shader) and xtask's repository_passes_policy (frame_users.rs). 2208 passed, including five that fail on main (three BCPack oracle tests, the menu save race, the shader key test).

Checked for overlap

  • I searched the open pull requests for the same issue and for the files this touches. Related:
    None found for held copies or copy fitting (searched "held", "CopyTextureRegion", "fit_copy").

🤖 Generated with Claude Code

**@⁠Adriwin06** on GitHub · 2026-11-29 19:52 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3062) `Adriwin06:held-copies` → `main` · +457 −4 · 2 files · 2 commits · closed without merging ## What it changes A host copy made of only the levels a placed texture's views show (resource::held_only, on by default on cards over 8 GB) begins at the title's level `base`, but copy_texture_region, its read backs and copy_resource handed the title's subresource index to the host as it was, so a copy from the title's level 0 read the host copy's first level, which is a smaller one, with the title's box. held_sub maps the title's index to the host copy's. A copy naming a level the host copy lacks first asks for one with every level (want_level, as the placed twins' copies do), and is left out with a warning only if the host copy is kept (one the host wrote). Whole copies ask the same of both sides and are left out if they still begin at other levels. The placed twins and bakes still read the title's indices. Every region copy (and read back, and copy into a placed twin) is also fitted to the host's subresources before it is recorded (fit_copy: the source box cut to the source, the copy to the destination's room from its corner, blocks counted for block-compressed formats). A copy that is cut or left out is logged with both textures as the title and the host have them, instead of recording a CopyTextureRegion the debug layer calls invalid (which leaves the list unclosable with E_INVALIDARG). Whole copies between host textures of two shapes are left out the same way. Tests: resource::a_copy_names_the_levels_a_held_copy_has, list::fit_tests. ## How it was tested - GPU and profile: RTX 4070 SUPER, Ryzen 7 5800X. Not measured in the title on these commits by themselves: they come from a fork of mine that carries them with the rest of this set, and the title ran there. What is below is the unit tests on this branch. - Before: n/a (no in-title measurement on this branch) - After: n/a - `cargo test` passed for the crates it touches: - this change: yes, `cargo test -p victory-gpu --lib -- list:: resource::`: 67 passed - `cargo clippy --workspace --all-targets --locked`: no finding that main does not already have (main has 34 of its own, which is why the Clippy step of CI is red on main itself). - `cargo xtask policy`: no new finding (main fails it on crates/victory-loader/src/heap_sites/frame_users.rs). - With all eleven of my pull requests merged together: `cargo clippy` also with `--all-features` adds no finding, and `cargo test --workspace --locked` fails only tests main also fails on this machine: the five shader tests that fail on main here too (WARP's SM 6.2 and the validator) (barycentric_tests::first_half_values_render_on_hardware_and_warp, hw_tests::split_lds_wave32_read_after_read_barrier_coalescing_and_parity, intersect_tests::flat_global_stores_and_atomics_fence_uavs_at_group_barriers_across_waves, rect::tests::rectangles_are_drawn_whole, rect::tests::the_rectangle_stage_is_a_geometry_shader) and xtask's repository_passes_policy (frame_users.rs). 2208 passed, including five that fail on main (three BCPack oracle tests, the menu save race, the shader key test). ## Checked for overlap - [x] I searched the open pull requests for the same issue and for the files this touches. Related: None found for held copies or copy fitting (searched "held", "CopyTextureRegion", "fit_copy"). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
A host copy made of only the levels a placed texture's views show
(resource::held_only, on by default on cards over 8 GB) begins at the
title's level `base`, but copy_texture_region, its read backs and
copy_resource handed the title's subresource index to the host as it
was, so a copy from the title's level 0 read the host copy's first
level, which is a smaller one, with the title's box.

held_sub maps the title's index to the host copy's. A copy naming a
level the host copy lacks first asks for one with every level
(want_level, as the placed twins' copies do), and is left out with a
warning only if the host copy is kept (one the host wrote). Whole copies
ask the same of both sides and are left out if they still begin at
other levels. The placed twins and bakes still read the title's indices.

Every region copy (and read back, and copy into a placed twin) is also
fitted to the host's subresources before it is recorded (fit_copy: the
source box cut to the source, the copy to the destination's room from
its corner, blocks counted for block-compressed formats). A copy that is
cut or left out is logged with both textures as the title and the host
have them, instead of recording a CopyTextureRegion the debug layer
calls invalid (which leaves the list unclosable with E_INVALIDARG).
Whole copies between host textures of two shapes are left out the
same way.

Tests: resource::a_copy_names_the_levels_a_held_copy_has, list::fit_tests.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-29 19:53:12 +00:00
@ -1411,0 +1442,4 @@
"a whole texture copy between host textures of two shapes: left out"
);
}
return;
Author
Owner

@⁠Copilot on GitHub · 2026-11-29 19:58 UTC · original

A rejected whole copy still calls host_written and host_write_listed before returning, so an unwritten destination can lose subsequent title-memory uploads and held-copy growth without receiving the copy. The same issue occurs for Fit::Nothing in crates/victory-gpu/src/list.rs:1883. Validate shape compatibility and nonempty regions before destination initialization, tile-write preparation, and write bookkeeping, so omitted copies leave content ownership unchanged.

**@⁠Copilot** on GitHub · 2026-11-29 19:58 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3062#discussion_r4732930714) A rejected whole copy still calls `host_written` and `host_write_listed` before returning, so an unwritten destination can lose subsequent title-memory uploads and held-copy growth without receiving the copy. The same issue occurs for `Fit::Nothing` in `crates/victory-gpu/src/list.rs:1883`. Validate shape compatibility and nonempty regions before destination initialization, tile-write preparation, and write bookkeeping, so omitted copies leave content ownership unchanged.
@ -1494,0 +1685,4 @@
held_sub(l.resource, l.footprint.offset as u32).map(u64::from)
}
};
let (Some(src_at), Some(dst_at)) = (host_at(&src), host_at(&dst)) else {
Author
Owner

@⁠Copilot on GitHub · 2026-11-29 19:58 UTC · original

For a copy within one unwritten texture held from mip 2, source mip 2 maps to host mip 0 before destination mip 0 grows the texture to a full host copy. Both recorded indices then become 0 instead of copying mip 2 to mip 0, and the title-index self-copy check misses this. Finish growth on both sides before calculating either host index.

**@⁠Copilot** on GitHub · 2026-11-29 19:58 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3062#discussion_r4732930738) For a copy within one unwritten texture held from mip 2, source mip 2 maps to host mip 0 before destination mip 0 grows the texture to a full host copy. Both recorded indices then become 0 instead of copying mip 2 to mip 0, and the title-index self-copy check misses this. Finish growth on both sides before calculating either host index.
@ -1780,0 +2049,4 @@
}
let cut_box = match fitted {
Fit::AsAsked => None,
Fit::Cut(b) => Some(D3D12_BOX { left: b[0], top: b[1], front: b[2], right: b[3], bottom: b[4], back: b[5] }),
Author
Owner

@⁠Copilot on GitHub · 2026-11-29 19:58 UTC · original

When a read-back is clipped, the GPU writes only the fitted region, but defer_read_back still passes the original footprint's row width and row count to host::read_backs. The CPU copy then overwrites title memory with unwritten bytes from the pooled buffer. Carry the fitted byte width and row/depth counts through deferred read-back handling while preserving the original host row/slice strides and title destination pitch.

**@⁠Copilot** on GitHub · 2026-11-29 19:58 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3062#discussion_r4732930754) When a read-back is clipped, the GPU writes only the fitted region, but `defer_read_back` still passes the original footprint's row width and row count to `host::read_backs`. The CPU copy then overwrites title memory with unwritten bytes from the pooled buffer. Carry the fitted byte width and row/depth counts through deferred read-back handling while preserving the original host row/slice strides and title destination pitch.
@ -1411,0 +1427,4 @@
// SAFETY: live textures.
let (a, b) = unsafe { (to.GetDesc(), from.GetDesc()) };
if (a.Dimension, a.Width, a.Height, a.DepthOrArraySize, a.MipLevels)
!= (b.Dimension, b.Width, b.Height, b.DepthOrArraySize, b.MipLevels)
Author
Owner

@⁠Copilot on GitHub · 2026-11-29 19:58 UTC · original

Comparing raw width and height rejects valid block-compressed reinterpret copies, such as a 256×256 R32G32B32A32_UINT texture copied to a 1024×1024 BC5_UNORM texture. D3D12 CopyResource supports this, with one uncompressed texel representing one compressed block. Validate dimensions using the supported reinterpret-format pairs and their block sizes rather than requiring raw dimensions to match.

**@⁠Copilot** on GitHub · 2026-11-29 19:58 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3062#discussion_r4732930765) Comparing raw width and height rejects valid block-compressed reinterpret copies, such as a 256×256 `R32G32B32A32_UINT` texture copied to a 1024×1024 `BC5_UNORM` texture. [D3D12 CopyResource supports this](https://learn.microsoft.com/en-us/windows/win32/api/d3d12/nf-d3d12-id3d12graphicscommandlist-copyresource#reinterpret-copy), with one uncompressed texel representing one compressed block. Validate dimensions using the supported reinterpret-format pairs and their block sizes rather than requiring raw dimensions to match.
Author
Owner

@⁠copilot-pull-request-reviewer[bot] on GitHub · 2026-11-29 19:58 UTC · original · reviewed

Critical copy and read-back defects can select the wrong mip, overwrite title memory with unwritten bytes, and incorrectly change destination ownership when copies are omitted.

4 open issues
What changed in this PR

This PR updates the GPU command-list copy paths to account for host textures that retain only selected mip levels, aiming to prevent invalid D3D12 copies from leaving command lists unclosable.

Changes:

  • Maps title subresource indices to retained host levels and requests missing levels when possible.
  • Fits region copies, read-backs, and placed-twin copies to host extents, with warnings for clipped or omitted transfers.
  • Adds tests for held-level mapping and copy-region fitting.
File Description
crates/​victory-gpu/​src/​resource.rs Adds footprint extent access and a held-level mapping regression test.
crates/​victory-gpu/​src/​list.rs Adds subresource remapping, copy fitting, shape checks, diagnostics, and fitting tests.

Review effort: Balanced

**@⁠copilot-pull-request-reviewer[bot]** on GitHub · 2026-11-29 19:58 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3062#pullrequestreview-6104541095) · **reviewed** <!-- ccr-overview-v2 --> ### 🟡 Changes recommended Critical copy and read-back defects can select the wrong mip, overwrite title memory with unwritten bytes, and incorrectly change destination ownership when copies are omitted. <details open> <summary><strong>4 open issues</strong></summary> - <picture><source media="(prefers-color-scheme: dark)" srcset="https://github.githubassets.com/static/images/icons/copilot-code-review/high-v2-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://github.githubassets.com/static/images/icons/copilot-code-review/high-v2-light.svg"><img src="https://github.githubassets.com/static/images/icons/copilot-code-review/high-v2-light.png" alt="High severity" width="62" height="18" align="texttop"></picture> [Validate copies before initializing or marking the destination written](https://git.gtahub.st/github/trustno1-coder--VIctory-NVIDIA/pulls/3062) · New - <picture><source media="(prefers-color-scheme: dark)" srcset="https://github.githubassets.com/static/images/icons/copilot-code-review/high-v2-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://github.githubassets.com/static/images/icons/copilot-code-review/high-v2-light.svg"><img src="https://github.githubassets.com/static/images/icons/copilot-code-review/high-v2-light.png" alt="High severity" width="62" height="18" align="texttop"></picture> [Grow both textures before calculating held-copy mip indices](https://git.gtahub.st/github/trustno1-coder--VIctory-NVIDIA/pulls/3062) · New - <picture><source media="(prefers-color-scheme: dark)" srcset="https://github.githubassets.com/static/images/icons/copilot-code-review/high-v2-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://github.githubassets.com/static/images/icons/copilot-code-review/high-v2-light.svg"><img src="https://github.githubassets.com/static/images/icons/copilot-code-review/high-v2-light.png" alt="High severity" width="62" height="18" align="texttop"></picture> [Use the fitted region size for deferred read-back copies](https://git.gtahub.st/github/trustno1-coder--VIctory-NVIDIA/pulls/3062) · New - <picture><source media="(prefers-color-scheme: dark)" srcset="https://github.githubassets.com/static/images/icons/copilot-code-review/medium-v2-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://github.githubassets.com/static/images/icons/copilot-code-review/medium-v2-light.svg"><img src="https://github.githubassets.com/static/images/icons/copilot-code-review/medium-v2-light.png" alt="Medium severity" width="62" height="18" align="texttop"></picture> [Allow valid block-compressed reinterpret copies](https://git.gtahub.st/github/trustno1-coder--VIctory-NVIDIA/pulls/3062) · New </details> <details> <summary><strong>What changed in this PR</strong></summary> This PR updates the GPU command-list copy paths to account for host textures that retain only selected mip levels, aiming to prevent invalid D3D12 copies from leaving command lists unclosable. **Changes:** - Maps title subresource indices to retained host levels and requests missing levels when possible. - Fits region copies, read-backs, and placed-twin copies to host extents, with warnings for clipped or omitted transfers. - Adds tests for held-level mapping and copy-region fitting. | File | Description | | ---- | ----------- | | `crates/​victory-gpu/​src/​resource.rs` | Adds footprint extent access and a held-level mapping regression test. | | `crates/​victory-gpu/​src/​list.rs` | Adds subresource remapping, copy fitting, shape checks, diagnostics, and fitting tests. | </details> <sub>Review effort: Balanced</sub>
Author
Owner

@⁠dyshay on GitHub · 2026-11-29 20:46 UTC · original

Merged into our fork's integration branch for testing (dyshay/VIctory-NVIDIA, branch janus-prs). I read the full diff first: no network access, process spawning, binaries, build or dependency changes, or game data. It builds with --profile diag --features diagnostics, and the CPU tests of the touched crates pass. A run on an RTX 4090 is queued (Series S with ray tracing, DLSS Quality). Frame times will follow here.

**@⁠dyshay** on GitHub · 2026-11-29 20:46 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3062#issuecomment-7262353272) Merged into our fork's integration branch for testing ([dyshay/VIctory-NVIDIA](https://github.com/dyshay/VIctory-NVIDIA/tree/janus-prs), branch `janus-prs`). I read the full diff first: no network access, process spawning, binaries, build or dependency changes, or game data. It builds with `--profile diag --features diagnostics`, and the CPU tests of the touched crates pass. A run on an RTX 4090 is queued (Series S with ray tracing, DLSS Quality). Frame times will follow here.
Four things the review of the held copies found:

- A whole copy between host textures of two shapes, and a region copy
  with nothing of it in both (Fit::Nothing), were left out only after the
  destination was marked host-written (host_written, host_write_listed)
  and uploaded into: an unwritten destination lost its title-memory
  uploads without getting the copy. Both checks now come first.
- Within one texture held from level 2, a copy of its level 2 into its
  level 0 took the source's host index (0) before the destination grew
  the texture to hold every level, so both became 0. Both sides now grow
  before either index is taken.
- A read back cut to what the host has wrote only the cut region at the
  buffer's start, but the deferred copy took the footprint's full rows,
  putting the pooled buffer's unwritten bytes over title memory. It now
  takes the region's rows and bytes (read_back_rows; a volume cut in
  each slice's height is left out).
- The whole copy compared raw widths and heights, refusing reinterpret
  copies such as 256x256 R32G32B32A32_UINT and 1024x1024 BC5_UNORM. It
  now compares sizes in blocks of the same bytes (whole_copy_fits).

Tests: fit_tests::a_cut_read_back_returns_only_what_the_copy_wrote,
fit_tests::a_whole_copy_compares_sizes_in_blocks.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Author
Owner

@⁠Adriwin06 on GitHub · 2026-11-30 01:10 UTC · original

Fixed in 1e02966d: the whole copy's shape check now runs before the source upload, the twins, card_writes, host_written and host_write_listed. For region copies, the fit (Fit::Nothing) is decided before the destination is uploaded into or marked, so a copy left out leaves ownership unchanged.

**@⁠Adriwin06** on GitHub · 2026-11-30 01:10 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3062#discussion_r4734087759) Fixed in 1e02966d: the whole copy's shape check now runs before the source upload, the twins, `card_writes`, `host_written` and `host_write_listed`. For region copies, the fit (`Fit::Nothing`) is decided before the destination is uploaded into or marked, so a copy left out leaves ownership unchanged.
@ -1494,0 +1742,4 @@
held_sub(l.resource, l.footprint.offset as u32).map(u64::from)
}
};
let (Some(src_at), Some(dst_at)) = (host_at(&src), host_at(&dst)) else {
Author
Owner

@⁠Adriwin06 on GitHub · 2026-11-30 01:10 UTC · original

Fixed in 1e02966d: both locations grow before either host index is taken. Any side naming a level below its held base calls want_level(.., 0) first, so a copy of mip 2 into mip 0 within one held texture is recorded as 2 into 0.

**@⁠Adriwin06** on GitHub · 2026-11-30 01:10 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3062#discussion_r4734087867) Fixed in 1e02966d: both locations grow before either host index is taken. Any side naming a level below its held base calls `want_level(.., 0)` first, so a copy of mip 2 into mip 0 within one held texture is recorded as 2 into 0.
@ -1780,0 +2108,4 @@
}
let cut_box = match fitted {
Fit::AsAsked => None,
Fit::Cut(b) => Some(D3D12_BOX { left: b[0], top: b[1], front: b[2], right: b[3], bottom: b[4], back: b[5] }),
Author
Owner

@⁠Adriwin06 on GitHub · 2026-11-30 01:10 UTC · original

Fixed in 1e02966d: the deferred read back now gets the rows and bytes of the region actually written, at the buffer's start. That is the fitted cut, or the title's own box when there is one (read_back_rows). Host row pitch and title pitch are unchanged. A volume cut within each slice's height is refused before recording. Regression test: fit_tests::a_cut_read_back_returns_only_what_the_copy_wrote.

**@⁠Adriwin06** on GitHub · 2026-11-30 01:10 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3062#discussion_r4734088007) Fixed in 1e02966d: the deferred read back now gets the rows and bytes of the region actually written, at the buffer's start. That is the fitted cut, or the title's own box when there is one (`read_back_rows`). Host row pitch and title pitch are unchanged. A volume cut within each slice's height is refused before recording. Regression test: `fit_tests::a_cut_read_back_returns_only_what_the_copy_wrote`.
Author
Owner

@⁠Adriwin06 on GitHub · 2026-11-30 01:10 UTC · original

Fixed in 1e02966d: whole_copy_fits compares dimension, slices and levels, then the size in blocks of the same bytes, so 256x256 R32G32B32A32_UINT and 1024x1024 BC5_UNORM match. Formats whose blocks are unknown fall back to raw sizes. Regression test: fit_tests::a_whole_copy_compares_sizes_in_blocks.

**@⁠Adriwin06** on GitHub · 2026-11-30 01:10 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3062#discussion_r4734088148) Fixed in 1e02966d: `whole_copy_fits` compares dimension, slices and levels, then the size in blocks of the same bytes, so 256x256 `R32G32B32A32_UINT` and 1024x1024 `BC5_UNORM` match. Formats whose blocks are unknown fall back to raw sizes. Regression test: `fit_tests::a_whole_copy_compares_sizes_in_blocks`.
Author
Owner

@⁠tyr0nsur on GitHub · 2026-11-30 09:03 UTC · original

I tested the read-back follow-up at 1e02966 on an RTX 4060 and found two cases that still fail. The test uploads distinct rows to a 256×256 R32_FLOAT texture and reads it back into a wider and taller footprint with a 1,280-byte GPU pitch and a 1,536-byte title pitch.

  • A null source box copies the whole source. Since it fits, Fit::AsAsked leaves the effective region unset and the CPU copies the unwritten tail of the wider destination footprint into title memory.
  • With an explicit 192×3 region, the GPU writes 768 bytes per row. The deferred CPU copy uses that width to recalculate the GPU pitch as 768 instead of 1,280. The first row lands correctly and subsequent rows come from the wrong offsets.

Follow-up commit cb3f59d carries the actual GPU pitch and uses the source extent when there is no box. The regression verifies each copied row and the sentinel bytes outside the region. Both cases fail on the PR head with only the test added and pass with the patch.

The targeted Windows suite passed 74 tests (one ignored). With the existing diagnostics build repair from 41adb551 applied locally, 95 passed (two ignored), and the new regression also passed on WARP. The staged asset-policy check passed. Review assisted by Claude Opus 5.5.

**@⁠tyr0nsur** on GitHub · 2026-11-30 09:03 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3062#issuecomment-7273692176) I tested the read-back follow-up at 1e02966 on an RTX 4060 and found two cases that still fail. The test uploads distinct rows to a 256×256 R32_FLOAT texture and reads it back into a wider and taller footprint with a 1,280-byte GPU pitch and a 1,536-byte title pitch. - A null source box copies the whole source. Since it fits, `Fit::AsAsked` leaves the effective region unset and the CPU copies the unwritten tail of the wider destination footprint into title memory. - With an explicit 192×3 region, the GPU writes 768 bytes per row. The deferred CPU copy uses that width to recalculate the GPU pitch as 768 instead of 1,280. The first row lands correctly and subsequent rows come from the wrong offsets. [Follow-up commit `cb3f59d`](https://github.com/tyr0nsur/VIctory-NVIDIA/commit/cb3f59df00f4733cfe8e884e08d73e1775fb32a4) carries the actual GPU pitch and uses the source extent when there is no box. The regression verifies each copied row and the sentinel bytes outside the region. Both cases fail on the PR head with only the test added and pass with the patch. The targeted Windows suite passed 74 tests (one ignored). With the existing diagnostics build repair from `41adb551` applied locally, 95 passed (two ignored), and the new regression also passed on WARP. The staged asset-policy check passed. Review assisted by Claude Opus 5.5.
github-bot closed this pull request 2026-12-01 18:59:17 +00:00

Pull request closed

This discussion has been locked. Commenting is limited to contributors.
No reviewers
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.

Dependencies

No dependencies set

Reference
github/trustno1-coder--VIctory-NVIDIA!3062
No description provided.