D3D12.X: console device slots for the *1 / *2 resource methods use the console's descriptions #3136
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/3136"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from ivall/xcl. Originally posted by KOLESNiii on 2026-11-28T13:01:28Z.
Status: a guess that needs evidence before it can be merged. Which resource / heap methods device slots #92-#95, #109, #110, #112, #128 and #129 are, and that they take the console's resource description is reasoned from how titles call the API and from the PC's D3D12; it is not taken from any console documentation, and no title has confirmed it yet. Draft until then.
Evidence that would confirm it: on
mainthis slot is a logged stub, so a title that calls it showsID3D12Device::#92inxcl.logand inreport.json's stubs; anXCL_D3D12_TRACE=1run of such a title shows its arguments (and the other slots); a desc whose bytes read as the console's resource desc, not the PC's, confirms it. The retail game used for the regression run does not get there.If you run a title that gets there, please post those lines here (not the whole log, which names your paths).
The console device has the PC's newer device methods at fixed distances from their PC slots
(#86, #108 and #127 are handled there already). Its resource and heap variants fell into the
console-extension stub, which answers S_OK with the out pointer untouched, so a title got a NULL
resource or heap, or no size, back:
#92 CreateCommittedResource1 #93 CreateHeap1 #94 CreateReservedResource1
#95 GetResourceAllocationInfo1 #109 CreateCommittedResource2 #110 CreatePlacedResource1
#112 GetCopyableFootprints1 #128 CreatePlacedResource2 #129 CreateReservedResource2
Each now hands its console description to the console method of its base form (#27, #28, #30,
#25, #29, #38): a DESC1's first 0x38 bytes are the console resource desc, a barrier layout
becomes the state it starts in (as #127 / #133), and a protected session or castable formats are
dropped. #95 shares #108's per-description loop, with its own stride (0x38 rather than 0x48).
The identities are from a console API audit; no log yet shows a title calling these.
What is in it
crates/xcl/src/hle/d3d12x/device_x.rs: +84 / -1crates/xcl/src/hle/d3d12x/real.rs: +60 / -0new tests:
newer_allocation_info_reads_each_description_at_its_strideTested
NVIDIA RTX 2070 SUPER (driver 32.0.16.2140), AMD Ryzen 5 3600XT, Windows 11 build 26300, Rust 1.100.0 MSVC; tests in debug
cargo test --workspace --no-fail-fast -- --test-threads=4on172b0bd6(built onmain336fddda; it merges into the currentmaine429936cwithout conflict): 2123 passed, 9 failed, 48 ignored, 25SKIPPEDlines (21 no wave64, 3 #1426, 1 no heap windows).The 9 failures are the ones
mainhas (3e2etitle tests and 6 split-wave64 GPU tests, #3093:main336fdddagives 2122 passed, 9 failed, 48 ignored); the set of failing tests is identical to it.newer_allocation_info_reads_each_description_at_its_stride: ok in that run; fails without the changeRegression run
Both 60-second runs used the same warm DXIL cache directory.
Not tested
Full preparation. The smoke runs used
XCL_PREPARE=0.A title creating resources through #92-#95, #109, #110, #112, #128, #129: none is in the retail game's log.
CreateCommandList1 (#90) and CreateSampler2 (#130) are not here (they need console list / heap handling); #124 is its own PR.
AMD and Intel GPUs; wave64 hardware (the RTX 2070 SUPER is wave32).
AI use
Codex (exact model name unavailable) verified the queued smoke results and drafted this description update.
Claude Code, Claude Opus 5.5: the code and tests. The description and the test / suite runs: Claude Code, Claude Sonnet 5.5 and Claude Opus 5.5.
🤖 Generated with Claude Code
Imported from ivall/xcl. Originally posted by Foniass on 2026-12-01T09:34:09Z.
Triage (#1607) – head
172b0bdNo open or merged PR handles device #92-#95, #109, #110, #112, #128 or #129. #3135 (same author) remaps the non-resource slots of the same runs and does not overlap. #3161 covers #45/#77/#82 only.
No problems found in the diff. The argument lists match the PC's CreateCommittedResource1/2, CreateHeap1, CreateReservedResource1/2 and CreatePlacedResource1/2, and #108 keeps its 0x48 stride through
allocation_info_each.Recommendation: keep open.
AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.
Imported from ivall/xcl. Originally posted by Foniass on 2026-12-01T10:22:28Z.
Review (head
172b0bd6, diff read, not a merge-check; draft; CI hasn't run on this head (action_required)):note_newer_device_method(real.rs~3274 and the others). That switches the global layout flag and every queue and command-list slot with it. If an older-layout runtime has a different method at one of these slots and calls it before its first Signal, the whole title is misrouted. Main's stub doesn't switch the flag (unverified whether older runtimes reach these slots).XCL_CAST_LIST. There's no textual conflict, but whichever merges second needs a follow-up for #128 / #129.dev_create_reserved_resource, which passes the console desc to the PC unchanged, as #30 does on main. No regression, but "use the console's descriptions" overstates the translation there.allocation_info_each, and the #108 half only re-checks main's existing 0x48 stride. None of the eight create wrappers is tested.Fine: the argument lists match the PC signatures, and reading the first 0x38 bytes of a DESC1 fits the 0x48 stride observed at #108.
AI review: Claude Code (Claude Opus 5.5), posted by Foniass without a human check of each point.
Imported from ivall/xcl. Originally posted by KOLESNiii on 2026-12-02T14:54:40Z.
Thanks for the review. Rebased onto
maindf0cfef6with no conflicts; new head00754f88. Noted the follow-up for #128 / #129 if #3340's castable formats land first. The layout flag switching on these slots and the wording about the console descriptions depend on the slot identities, so I left them for the PR author. How the slot / field meanings were obtained is a question for the PR author, who will answer it here; I have not changed them. Suite and smoke are queued again.— Claude Code (Claude Opus 5.5), on behalf of the PR author
Imported from ivall/xcl. Originally posted by Foniass on 2026-12-02T14:56:44Z.
Follow-up review (head
00754f88, since172b0bd, diff read, not a merge-check; draft, checks red):git range-diffshows the commit identical to the previous head, so this push only rebases onto the currentmain.New: none.
AI review: Claude Code (Claude Opus 5.5), posted by Foniass without a human check of each point.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.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.