Difference between revisions of "Vkd3d-todo"

From WineHQ Wiki
Jump to: navigation, search
(→‎vkd3d 1.3 release: more stuff to do before release...)
 
(22 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
[[Vkd3d]]  
 
[[Vkd3d]]  
  
== libvkd3d-shader release ==
+
== vkd3d 1.3 release ==
  
* Finish API for flexible shader parameters.
+
* Review of new APIs:
* Add API for passing compilation options/parameters (e.g. disable rasterization, emulate d3d discard?)
+
** Can we find a better way to pass "parent_data" from PFN_vkd3d_shader_open_include, and "code" from PFN_vkd3d_shader_close_include? Associate a more generic "context" parameter with struct vkd3d_shader_code?
* Add API for enabling optional features/extensions, e.g. SPIR-V extensions, GLSL extensions.
+
** Should we specify the DXBC profile info using a C struct instead of a string?
* Avoid artificial limits in the API, e.g. VKD3D_SHADER_MAX_UNORDERED_ACCESS_VIEWS.
+
** Do we really want "secondary_code" to be part of the vkd3d_shader_hlsl_source_info structure? It's very specific...
* Should shader translation to GLSL use the same exported function as SPIR-V translator?
+
** Do we really want "profile" to be part of the vkd3d_shader_hlsl_source_info structure? It relates more to the target, and specifically DXBC/D3DBC.
* Should DXIL use the same exported function as TPF (DXBC)?
+
* Finish API for scanning/gathering info from shaders (registers used, bindings used, parameters used, required limits, extensions).
* Consider renaming vkd3d_shader_compile_dxbc() to vkd3d_shader_compile_tpf() (Tokenized Program Format).
+
* Implement ID3D11ShaderReflection et al.
* Consider addding tests for OpenGL SPIR-V.
+
** Should we put everything into the same (chained) vkd3d_shader_scan_dxbc_info struct, or split them up? (Split up the DXBC-specific ones from the rest?)
* Review API for consistency and extensibility.
+
** I guess HLSL compile flags should be preserved verbatim...? I don't like the disparity we currently have.
* Add support for resource arrays.
+
** How to do things like constant table types?
* Add or consider support for Shader Model 5.1 and 6.0+.
+
* Consider adding tests for OpenGL SPIR-V.
* Add or consider support for UAV in vertex processing shader stages.
+
* Review API for consistency and extensibility.
 
* Add support for SSBO.
 
* Add support for SSBO.
* Finish API for scanning/gathering info from shaders (registers used, bindings used, parameters used, required limits, extensions).
+
* Use ranges for binding mappings if possible.
 +
* Let vkd3d-compiler automatically detect source type.
  
 
== libvkd3d ==
 
== libvkd3d ==
  
* Re-implement descriptor heaps on top of VK_EXT_descriptor_indexing.
+
* Re-implement descriptor heaps on top of VK_EXT_descriptor_indexing (WIP - jkucia).
 
* Try to use VK_EXT_buffer_device_address for GPU addresses (partially done - jkucia).
 
* Try to use VK_EXT_buffer_device_address for GPU addresses (partially done - jkucia).
* Implement ID3D12Resource::ReadFromSubresource() for Metro Exodus.
+
* <s>Implement ID3D12Resource::ReadFromSubresource() for Metro Exodus.</s>
* Emulate wait-before-signal (mostly done - jkucia).
+
* Emulate wait-before-signal (partially done - jkucia).
 
* <s>Emulate NULL SRVs and UAVs.</s>
 
* <s>Emulate NULL SRVs and UAVs.</s>
 
* Add tests for out-of-bounds access with vertex buffers.
 
* Add tests for out-of-bounds access with vertex buffers.
 
* Improve multi-queue support.
 
* Improve multi-queue support.
 +
* Queue family ownership transfer.
 
* Fix all Vulkan validation errors.
 
* Fix all Vulkan validation errors.
* Test ClearRTV() with UINT formats.
+
* <s>Test ClearRTV() with UINT formats.</s>
 
* Fix clears for A8_UNORM.
 
* Fix clears for A8_UNORM.
 
* Implement UAVs in vertex processing shader stages.
 
* Implement UAVs in vertex processing shader stages.
 
* Implement support for multiple viewports.
 
* Implement support for multiple viewports.
* Implement ID3D12GraphicsCommandList::SetPredication().
+
* <s>Implement ID3D12GraphicsCommandList::SetPredication().</s>
 
* Test and fix copying between BC and other compatible formats.
 
* Test and fix copying between BC and other compatible formats.
 
* State decay for resources and queue ownership transfer for resources.
 
* State decay for resources and queue ownership transfer for resources.
 
* Add tests for "lod" shader instruction.
 
* Add tests for "lod" shader instruction.
* Add tests for sample_d and sample_b instructions.
+
* <s>Add tests for sample_d and sample_b instructions.</s>
 
* Add tests for "bufinfo" instruction.
 
* Add tests for "bufinfo" instruction.
 
* Add tests for bufinfo and resinfo with NULL SRV and UAV descriptors.
 
* Add tests for bufinfo and resinfo with NULL SRV and UAV descriptors.
* Add a test for early depth-stencil (mostly done - jkucia).
+
* <s>Add a test for early depth-stencil.</s>
 
* Add a test and fix relative vertex input addressing.
 
* Add a test and fix relative vertex input addressing.
 
* Reduce the number of queue submits. Queue submits are generally expensive, especially on recent kernels with amdgpu (mostly done - jkucia).
 
* Reduce the number of queue submits. Queue submits are generally expensive, especially on recent kernels with amdgpu (mostly done - jkucia).
 +
* <s>Use VK_KHR_image_format_list</s>.
 
* Merge vkCmdPipelineBarrier() calls.
 
* Merge vkCmdPipelineBarrier() calls.
 
* Try to avoid fence worker thread when possible.
 
* Try to avoid fence worker thread when possible.
* Optimize fence worker thread?
+
* <s>Implement workaround for minTexelBufferOffsetAlignment  (NVIDIA).</s>
* Implement workaround for minTexelBufferOffsetAlignment  (NVIDIA).
+
* Implement stencil aspect resource state transitions.
* Implement stencil plane resource state transitions.
 
 
* Implement cache for SPIR-V shaders?
 
* Implement cache for SPIR-V shaders?
 
* Implement disk pipeline/shader cache?
 
* Implement disk pipeline/shader cache?
Line 54: Line 56:
 
* Raytracing?
 
* Raytracing?
 
* DirectML?
 
* DirectML?
 +
* Add support for sRGB swapchain views (VK_KHR_image_format_list).
 +
* Add tests for validation of view format compatibility (RTV, SRV, UAV, DSV).
  
 
== libvkd3d-shader ==
 
== libvkd3d-shader ==
Line 60: Line 64:
 
* Add support for unlimited registers (SM5.1).
 
* Add support for unlimited registers (SM5.1).
 
* Finish and fix tessellation shaders (I have some patches but unfortunately a lot of shaders are broken by Nvidia driver bugs - jkucia).
 
* Finish and fix tessellation shaders (I have some patches but unfortunately a lot of shaders are broken by Nvidia driver bugs - jkucia).
* Import SM4 to GLSL shader translation from wined3d.
 
 
* Start working on DXIL.
 
* Start working on DXIL.
 
* Add foundations for common shader tests. Write a shader test one time and run it on D3D10, D3D11, D3D12, Vulkan and OpenGL on Linux and Windows (mostly done - jkucia).
 
* Add foundations for common shader tests. Write a shader test one time and run it on D3D10, D3D11, D3D12, Vulkan and OpenGL on Linux and Windows (mostly done - jkucia).
 
* Add tests for OpenGL atomic counters.
 
* Add tests for OpenGL atomic counters.
* Implement D3D discard.
+
* <s>Implement D3D discard.</s>
 +
* Import SM4 to GLSL shader translation from wined3d.
 +
* Add support for Shader Model 6.0+.
  
 
==== TPF validation ====
 
==== TPF validation ====
  
Vkd3d-shader generally assumes that Direct3D shader bytecode is valid and doesn't do much validation. It would be nice to have some kind of validation pass. The validation potentially could be optional, e.g. used only in debug builds.
+
Vkd3d-shader generally assumes that Direct3D shader bytecode is valid and doesn't do much validation. We should introduce some kind of validation pass. The validation potentially could be optional, e.g. used only in debug builds.
  
 
* Interpolation mode is the same for all variables in the input register.
 
* Interpolation mode is the same for all variables in the input register.
 +
* Number of indices for resources (SM5 vs SM5.1).
  
 
== DXGI ==
 
== DXGI ==
  
* Implement d3d12_swapchain_SetFullscreenState().
+
* <s>Implement d3d12_swapchain_SetFullscreenState().</s>
* Implement d3d12_swapchain_GetFullscreenState().
+
* <s>Implement d3d12_swapchain_GetFullscreenState().</s>
* Implement d3d12_swapchain_ResizeTarget().
+
* <s>Implement d3d12_swapchain_ResizeTarget().</s>
 
* Fix adapter LUIDs in Wine.
 
* Fix adapter LUIDs in Wine.
 
* Reimplement IDXGIAdapter3::QueryVideoMemoryInfo() on top of VK_EXT_memory_budget. Ideally, Vulkan implementations should return the memory budget based on total system load (memory used by all graphics APIs).
 
* Reimplement IDXGIAdapter3::QueryVideoMemoryInfo() on top of VK_EXT_memory_budget. Ideally, Vulkan implementations should return the memory budget based on total system load (memory used by all graphics APIs).

Latest revision as of 19:23, 25 December 2021

Vkd3d

vkd3d 1.3 release

  • Review of new APIs:
    • Can we find a better way to pass "parent_data" from PFN_vkd3d_shader_open_include, and "code" from PFN_vkd3d_shader_close_include? Associate a more generic "context" parameter with struct vkd3d_shader_code?
    • Should we specify the DXBC profile info using a C struct instead of a string?
    • Do we really want "secondary_code" to be part of the vkd3d_shader_hlsl_source_info structure? It's very specific...
    • Do we really want "profile" to be part of the vkd3d_shader_hlsl_source_info structure? It relates more to the target, and specifically DXBC/D3DBC.
  • Finish API for scanning/gathering info from shaders (registers used, bindings used, parameters used, required limits, extensions).
  • Implement ID3D11ShaderReflection et al.
    • Should we put everything into the same (chained) vkd3d_shader_scan_dxbc_info struct, or split them up? (Split up the DXBC-specific ones from the rest?)
    • I guess HLSL compile flags should be preserved verbatim...? I don't like the disparity we currently have.
    • How to do things like constant table types?
  • Consider adding tests for OpenGL SPIR-V.
  • Review API for consistency and extensibility.
  • Add support for SSBO.
  • Use ranges for binding mappings if possible.
  • Let vkd3d-compiler automatically detect source type.

libvkd3d

  • Re-implement descriptor heaps on top of VK_EXT_descriptor_indexing (WIP - jkucia).
  • Try to use VK_EXT_buffer_device_address for GPU addresses (partially done - jkucia).
  • Implement ID3D12Resource::ReadFromSubresource() for Metro Exodus.
  • Emulate wait-before-signal (partially done - jkucia).
  • Emulate NULL SRVs and UAVs.
  • Add tests for out-of-bounds access with vertex buffers.
  • Improve multi-queue support.
  • Queue family ownership transfer.
  • Fix all Vulkan validation errors.
  • Test ClearRTV() with UINT formats.
  • Fix clears for A8_UNORM.
  • Implement UAVs in vertex processing shader stages.
  • Implement support for multiple viewports.
  • Implement ID3D12GraphicsCommandList::SetPredication().
  • Test and fix copying between BC and other compatible formats.
  • State decay for resources and queue ownership transfer for resources.
  • Add tests for "lod" shader instruction.
  • Add tests for sample_d and sample_b instructions.
  • Add tests for "bufinfo" instruction.
  • Add tests for bufinfo and resinfo with NULL SRV and UAV descriptors.
  • Add a test for early depth-stencil.
  • Add a test and fix relative vertex input addressing.
  • Reduce the number of queue submits. Queue submits are generally expensive, especially on recent kernels with amdgpu (mostly done - jkucia).
  • Use VK_KHR_image_format_list.
  • Merge vkCmdPipelineBarrier() calls.
  • Try to avoid fence worker thread when possible.
  • Implement workaround for minTexelBufferOffsetAlignment (NVIDIA).
  • Implement stencil aspect resource state transitions.
  • Implement cache for SPIR-V shaders?
  • Implement disk pipeline/shader cache?
  • Implement sparse resources?
  • Optimize barriers (render passes, ClearUnorderedAccessView, transform feedback).
  • Memory residency.
  • Raytracing?
  • DirectML?
  • Add support for sRGB swapchain views (VK_KHR_image_format_list).
  • Add tests for validation of view format compatibility (RTV, SRV, UAV, DSV).

libvkd3d-shader

  • Add support for capturing components with stream output.
  • Add support for unlimited registers (SM5.1).
  • Finish and fix tessellation shaders (I have some patches but unfortunately a lot of shaders are broken by Nvidia driver bugs - jkucia).
  • Start working on DXIL.
  • Add foundations for common shader tests. Write a shader test one time and run it on D3D10, D3D11, D3D12, Vulkan and OpenGL on Linux and Windows (mostly done - jkucia).
  • Add tests for OpenGL atomic counters.
  • Implement D3D discard.
  • Import SM4 to GLSL shader translation from wined3d.
  • Add support for Shader Model 6.0+.

TPF validation

Vkd3d-shader generally assumes that Direct3D shader bytecode is valid and doesn't do much validation. We should introduce some kind of validation pass. The validation potentially could be optional, e.g. used only in debug builds.

  • Interpolation mode is the same for all variables in the input register.
  • Number of indices for resources (SM5 vs SM5.1).

DXGI

  • Implement d3d12_swapchain_SetFullscreenState().
  • Implement d3d12_swapchain_GetFullscreenState().
  • Implement d3d12_swapchain_ResizeTarget().
  • Fix adapter LUIDs in Wine.
  • Reimplement IDXGIAdapter3::QueryVideoMemoryInfo() on top of VK_EXT_memory_budget. Ideally, Vulkan implementations should return the memory budget based on total system load (memory used by all graphics APIs).

Vulkan

  • Try to fix detached WSI surfaces after D3D9/D3D11 swapchain (OpenGL) is created for a window with D3D12 swapchain (Vulkan).
  • Fix child window rendering for D3D12 RenderDoc.