doitsujin / dxvk

Vulkan-based implementation of D3D8, 9, 10 and 11 for Linux / Wine
zlib License
12.83k stars 827 forks source link

Horizon Zero Dawn (or the crash reporter?) crashes inmediately upon startup #3159

Closed braiam closed 1 year ago

braiam commented 1 year ago

On a new prefix with only winetricks -q vcrun2019 Horizon Zero Dawn crashes immediately before startup. It shows the crash handler prompt with a id and url to check out. The version comes from GOG. WIthout dxvk I can get a black loading screen.

This is also reported in wine https://bugs.winehq.org/show_bug.cgi?id=53050

System information

Log files

Wine stdout:

007c:fixme:wineusb:query_id Unhandled ID query type 0x5.
007c:fixme:hid:handle_IRP_MN_QUERY_ID Unhandled type 00000005
007c:fixme:hid:handle_IRP_MN_QUERY_ID Unhandled type 00000005
007c:fixme:hid:handle_IRP_MN_QUERY_ID Unhandled type 00000005
007c:fixme:hid:handle_IRP_MN_QUERY_ID Unhandled type 00000005
0108:fixme:nls:RtlGetThreadPreferredUILanguages 00000038, 000000000011F3A4, 000000000011F3C0 000000000011F3A0
0108:fixme:nls:get_dummy_preferred_ui_language (0x38 0x409 000000000011F3A4 000000000011F3C0 000000000011F3A0) returning a dummy value (current locale)
Initializing DLMalloc Heap
0108:fixme:ntdll:NtQuerySystemInformation info_class SYSTEM_PERFORMANCE_INFORMATION
0108:fixme:file:NtLockFile I/O completion on lock not implemented yet
[260:268:20221231,011617.998:ERROR crashpad_client_win.cc:521] CreateProcess: Path not found. (3)
0108:fixme:toolhelp:CreateToolhelp32Snapshot Unimplemented: heap list snapshot
0108:fixme:toolhelp:Heap32ListFirst : stub
014c:fixme:ver:GetCurrentPackageId (000000001660FE10 0000000000000000): stub
**************************************************************************** BuildID = HRZ-PCR 181/7517962 09:56 - Tue Jan 18 2022
* Executable Configuration = SubmissionGOG
* SaveGame Version = 28, flags = 0
* SessionID = '132b5043-7e59-44c5-b8bb-6e9e90e9ca98'
***************************************************************************0108:err:ole:com_get_class_object apartment not initialised
Allocator AssetMemory: Creating new region at [0x00007efc00000000
:0x00007efc40000000]
warn:  CreateDXGIFactory2: Ignoring flags
info:  Game: HorizonZeroDawn.exe
info:  DXVK: v2.0-46-gf94b42f2
info:  Built-in extension providers:
info:    Win32 WSI
info:    OpenVR
info:    OpenXR
info:  OpenVR: could not open registry key, status 2
info:  OpenVR: Failed to locate module
info:  Enabled instance extensions:
info:    VK_KHR_get_surface_capabilities2
info:    VK_KHR_surface
info:    VK_KHR_win32_surface
warn:  Skipping CPU adapter: llvmpipe (LLVM 15.0.5, 256 bits)
info:  AMD Radeon RX 590 Series (RADV POLARIS10):
info:    Driver: 22.2.4
info:    Vulkan: 1.3.224
info:    Memory Heap[0]:
info:      Size: 16014 MiB
info:      Flags: 0x0
info:      Memory Type[2]: Property Flags = 0x6
info:      Memory Type[4]: Property Flags = 0xe
info:    Memory Heap[1]:
info:      Size: 8192 MiB
info:      Flags: 0x1
info:      Memory Type[0]: Property Flags = 0x1
info:      Memory Type[1]: Property Flags = 0x1
info:      Memory Type[3]: Property Flags = 0x7
warn:  DxgiAdapter::QueryInterface: Unknown interface query
warn:  17399d75-964e-4c03-99f8-9d4fd196dd62
018c:fixme:imm:ImeSetActiveContext (000000000001005E, 1): stub
018c:fixme:imm:ImmReleaseContext (0000000000010064, 000000000001005E): stub
008c:fixme:imm:ImeSetActiveContext (0000000000010026, 0): stub
008c:fixme:imm:ImmReleaseContext (0000000000010020, 0000000000010026): stub
[260:396:20221231,011625.654:ERROR crashpad_client_win.cc:792] crash server failed to launch, no dump captured
An Access Violation (C0000005h) has occurred in thread 'Main' (0) at instruction location 0000000140245A7Ch while trying to read from addres
s 0000000000000000h

Call stack:
Base address: 0x000140000000
  0. 0x00017005547E    ntdll, 0x7005547E
  1. 0x000140245A7C    horizonzerodawn, 0x40245A7C
  2. 0x0001402449A4    horizonzerodawn, 0x402449A4
  3. 0x000140222279    horizonzerodawn, 0x40222279
  4. 0x0001415DF4E7    horizonzerodawn, 0x415DF4E7
  5. 0x0001400CD7D4    horizonzerodawn, 0x400CD7D4
  6. 0x0001400CFCB2    horizonzerodawn, 0x400CFCB2
  7. 0x000141993322    horizonzerodawn, 0x41993322
  8. 0x00007B627E49    kernel32, 0x7B627E49
  9. 0x00017005DCB8    ntdll, 0x7005DCB8
 10. 0x000000000000
 11. 0x0001419933F8    horizonzerodawn, 0x419933F8
 12. 0x000067FF0000
 13. 0x000000000000

The application will now terminate
Kron4ek commented 1 year ago

HZD is a D3D12 game, DXVK (except for its dxgi) does not work with it. You need to use vkd3d-proton.

Blisto91 commented 1 year ago

Yes as said above make sure you are also using vkd3d-proton which is what dxvk is usually paired with for d3d12

braiam commented 1 year ago

I'm aware of that, which is why it's surprising that when dxvk is also installed in the same prefix it changes its behavior. In the report I made references trying to indicate that I'm unsure if the game itself or the crash reporter is the one crashing. In other hand, should I use vkd3d-proton if I'm using wine directly?

mbriar commented 1 year ago

Upstream vkd3d is incompatible with DXVK's DXGI, which is why it changes behavior (upstream vkd3d is used by default for d3d12 and breaks when you install DXVK and enable it's DXGI). Upstream vkd3d is also currently unable to run HZD, because it lacks support for SM6 DXIL shaders, which is why it doesn't work without DXVK either. If you want it to work, you need to install both DXVK and vkd3d-proton. There is no DXVK or wine bug to fix here.

Blisto91 commented 1 year ago

Yes vkd3d-proton can also be used in regular wine. That said i don't actually know much about using dxvk's dxgi with upstream vkd3d so maybe there is an issue there indeed. But I'll let the devs answer that 🙂

Edit: oh mbriar ninjaed me there lol

mbriar commented 1 year ago

Well, to be honest, I'm not 100% sure if DXVK's DXGI is supposed to work with upstream vkd3d, but there is not much use case for it anyways because upstream vkd3d doesn't really run any games and you can just disable DXVK's DXGI if you really want to try it for some reason.

K0bin commented 1 year ago

I think mbriar has explained it pretty well. I'm gonna close this. Feel free to re-open if there's an actual DXVK bug.

crbble commented 1 year ago

Just a hint for people running into the original issue with the crash reporter. I am not sure if this is clear from the comments above, but for me to run HZD on an eGPU setup with Nvidia GTX 1060 with vanilla wine from Archlinux I had to first install vkd3d-proton into the wine prefix and also install dxvk into the same wine prefix. This does not make sense to me, but it works.

Blisto91 commented 1 year ago

This does not make sense to me, but it works.

Since vkd3d-proton 2.9 (and maybe semi before? Not sure on that) it now requires dxvk's dxgi.dll and isn't compatible with wines own. At least as of writing.