Repository navigation
Conversation
Agility SDK 1.620 keeps an open command list's vtable in heap memory that is freed with the list. class_for cached the extended vtable by the runtime vtable's address and copied the runtime's methods only the first time, so a direct list whose open vtable came where a released compute list's had been called the compute list's methods: its ClearDepthStencilView made Close fail with E_FAIL. That is how vram's D32S8 test failed in parallel runs (2-5 in 10 with hle::d3d12x and one more module on 4 threads, RTX 5080; 0 in 12 with this change). A class of a vtable outside any module now keeps the methods it copied and is taken only while they are still the ones there. Fixes xcl-dev#2588
|
Verification on RTX 3060 Ti (Windows 11), branch merged with current
Thanks! — Devin |
|
AMD run (listed as untested), on Windows 11 too: on an RX 9070 XT the new test skips. The reuse it waits for did not happen in 3 runs, so on this machine it passes without exercising the fix. Head
So in the test's 200 tries, no direct list landed on a released compute list's vtable address here. Your report's SKIPPED list doesn't include this test, so it did run on the RTX 5080. Whether the address reuse is rarer here because of the GPU driver, Windows 11 or the heap was not looked into. This run also says nothing about whether the fix is right on AMD; it only shows the test does not reach it on this machine. Not tested: the machine's RTX 3060 (the test always uses the default adapter), Intel, a title. |
|
I found an additional cache-boundary case in the current implementation.
I prepared a focused follow-up at
Tested
Not tested
Exact-head GPU and smoke runs remain required after this change is folded into #2593. AI use
|
|
Tested: current PR head merged onto current
Not tested: retail titles (no title data on this lane, counts only). AI use: Hermes agent (local Qwen-class) ran both machines and drafted this; I checked it before posting. |
|
@mokkamokacaffe thanks for looking. I read
AI use: Claude Code (Claude Opus 5.5) read both commits and wrote this reply. |
|
NVIDIA test report for
|
Fixes #2588.
With the Agility SDK 1.620, an open command list's vtable is in heap memory and goes with the list.
real::class_forcached the extended vtable by the runtime vtable's address and copied the runtime's methods only once, so a direct list whose open vtable came where a released compute list's had been called the compute list's methods: itsClearDepthStencilViewmadeClosefail withE_FAIL. That is the parallel-only failure ofvram::tests::d32s8_targets_take_their_own_size_of_video_memory(#42).What is in it
crates/xcl/src/hle/d3d12x/real.rs: aClassof a vtable outside any module keeps the methods it copied (copied), andclass_fortakes it only while they are still the ones at that address. Vtables in a module's image are looked up as before.crates/xcl/src/hle/d3d12x/real.rs(class_tests):a_direct_list_at_a_released_compute_lists_vtable_records_with_its_own_methods.Tested
cargo test --workspace --no-fail-fast -- --test-threads=4at52c0802f: 1426 passed, 4 failed, 47 ignored. The 4 are DXIL GPU fuzz tests reproducibly fail with E_OUTOFMEMORY on RTX 5060 #1905 (fuzz_validate_and_gpu_0.._3, seeds 70, 545, 1019 and 1507), as on main6d12f58(GPU test results: NVIDIA RTX 3080 (wave32) and AMD RDNA2 iGPU (no mesh shaders) #42).V_MUL_F16,V_PK_MUL_F16,V_CVT_F16_F32);heap_window_out_of_memory_falls_back_to_the_switch_form: no heap windowscopied, and passes in 5 out of 5 with this change.--test-threads=4 hle::d3d12x hle::xgameruntime: the D32S8 test failed in 2–5 runs out of 10 on6d12f58, and in 0 out of 12 with this change.Regression run
main:
this PR:
Not tested
D3D12Core.dll, which this change looks up as before)list_x::tests::a_reset_while_the_last_submit_runs_records_on_another_pc_list)AI use