doitsujin / dxvk

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

Escape from Tarkov (DX11, Unity 5) crash on map load. #1135

Closed Vinjul1704 closed 5 years ago

Vinjul1704 commented 5 years ago

Hello, this is an issue not only I have, but pretty much everyone who plays this game on linux. I and many other people tried a lot of different wine and dxvk configurations (discussed here (reddit) or here (official forums), there is also a small discord server with a few people who tried a lot of things). We have a few (crash) logs, I only have 4 (I had to reinstall my whole system and lost all the other ones, sadly, but the errors are the same as in the logs from other people). I am not really experienced with all that yet, sorry. I know there are other people who posted about that issue here that know a lot more than me, so maybe they could provide some more information.

The game often crashed when the map loads or a few seconds after that, but not always. It crashes more often on maps with a lot of objects (like a mall with a lot of trash and goods laying around everywhere or just a really huge map). What I recognized is that it often crashed for me near areas where a lot of occlusion culling is going on and where there are a lot of occlusion culling issues even on windows. The fps is really bad at the beginning of a round, but that is also an issue on windows (maybe worth mentioning though?) and it usually doesn't crash after it worked fine for a few seconds (maybe up to a minute).

I ran an apitrace on windows because I was told this is what I should do. It took two whole days to complete (started the game, loaded into the map where it often crashed on linux and left shortly after that. No alt+f4, I exited via ingame buttons etc.). I used the dlls found here. I pasted the files d3d10.dll, d3d10_1.dll, d3d10core.dll, d3d11.dll and dxgi.dll into the directory where the exe is located and ran apitrace.

Escape from Tarkov, highest settings used. Linux distros where the issue occured: Arch linux, debian 9/10, fedora and many more used by other people who experienced crashes. Tested with and without lutris. Tested pretty much all runners available in lutris from 3.something up to ge 4.10 protonified. Also tested with custom wine versions (4.12 tested by me, for example. 4.something by someone else). Tested with DXVK 0.9.something up to 1.3. Other people tried even older versions, but I don't know which ones exactly.

The system I used for my linux testing (debian 10, cinnamon desktop):

The system I used for the apitrace (windows 10 enterprise ltsc):

Apitrace files: http://185.245.96.26/eft/EscapeFromTarkov.trace http://185.245.96.26/eft/EscapeFromTarkov.1.trace

Logs/Files I still have: http://185.245.96.26/eft/crash.dmp (generated by the game) http://185.245.96.26/eft/error.log (generated by the game) http://185.245.96.26/eft/output_log.txt (generated by the game) http://185.245.96.26/eft/EscapeFromTarkov_d3d11.log

doitsujin commented 5 years ago

I'm aware that this game has issues (see #873), but it's not really obvious why.

Unfortunately, the crash dump and error logs generated by the game aren't particularly useful as they only point to kernel32 (pretty much anything could call into that) with no useful stack trace, and the DXVK log doesn't point to any issues either.

Replaying both of your apitraces works fine on my end as well, so I cannot reproduce the crash.

Vinjul1704 commented 5 years ago

I will try to get an apitrace with the crash happening and send them here when they are done

robbierobs commented 5 years ago

I attached the last two logs I got while in-game running it on DXVK

CPU: i7 8750h GPU: GTX 1070 Wine: 4.12.1 TKG Patched DXVK: 1.3

As Vinjul1704 said, I have tried testing wine from 3.19 through 4.12.1 and DXVK .90 through 1.3

The last error I am getting is: warn: D3D11Device: Vertex input 'SV_POSITION0' not defined by input layout I am not sure if this is relevant or not.

Originally, I was getting the DxvkMemoryAllocator error but that's been mitigated with THP set to never (currently). I have noticed there are a few things that do tend to set it off. On first load, if memory usage is high it would cause the crash (MemoryAllocator?). You used to be able to mitigate it by sitting still for 1-2 mins until the frametimes would die down and then you'd be fine. This is substantially worse on the bigger maps.

Second, I have noticed that crashes happen around player interaction. While taking/receiving fire or being in their relative area, the game would crash. This seemed to get much worse around the last hotfix that they pushed and it could happen at any time during the raid. Currently, I am unable to play online due to this. Crashes are almost guaranteed.

Trying to run an apitrace online is almost impossible because the raid will be over by the time we load into the game. Are we able to run a different apitrace on Windows (AMD GPUPerf which is much faster and also playable)? On Linux, the game will not run without DXVK or some wonky wine configurations. If we HAVE to do it on wined3d I can spend some time trying to get it working again.

https://pastebin.com/embed_js/59Xebahy https://pastebin.com/embed_js/kHLvZy1K

Vinjul1704 commented 5 years ago

I got an apitrace on linux with the crash. Setup:

It took me 3 or 4 attempts to get the crash, which is why the apitrace is so big. http://185.245.96.26/eft/EscapeFromTarkov.trace.tar.gz

robbierobs commented 5 years ago

After further testing and analysis, I believe this issue is due to the anti-cheat that BSG is using currently. I would consider closing this. This is a not a Dxvk related issue.

Vinjul1704 commented 5 years ago

We fixed the issue on different setups, but don't have a solid solution/guide yet (we believe it is because of missing registry entries that causes issues with their anticheat). It is not a DXVK issue though. We will most likely update the lutris script once we figured out what exactly is going on. I will close this now.