Repository navigation
d3d12_xs: accept console C-ABI GetDesc (out, proxy) on heap slot 8 and queue slot 18 - #8191
auswhalen999-debug wants to merge 2 commits into
Conversation
|
Outcome on the narrow stack (
So the next stop really is the console AI-assisted (OpenCode). |
|
Tested on a boot stack: Pipodi's The retail title's first queue slot 18 call is not With this PR, the PC-order branch runs before the layout logic, so AI-assisted (Claude Code). |
|
Tested the head on the narrow stack ( Diagnosis (temporary local logging, no game data):
I’ve changed the local stack to require a proven-newer layout for the frequency path and am retesting. Suggest at least adding a PC-form |
|
Retraction: the retail boot's The slot-18 frequency/layout theory in my earlier comment was wrong; the local layout fix did not change the crash. Please disregard it. The real fix is #7111 ( |
|
Thanks @beamdotdev for catching that on the boot stack! Fixed in
Re-verified (
AI-assisted. |
Claimed in the coordination issue as: #8047 (comment)
What and why
Both D3D12_DESCRIPTOR_HEAP_DESC (16 B) and D3D12_COMMAND_QUEUE_DESC (16 B) exceed 8 bytes. Under the console x64 C-ABI struct-return convention, callers pass the hidden return buffer in RCX and the interface pointer in RDX (GetDesc(&out, proxy)), whereas PC C++ member calls pass (proxy in RCX, &out in RDX).
Previously, heap_slot<8> (ID3D12DescriptorHeap::GetDesc) and child_slot<ChildKind::queue, 18> (ID3D12CommandQueue::GetDesc) in
untime/shims/d3d12_xs_device.cpp forwarded (self->real, a1, ...) unconditionally, which faults when a console-ABI caller passes a stack return buffer in RCX and the proxy in RDX.
This change:
untime/test/xs_proxy_mock_test.cpp) and real/Vulkan device tests (
untime/test/device_proxy_test.cpp,
untime/test/queue_proxy_test.cpp) exercising both console C-ABI and PC C++ forms, canary padding, null output handling, hit counters, and proxy integrity.
Tested
Built on Windows 11 x64 with clang-cl 23.1.6 + lld-link 23.1.6 + xwin-sdk 10.0.26100 (NVIDIA GeForce GTX 1070, driver 581.80, WARP, and Vulkan D3D12 backend):
AI-assisted: yes
Checklist