diff options
| author | sds-228 <329233051+sds-228@users.noreply.github.com> | 2026-11-23 02:12:09 +0300 |
|---|---|---|
| committer | sds-228 <329233051+sds-228@users.noreply.github.com> | 2026-11-23 02:12:09 +0300 |
| commit | cc4b37449929516fefbd4e999b77836698a9bfd4 (patch) | |
| tree | 598d1551196216ddd47cf46b22ea07359442fbb5 /runtime/shims/d3d12_com.cpp | |
| parent | aa2988cc555bad7ecd508b48a702adbb32fe7c95 (diff) | |
d3d12: translate ARRAY_OF_POINTERS instances on the KHR path
KHR TLAS builds hardcoded arrayOfPointers = VK_FALSE and passed the guest's console-VA pointer list straight to Vulkan. Carry DescsLayout into the recorded build, validate each pointer, stage a copy with heap_base added into a device-addressable buffer, and use it as the build input. The guest input is not modified and GPU-written pointer lists are refused. Adds ARRAY and ARRAY_OF_POINTERS RayQuery coverage plus a null-entry refusal check.
Diffstat (limited to 'runtime/shims/d3d12_com.cpp')
| -rw-r--r-- | runtime/shims/d3d12_com.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/runtime/shims/d3d12_com.cpp b/runtime/shims/d3d12_com.cpp index d9b1a009c..faf607248 100644 --- a/runtime/shims/d3d12_com.cpp +++ b/runtime/shims/d3d12_com.cpp | |||
| @@ -722,6 +722,7 @@ public: | |||
| 722 | if (cmd.is_tlas) { | 722 | if (cmd.is_tlas) { |
| 723 | cmd.instances_va = in.InstanceDescs; | 723 | cmd.instances_va = in.InstanceDescs; |
| 724 | cmd.instance_count = in.NumDescs; | 724 | cmd.instance_count = in.NumDescs; |
| 725 | cmd.instance_pointers = in.DescsLayout == D3D12_ELEMENTS_LAYOUT_ARRAY_OF_POINTERS; | ||
| 725 | } else { | 726 | } else { |
| 726 | for (UINT i = 0; i < in.NumDescs; ++i) { | 727 | for (UINT i = 0; i < in.NumDescs; ++i) { |
| 727 | const D3D12_RAYTRACING_GEOMETRY_DESC* gd = | 728 | const D3D12_RAYTRACING_GEOMETRY_DESC* gd = |