Repository navigation
D3D12.X: coordinate view texture creation by cache key - #2812
CryingLaughing wants to merge 2 commits into
Conversation
resource_at makes a placed texture for each new (address, description) of a view the title writes without a resource object (device xcl-dev#70/xcl-dev#71) and keeps it. Its key cleared the padding after the flags but not the padding after Dimension (bytes 4..8). A retail title leaves that set, so the same view made another texture whenever it differed: 24,844 of 80,953 textures in a 200 s run were such twins (GreemSC, xcl-dev#2743). The key now leaves out both. The activity line counts the textures kept. Part of xcl-dev#2743, xcl-dev#2688. Assisted-by: Claude Code (Claude Opus 5.5)
Publish one completed placed texture for each normalized view key. Keep allocation and waits outside the map lock so distinct keys can progress. Preserve completed failed entries and ownership of successful resources.
|
Regression run of Setup: RTX 3060 12 GB (NVIDIA 581.80), i9-14900KF, Windows 11 26200, release builds of main main: this PR: 103 % of main's frames, 104 % of its peak commit. One run each. Not tested: the suite on this head; whether the title reaches the code this PR changes in its first 60 s; AMD. AI use: Claude Code (Claude Opus 5.5) ran these runs on this machine and wrote this report. |
|
RX 9070 / Wine concurrent native Tested Compared exact head, current main RX 9070 16 GB, PCI Source copies received reversible
The native fixture uses small RGBA8 render targets, with a 192 KiB owned synthetic address range. It holds creation for the first address until all eight callers are observed: eight caller references to the pending entry on head, eight factory entrants on main. A different address completes while that first creation remains held. After release, every head caller receives the same pointer; main returns eight distinct pointers. An exact repeat uses a previously returned pointer on all three source variants. Per-process outcomes were identical in every repetition and both placement configurations:
Across 24 harness invocations: 0 ignored, 0 capability skips. The 18 native probes created 102 real resources. Independently checked saved pointer sets, creation counts, joins and native descriptors; each resource's device matched the selected RX 9070 LUID. Default placement mapped one tile per resource; arena mode had no page mappings. Shared page/heap backing means these object counts do not establish VRAM savings. Creation references and synthetic address identities remain valid until process exit, matching the cache's lifetime. Not tested Texture drawing, shader dispatch or pixel readback, native driver failures during concurrent creation, other formats or multiple devices, long-running cache lifetime, whole workspace suite, native Windows, other adapters, retail data, AI use OpenAI Codex (GPT-6; exact serving variant not exposed) audited the diff, wrote local test-only observations/fixture, ran all source variants, independently verified raw logs/source/executable hashes, and drafted this report. Publication authorized by the account owner. |
Stacked on #2762. Part of #2743.
The view-resource cache now shares one pending placement per normalized address and description. Concurrent callers for that key receive the completed resource. Lookups for other keys can proceed during creation.
What is in it
Tested
ab169f5396bda3df5a48497e668f49a99192e892, based on D3D12.X: a view's padding does not make a second texture #2762 head496ef5780a4549fc3f15bc65340deb1db4794d6b. RTX 4080 driver 621.01, i5-13600K, Windows 11 25H2 build 26200.9974, Rust 1.100.0 x64 MSVC, DXC 1.8.2502.11.cargo build --workspace --locked -j 4andcargo test --workspace --locked -j 4 -- --test-threads=4 --show-outputpassed 1,437 passed, 0 failed, 47 ignored across 37 harnesses, including 29 capability skips.Regression run
Independent retail smoke by Anon64 compared release builds of main and this exact head on an RTX 3060 12 GB (driver 581.80), Core i9-14900KF, and Windows 11 build 26200. The 60-second runs used the same title. The head retained 103.0% of the baseline frames and used 104.6% of its peak commit, with zero crashes or device removals. The run did not establish whether the title reached the changed code.
main:
PR:
Not tested