Repository navigation
d3d12: the title's startup command signatures are created (argument type 105, DISPATCH_MESH), again (RT-SLOT41) - #377
Conversation
ff9bb14 to
3b86f5f
Compare
|
Holding this, and the PRs stacked on it (#383, #385, #391, #395, #396), on one regression. The Please restore the block, add Two small notes for the PRs above it:
|
…stack Contains ProjectLeonida#375 ProjectLeonida#377 ProjectLeonida#383 ProjectLeonida#385 ProjectLeonida#391 ProjectLeonida#395 ProjectLeonida#396 ProjectLeonida#403 ProjectLeonida#414 ProjectLeonida#416 ProjectLeonida#427 ProjectLeonida#430 ProjectLeonida#432. # Conflicts: # runtime/shims/d3d12_com.cpp # runtime/shims/d3d12_vulkan_device.cpp # runtime/src/command_list.h
…TCH (slot 41) The retail title creates five one-argument command signatures with no root signature at startup (device slot 41, CreateCommandSignature at its PC position). One has the console argument type 105 and a 12-byte stride, next to a DISPATCH and a DISPATCH_MESH of 12 bytes. The PC layer refuses the unknown type, which is stop 19 of the RT-5 boot measurements. Read statically from the title's call sites (shapes only): the two ExecuteIndirect sites of that signature pass MaxCommandCount 1 and an offset into the same argument buffer as the DISPATCH sites. Right before, they set the same compute state as the DISPATCH path (pipeline, compute root signature, tables, constants, SRV and UAV); they record on a second command list of the title's context. So the argument is taken as a D3D12_DISPATCH_ARGUMENTS. Slot 41 now has its own handler. A description that holds type 105 is copied with that type replaced by DISPATCH (logged once). Any other description is forwarded as the same pointer. What the console does differently for type 105 is left open in docs/d3d12_vulkan.md (section 4.9). xs_proxy_mock_test: a two-argument description (a root constant, then type 105) reaches the PC slot 41 as a copy with DISPATCH, the same stride, count, root signature, IID and output, and the caller's description is untouched; a PC description is passed through unchanged. With main's d3d12_xs_device.cpp the new check fails. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit 4c04c0f)
105 is outside D3D12_INDIRECT_ARGUMENT_TYPE's range [0, 15], so clang-cl rejects a constant expression that casts it to the enum (reported by umnitus on #7163). The handler now reads each argument's Type field as a uint32_t through memcpy and compares it with 105; the test writes and reads the raw value the same way, and the mock records it the same way. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit 084c8c6)
…device with mesh shaders The Vulkan layer created signatures for draw, draw-indexed and dispatch only and answered E_NOTIMPL for DISPATCH_MESH, which the PC runtime creates on any mesh-shader tier 1 device. A title that creates such a signature at startup and asserts on the result stopped there. The signature is created when the device has VK_EXT_mesh_shader (MeshShaderTier 1), as a new IndirectKind::dispatch_mesh (the name and value #3777 uses, so the two merge). ExecuteIndirect with it records nothing yet and says so once; #3777 replays it as vkCmdDrawMeshTasksIndirectEXT. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit efc3478)
…H has a record size and returns after it Resolving the cherry-pick of efc3478 I dropped main's record-size, stride and span checks (e1ec785), which d3d12_execute_indirect_validation_test depends on and which matter to every D3D12 user (found in review on ubiquitarianism#377). They are back as on main, the record-size chain knows D3D12_DISPATCH_MESH_ARGUMENTS, and the early return for a DISPATCH_MESH signature comes after the checks. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01HxBQf4pXH8PWpC5oZsM4bt
3b86f5f to
88b8dba
Compare
…riptor range Slot 61 passed the destination handle to the PC CreateSampler as given. With the title's descriptor range honoured (__XMemAllocationHooks__), a handle in that range has to be translated to the real heap's, as device slots 17 to 24 do (asked for in review on ProjectLeonida#377). Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01HxBQf4pXH8PWpC5oZsM4bt
Asked for in review on ProjectLeonida#377. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01HxBQf4pXH8PWpC5oZsM4bt
…ow in the Xbox-only table Asked for in review on ProjectLeonida#377. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01HxBQf4pXH8PWpC5oZsM4bt
|
Fixed, and sorry for that one: resolving the cherry-pick I dropped
Everything from #375 to #432 is rebased on AI-assisted. |
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Merged. Mumogg is still away and this is the next rung on Conflicts: two.
The hold (the owner's comment of 04:51 UTC, answered by Mumogg in
Tests (Linux; clang-cl with the xwin SDK; Wine, headless; llvmpipe and an RDNA2 iGPU):
Notes for later, none blocking:
#383 is the next rung. AI-assisted (Claude Code, Claude Fable 5.2 and Claude Opus 5.5). |
Claimed in #14 as
RT-SLOT41. Depends on: #349, #350, #356, #362, #369, #375 (their commits come first here; this pull request is the last three commits).What and why
After #375 the title creates five one-argument command signatures at startup through device slot 41 (
CreateCommandSignatureat its PC position) and stops when one is refused: its device set-up returns false and it hits its ownint3. Two of the five are refused onmain:4c04c0f4eDISPATCH; slot 41 gets its own handler084c8c60eefc347830DISPATCH_MESHsignature on a device with mesh shaders;ExecuteIndirectwith it records nothing yet and says so onceAll three are cherry-picked with
-xand keep their authors; all are ancestors ofmainwhose content is not in the tree. Conflicts were neighbours only (slot lists, the mock's cases), except one: ind3d12_com.cppthe last commit carried a copy of the argument-range validation thatmainno longer has at that place, so I kept only its early return forDISPATCH_MESH.I applied them one at a time: with the first two alone the run still ends at the same stop, and the third is what lets it go on. So both refusals are real here.
Measured
Linux (Nobara 44, kernel 7.3), Wine 11.21 staging, RTX 5070 Ti (driver 615.78.08), clang-cl 22.1.8 + xwin SDK 10.0.26100, own 1.0.2.1 copy, network off, on
mainece4ba5b3, with #142 and #328 applied on top for the boot runs (they are not in this branch).--runint3after its device set-up returns false; last slot called: 41The count of traced D3D12 calls is 1,655 in both (
CreateCommandSignatureis not one of the traced calls). The log lineslot 41 argument type 105 (stride 12) created as DISPATCHappears once. The next stop is device slot 61, forwarded as it is; on the console that slot writes a sampler to a descriptor handle.xs_proxy_mock_testunder Wine passes, with the slot 41 case (type 105 reaches the PC slot as a copy withDISPATCH).d3d12_mesh_testunder Wine passes on the RTX 5070 Ti (mesh tier 1), with the commit'sDISPATCH_MESHsignature case.Not built with MSVC and not run on Windows.
AI-assisted (Claude Code); built and run on the machine above.
🤖 Generated with Claude Code
https://claude.ai/code/session_01HxBQf4pXH8PWpC5oZsM4bt