protonscr

Issue running simple Microsoft DXR SDK samples using https://github.com/HansKristian-Work/vkd3d-proton/pull/566..

vkd3dclosed
HansKristian-Work/vkd3d-proton#568 · opened 2021-03-12 by oscarbg · updated 2021-03-19 · 4 comments · github
Ooscarbg 2021-03-12 github

Hi,
first congrats for success in running Control with DXR enabled!
sadly, I get no success, just trying some DXR samples from Microsoft SDK: https://github.com/microsoft/DirectX-Graphics-Samples/tree/master/Samples/Desktop/D3D12Raytracing
I attach prebuilt binaries for fast testing:
dxrsamples.zip
using a build from: https://github.com/HansKristian-Work/vkd3d-proton/pull/566
I'm getting in all samples same error:

15152:err:vkd3d_dxil_log_callback: dxil-spirv: Failed to convert function.
15152:err:d3d12_state_object_compile_pipeline: Failed to convert DXIL export: MyRaygenShader

hope is a minor issue and getting it solved helps running more DXR apps..

full log:

warn:  DXGIDeclareAdapterRemovalSupport: Stub
info:  Game: D3D12RaytracingHelloWorld.exe
info:  DXVK: v1.8
info:  Built-in extension providers:
info:    Win32 WSI
info:    OpenVR
info:    OpenXR
warn:  OpenVR: Failed to locate module
info:  Enabled instance extensions:
info:    VK_KHR_get_surface_capabilities2
info:    VK_KHR_surface
info:    VK_KHR_win32_surface
info:  TITAN V:
info:    Driver: 461.81.0
info:    Vulkan: 1.2.155
info:    Memory Heap[0]: 
info:      Size: 12079 MiB
info:      Flags: 0x1
info:      Memory Type[7]: Property Flags = 0x1
info:    Memory Heap[1]: 
info:      Size: 16362 MiB
info:      Flags: 0x0
info:      Memory Type[0]: Property Flags = 0x0
info:      Memory Type[1]: Property Flags = 0x0
info:      Memory Type[2]: Property Flags = 0x0
info:      Memory Type[3]: Property Flags = 0x0
info:      Memory Type[4]: Property Flags = 0x0
info:      Memory Type[5]: Property Flags = 0x0
info:      Memory Type[6]: Property Flags = 0x0
info:      Memory Type[8]: Property Flags = 0x6
info:      Memory Type[9]: Property Flags = 0xe
info:    Memory Heap[2]: 
info:      Size: 246 MiB
info:      Flags: 0x1
info:      Memory Type[10]: Property Flags = 0x7
info:  DXGI: NvAPI workaround enabled, reporting AMD GPU
info:  DXGI: NvAPI workaround enabled, reporting AMD GPU
15152:info:vkd3d_get_vk_version: vkd3d-proton - applicationVersion: 2.2.0.
15152:info:vkd3d_instance_init: vkd3d-proton - build: f251b5c35ee80cf.
15152:info:vkd3d_bindless_state_get_bindless_flags: Device does not support VK_VALVE_mutable_descriptor_type.
15152:fixme:d3d12_device_caps_init_feature_options1: TotalLaneCount = 10240, may be inaccurate.
15152:info:d3d12_device_determine_ray_tracing_tier: DXR support enabled.
info:  DXGI: NvAPI workaround enabled, reporting AMD GPU
15152:info:vkd3d_get_vk_version: vkd3d-proton - applicationVersion: 2.2.0.
15152:info:vkd3d_instance_init: vkd3d-proton - build: f251b5c35ee80cf.
15152:info:vkd3d_bindless_state_get_bindless_flags: Device does not support VK_VALVE_mutable_descriptor_type.
15152:fixme:d3d12_device_caps_init_feature_options1: TotalLaneCount = 10240, may be inaccurate.
15152:info:d3d12_device_determine_ray_tracing_tier: DXR support enabled.
info:  DXGI: NvAPI workaround enabled, reporting AMD GPU
15152:info:vkd3d_get_vk_version: vkd3d-proton - applicationVersion: 2.2.0.
15152:info:vkd3d_instance_init: vkd3d-proton - build: f251b5c35ee80cf.
15152:info:vkd3d_bindless_state_get_bindless_flags: Device does not support VK_VALVE_mutable_descriptor_type.
15152:fixme:d3d12_device_caps_init_feature_options1: TotalLaneCount = 10240, may be inaccurate.
15152:info:d3d12_device_determine_ray_tracing_tier: DXR support enabled.
15152:fixme:d3d12_swapchain_init: Ignoring swap effect 0x4.
15152:fixme:d3d12_swapchain_init: Ignoring swapchain flags 0x800.
warn:  DXGI: MakeWindowAssociation: Ignoring flags
15152:err:vkd3d_dxil_log_callback: dxil-spirv: Failed to convert function.
15152:err:d3d12_state_object_compile_pipeline: Failed to convert DXIL export: MyRaygenShader
SSveSop 2021-03-13 github
warn:  DXGIDeclareAdapterRemovalSupport: Stub
info:  Game: D3D12RaytracingHelloWorld.exe
info:  DXVK: v1.8.1-1-g8f343b87
info:  Found config file: /home/XXX/dxr.conf
info:  Effective configuration:
info:    dxgi.nvapiHack = False
info:  GeForce RTX 2070:
info:    Driver: 455.50.10
info:    Vulkan: 1.2.170

248:info:vkd3d_config_flags_init_once: VKD3D_CONFIG='dxr'.

248:info:d3d12_device_determine_ray_tracing_tier: DXR support enabled.
248:info:vkd3d_get_vk_version: vkd3d-proton - applicationVersion: 2.2.0.
248:info:vkd3d_instance_init: vkd3d-proton - build: 499d741c0fa2092.
248:warn:vkd3d_memory_info_find_global_mask: Blocking memory type 10 for use (PCI-pinned memory).
248:info:vkd3d_bindless_state_get_bindless_flags: Device does not support VK_VALVE_mutable_descriptor_type.
248:fixme:d3d12_device_caps_init_feature_options1: TotalLaneCount = 2304, may be inaccurate.
248:info:d3d12_device_determine_ray_tracing_tier: DXR support enabled.
248:fixme:d3d12_swapchain_init: Ignoring swap effect 0x4.
248:fixme:d3d12_swapchain_init: Ignoring swapchain flags 0x800.
248:warn:select_vk_format: Failed to find Vulkan swapchain format for DXGI_FORMAT_R8G8B8A8_UNORM.
warn:  DXGI: MakeWindowAssociation: Ignoring flags
248:warn:parse_dxbc: Ignoring DXBC checksum.
248:warn:skip_dword_unknown: Skipping 4 unknown DWORDs:
248:warn:skip_dword_unknown:    0xd6d8136d
248:warn:skip_dword_unknown:    0x2cf96ae9
248:warn:skip_dword_unknown:    0xbd5fe36c
248:warn:skip_dword_unknown:    0x16d13fb1
248:warn:parse_dxbc: Ignoring DXBC checksum.
248:warn:skip_dword_unknown: Skipping 4 unknown DWORDs:
248:warn:skip_dword_unknown:    0x38148c3a
248:warn:skip_dword_unknown:    0xc98cca7f
248:warn:skip_dword_unknown:    0x1d7e75fc
248:warn:skip_dword_unknown:    0x9c9e8537
248:err:vkd3d_dxil_log_callback: dxil-spirv: Failed to convert function.
248:err:d3d12_state_object_compile_pipeline: Failed to convert DXIL export: MyRaygenShader

This is with:

VKD3D_DEBUG=trace
VKD3D_SHADER_DEBUG=trace
VKD3D_CONFIG=dxr

Had to use DXVK's dxgi.dll or else it would crash on DXGIDeclareAdapterRemovalSupport when using wine native dxgi.dll.

HHansKristian-Work maintainer 2021-03-17 github

The PR works fine for me, only issue is that I get some weird corruption on one of the spheres, but I'm pretty positive it's a driver bug. I've filed a bug.

Screenshot from 2021-03-17 16-41-34

HHansKristian-Work maintainer 2021-03-17 github

Actually, it's probably an app bug ... shader replaced tmin from 0.0 to 0.001 and it works fine. Odd that it worked on native driver, but I suppose there are some precision shenanigans that just happened to work on the D3D12 driver ...

EDIT: On even closer analysis, the sample might be supposed to guard against this case, but the control flow is complicated enough I think it threw dxil-spirv off. Sigh ...

Ooscarbg 2021-03-19 github

using VKD3D from https://github.com/HansKristian-Work/vkd3d-proton/actions/runs/665766380
works, even sphere bugs are fixed!
many thanks!

Launch options

Upstream links

DLLs

Error codes