Repository navigation
D3D12.X: a 3-D texture XG cannot size is taken at its texels' bytes - #2753
Conversation
xg::Texture::volume refuses 3-D render targets (flags 1 / 2: E_NOTIMPL), so CreatePlacedResourceX had no console size for them and vram gave such a texture every tile of the PC texture as a 64 KiB page at its address. The newer retail title of xcl-dev#505 places thirteen 33x33x33 RGBA16F colour LUTs (flags 0x5) 512 KiB apart. The PC texture has 18 tiles, so each LUT shared 10 pages with the next one. A LUT's bake overwrote its neighbour's rows and the tone map sampled the wrong LUT (black -> cyan): the picture was teal. On our lab branch the same change turned the picture into the game's colours. The fallback is the bytes of the texels of every level (287,496 bytes, 5 pages of its own, for that LUT) and not a console layout. What the console's library does with a 3-D render target is not known: the xg oracle covers 3-D flags 0 and 4 only, and no console library was at hand. The 2-D render target rule (64KB_R_X, thin for 3-D) gives 2.06 MiB, which cannot be right for textures packed 512 KiB apart and keeps the overlap. 4KB_S thick (500 KiB) fits but is a guess. Teaching XG would also change what XGCreateTextureComputer and GetResourceAllocationInfo tell titles. No layout is smaller than its texels, so the pages taken are always the texture's own. Part of xcl-dev#505. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Independent Ampere validation of the NVIDIA-branch precursor b59d263 RTX 3090 Ti 24 GiB, driver 621.40, Windows 10, 32 GiB RAM. Both release builds use
The direction of the color change is consistent with correcting cyan sampled from the wrong LUT. The frames are from different points in the opening and this is one run per arm. The control also recorded 153 two-pass mesh allocation refusals at the same 4 GiB cap, while the treatment recorded zero. No claim about a matched-frame color error, correct geometry, sustained rendering or device-removal prevention. The exact #2753 head has not been run here. Memory details are in the existing #2688 report. AI use: Codex (GPT-6) built and ran the pair, reviewed the backbuffer samples and wrote this report. |
|
Independent AMD RDNA4 (native wave64) verification of exact PR head Tested
(Compare against Not tested
AI use
|
|
Independent RTX 4060 (8 GB) / Windows 11 release verification of PR #2753 at Setup
Targeted RTX 4060 release unit tests (
|
|
I compared stock On stock, adjacent placements shared 10 backing pages. I stopped that case before issuing texture commands, so I have no readback result for the overlapping pair. With the placements farther apart, stock shared zero pages and both textures read back correctly. On the PR head, both placement cases shared zero pages. After waiting for GPU completion, I read back every component of every texel: I used Codex GPT-6 Sol Daybreak for the WARP fixture and GPT-6.2 Sol for physical GPU verification and independent review. Codex GPT-6.2 Astra wrote this comment. I reviewed and approved this comment before posting. |
|
Windows / NVIDIA results for Regression run (default settings, 600 s)
This PR,
Tested
Not tested: #505's title; a frame of the world (no run gets that far); AMD / wave64. AI use: Claude Code (Claude Opus 5.5) built the commit, ran the suite and the runs on my machine, read the logs and wrote this. |
|
On Linux + NVIDIA (RTX 4060 Ti 16 GB), this PR took away the large white shapes over the title's opening scenes that we reported on #505 (7199770263): with it, 0 of 25 frames dumped after the world load were over 20 % near-white (2 of 2 runs); without it, 43 of 48 were (5 of 5 runs). Setup: NVIDIA 615.71.09, Wine 11.21 Staging, vkd3d-proton
Not tested: Windows; AMD; this PR on AI use: Claude Code (Claude Opus 5.5) merged the trees, made and read the runs, and wrote this. Posted without review by a person: the account owner was away and reads replies later. Edited: "six runs" corrected to "seven runs" (the table has seven). |
|
Independent native Windows validation of #2753 for #505 Tested
Not tested The exact adjacent 3D render-target pair in a GPU readback, retail world rendering, whole-workspace or parent runs, and net VRAM usage. The footprint query measures tile count. The fallback changes which addresses own those tiles. AI use Codex GPT-6.2 reviewed the diff, wrote the standalone footprint probe, ran the checks and drafted this report. |
|
Tested: Clean Not tested: The adjacent XG-rejected render-target pair on Arc, console-native layout, full workspace suite and retail smoke. AI use: T3 Code / Codex ( |
|
RTX 3090 24 GB, Windows: with this PR the retail title crawls after its story load and then ends in the Setup
Not tested: this PR on its own base ( AI use: Claude Code (Claude Opus 5.5) built the trees, ran the runs and drafted this; checked by me before posting. |
|
Correction to my comment above: a rerun with frame dumps does not reproduce the split, so I no longer think this PR is the cause. With
AI use: Claude Code (Claude Opus 5.5) ran the runs, read the logs and dumps and drafted this; checked by me before posting. |
main has merged nvidia-dev (xcl-dev#3203): its two-pass mesh, sparse and upload paths now submit through real::native_queue_execute / _signal / _wait. Those already carry xcl-dev#867's UnadoptGuard and unwrap_fence; the conflicts and the main-only submit paths were resolved as follows. Taken from main, the stack's version dropped (main does the same): - recomp/dxc.rs (3): xcl-dev#688's private DXC heaps; main's form (3842807) falls back on any failure and never destroys a heap. - device_x.rs (10): xcl-dev#3091 (cherry-pick 511a297); main's 7e24237 keeps interned shader copies for base pipelines. xcl-dev#3091's tests and its real.rs test counter (GRAPHICS_FALLBACK_ATTEMPTS) and README line go; xcl-dev#2753's console_bytes is re-applied on main's file. - bind.rs (16): the stack's only change there was xcl-dev#1803, merged in main. main's file, plus the xcl-dev#2816 feedback-copy UnadoptGuard in poll_two_pass_feedback (ed887d2, from linux/stack-nvidia-dev). - pso.rs: main has daae033 (multidimensional groups take direct DXIL, xcl-dev#3189's change), so the stack-only commit is in main; translate calls take main's translate_compute_rodata / translate_entry_rodata_rt32. - list_x.rs tests: xcl-dev#3090's barrier tests were in twice (cherry-pick and main's merge); the cherry-picked copy goes. - runner.rs device(), xbox.rs Fssm::rodata: added on both sides; one copy. - README.md: the precompile-wrapper paragraph was added on both sides; one copy. Both kept: - build.rs (2): TRANSLATION_GLUE_REVISION "pso-glue-v5-linux-multidimensional- direct" (main's v5 + the stack suffix); translator sources keep xcl-dev#2229's cfg.rs and code_loads.rs, drop dxc.rs as main does. - dxil/kernel.rs (6): TRANSLATOR_VERSION 13 (main 12; the stack's xcl-dev#2229 head output differs, as on linux/stack-nvidia-dev); main's rt32 entry points with xcl-dev#2229's code_loads. - dxil/lower.rs (4), lower_mem.rs (3), lower_window.rs (1), recomp/emit.rs (11), recomp/mod.rs (3), recomp/tests.rs (1), core_tests.rs: main has an earlier copy of xcl-dev#2229 (41f1a85); xcl-dev#2229's head (code_loads, xcl_cload / xcl_gload(hi, a)) is kept over it, as on linux/stack-nvidia-dev; main's loop_ids, IO slots, ps_mask_live_scc and rt32 mask kept beside it, and main's duplicate core_tests copy of the rodata test goes. lower_mem.rs keeps the stack's scratch_ptr insert-before-terminator line. - real.rs (6): the class scan keeps `own` with main's release_through_its_own_vtable; xcl-dev#2477's in-place patch after main's two-pass defer hooks; q_signal_pc / q_wait_pc beside main's page mappings; the title ExecuteCommandLists keeps xcl-dev#867's list guards inside main's watch::in_driver scope; test modules of both. - list_x.rs (1): xcl-dev#867's allocator / PSO guards with main's `on = pc_alloc`. - sparse.rs (1): main's new_state, with xcl-dev#867's raw fences for the sparse and readback fences and the async readback fence pairs (as on linux/stack-nvidia-dev); pc_execute (main's texture_upload submit path) unadopts its list for the submit. - title_textures.rs (1): main's early fence creation, as a raw fence. - dstorage.rs (4): xcl-dev#2864's unpack cache on main's Cow source and stage buffers. - xg.rs (2): main's copy_args (adccb7d) covers xcl-dev#684's argument fix; xcl-dev#684's destination guard kept. - present.rs (1), gpu_compute_e2e.rs (1), README.md (2): tests and text of both. linux/README.md: main line updated; xcl-dev#1599, xcl-dev#2082, xcl-dev#1803, xcl-dev#3090, xcl-dev#688, xcl-dev#3091 and the stack-only multidimensional row leave the table. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
merge-check claim |
|
merge-check |
|
merge-check claim |
|
merge-check |
Keeps upstream's DXIL IR cuts (xcl-dev#3500-xcl-dev#3503/xcl-dev#3495-xcl-dev#3499: sampler waterfall, descriptor windows, split-wave64 mask exchange, per-lane exec, direct PS masks, quad shuffles, packed/normalized buffer decode, commit-aware compiles), xcl-dev#3269 fixed-point optimizer, xcl-dev#3154 compact compute prologue, xcl-dev#2123 split atomic add, xcl-dev#2070 offline 64 MB stacks, xcl-dev#3442 split-whole, xcl-dev#1319 root-constant bounds, xcl-dev#3356 late Reset releases, xcl-dev#1322 empty-BVH/NaN rays, xcl-dev#2753 3-D texture sizing, XMA/VFS/TLS/loader fixes. Resolutions: - real.rs: union of T-156 res_release pinning with upstream's InListReset and abi_rs_for_stages; dropped upstream's warm_graphics (T-095 removed that path); kept ComputeBuild::IndirectChain for our split-chain variant. - dispatch_chain.rs: kept our IndirectBuild split-chain architecture (the T-095 port removed the preload/whole-worker machinery upstream builds on); ported upstream's huge-PSO refusal log. - pso_async.rs: took upstream's commit-aware build_pieces/build_scoped and WORKER_STACK, removed the preload/backlog subsystem our port does not have (and its tests), kept our profile_is_series_s. - late_release.rs: took upstream's Dead enum, Busy/InListReset and hold_pipeline/hold_heap/hold_unmap, with our vram release path (no recycle pool). - emit.rs: upstream's additions moved into emit/memory.rs (ADD_TID_ENABLE), emit/exp.rs (misc-vector layer/viewport), emit/mimg.rs (SampleCmp with bias gradients), emit/valu.rs (abs/neg on shift/align), emit.rs out_struct. - bind.rs: root-constant bounds clamp + its test; kept our bool execute_indirect API. - bvh.rs: our grow/tri_ret/watertight model plus upstream's empty-root bounds and NaN-ray refusal. - kernel.rs: upstream's mask/waterfall/rodata cuts plus our lanes_upper. - shaders.rs: upstream's worker stack helpers and mesh/GS precompile paths, with our PipelineJob record identity. - eh.rs: upstream's CLWB TF guard + test, our termination test. - lower.rs test: 574bda4 makes wave32 SALU words compute S_WQM without quad lanes; assert that and keep the wave64 refusal.
A 3-D texture XG does not lay out (a 3-D render target:
xg::Texture::volumerefuses flags 1 / 2 withE_NOTIMPL) got no console size inCreatePlacedResourceX, sovramgave it every tile of the PC texture as a 64 KiB page at its address. The newer retail title of #505 places thirteen 33x33x33 RGBA16F colour LUTs (render target + UAV, flags 0x5) 512 KiB apart; the PC texture has 18 tiles of 64 KiB, so each LUT shared 10 pages with the next one. A LUT's bake overwrote rows of its neighbour, the tone map sampled another LUT's rows (LUT[black] = cyan) and the whole picture came out teal. Such a texture is now taken at the bytes of its texels (287,496 here: 5 pages of its own), which no console layout of it is smaller than.Part of #505.
Why not the console's layout: what the console's library does with a 3-D render target is not known here. The
xg_oraclevolume test covers flags 0 and 4 only, and no console library was at hand to ask. The 2-D rule for render targets (64KB_R_X, thin for 3-D in our tiling model) would give 33 x 64 KiB = 2.06 MiB, which cannot be right for textures the title packs 512 KiB apart, and it would keep the overlap. 4KB_S thick (500 KiB) fits, but that is a guess. Teaching XG this would also change whatXGCreateTextureComputerandGetResourceAllocationInfotell titles. The texels' bytes are a lower bound of any layout, so the pages taken are always the texture's own.What is in it
D3D12.X: a 3-D texture XG cannot size is taken at its texels' bytes(crates/xcl/src/hle/d3d12x/device_x.rs:console_bytes/volume_texel_bytes, used bycreate_placed_resource_x;vram::owned_pagesmadepub(super)for the test), with the unit testvolume_targets_xg_does_not_lay_out_keep_to_their_texels: two such LUTs 512 KiB apart do not share a page, a full mip chain is summed, and a sampled 3-D texture keeps XG's size.Tested
console_bytesis XG's size only) the new test fails:assertion left == right failed, left: None, right: Some(287496); with it, it passescargo test --release -p xcl --lib -- volume_targets owned_pages hle::xgon e07d03b: 80 passed, 0 failed, 0 ignored, 1257 filtered out (CPU tests; the filter also matcheshle::xgameruntime)stable-x86_64-pc-windows-msvc, release. One07d03b(this PR, onmainb49be18).cargo build --release --workspace && cargo test --release --workspace --no-fail-fast -- --test-threads=4one07d03b: 1432 passed, 4 failed, 47 ignored. The 4 failures aregpu::dxil::fuzz_tests::fuzz_validate_and_gpu_0..3(CreateComputePipelineState: out of memory (0x8007000E)), which fail onmainas well.main): 21 "no wave64", 3 refused by the per-lane form,heap_window_out_of_memory_falls_back_to_the_switch_form(no heap windows),pso_measurement_compiles_an_exact_synthetic_record(needs Developer Mode).Regression run
main:
this PR:
Not tested
xg_xs.dll(XCL_SAMPLE_XG) was at hand.AI use
🤖 Generated with Claude Code