HGL
generous-apricot
Horizon Zero Dawn (GOG version) freezes on initial load screen
Running into an error I can't find anything on when trying to launch HZD via Heroic.
I've tried
winetricks vcrun2019 mfc140
and set mfc140.dll
as an override in winecfg, without which the game won't even start.
Now, the game freezes about three-quarters through the first loading screen (upon starting the game). The log shows the following error:
Fatal error occurred: DLMalloc Assert: file D:\dev\HRZ-PCR\Code\PIGS\PCore\dlmalloc_src.c, line 5535, func mspace_malloc
I've attached the full logfile below.
Starting the game directly through Steam via Proton has similar results - install mfc140.dll
through protontricks to start the game, then a freeze on the initial load screen.
...Help?87 Replies
generous-apricotOP•2y ago
System specs:
Latest Archlinux
Nvidia RTX 3070 ti
32GB DDR4-3200MHz RAM
Intel i5-10600K, OC to 5.0Ghz (Microcode updates enabled)
Please send in Heroic's full game log (read #:pushpin: Read Me First | Frequently Asked Questions if you don't know what that is or how you'd get to it)
generous-apricotOP•2y ago
Here is the full logfile.
Try installing
d3dcompiler_43
and d3dcompiler_47
with Winetricksgenerous-apricotOP•2y ago

generous-apricotOP•2y ago
Got a crash message this time from the engine. Progress, I guess.
generous-apricotOP•2y ago
Here are the current game settings

Definitely
I'd need another log then
generous-apricotOP•2y ago
As an aside:
/home/Data/
Is that a 2nd hard drive? That's... not where you mount thosegenerous-apricotOP•2y ago
Yeah I know. Typically in /mnt or similar.
I could (and probably should) relocate them, but there are already a number of things tied to them and I don't really feel like moving everything around.
Just to rule file issues out I'm verifying the game files and clearing the shader cache.
This may sound weird, but could you try disabling your iGPU in your BIOS?
generous-apricotOP•2y ago
Sure. I'll reboot once the verification is done and report back 👍
ratty-blush•2y ago
horizon zero down requires vcrun2019 installed with winetricks
generous-apricotOP•2y ago
Looks like the BIOS for MSI boards doesn't have a specific setting to disable the iGPU. According to forum posts I found, disabling iGPU multi-monitor should prevent it from being initialized on startup, so I did that... No dice though.
It's installed. That was one of the first things I tried after
mfc140.dll
per Lutris's page.ratty-blush•2y ago
shouldn't need any other tweak (no need to install mfc)
have you tried with a clean prefix?
- delete /home/Data/Games/Heroic/prefixes/HorizonZeroDawn
- install vcrun2019
- try launching the game
in case other tests messed up your prefix
generous-apricotOP•2y ago
I can give that a shot. One sec.
According to Nvidia settings iGPU is disabled, so that shouldn't cause issues either.
generous-apricotOP•2y ago
No dice. Here's the logfile; same
malloc
error as before.generous-apricotOP•2y ago
Made some progress. Running via system WINE instead of Wine-GE gets rid of the malloc() error.
Currently testing with a clean prefix and just vcrun2019.
Also no dice there. Loading screen doesn't even get as far.
genetic-orange•2y ago
install d3dcompiler_43 and d3dcompiler_47 through winetricks
generous-apricotOP•2y ago
Already tried that.
genetic-orange•2y ago
it didn't install ig
generous-apricotOP•2y ago
This was the result.
They enable WINE to display a crash message. That's about it.
genetic-orange•2y ago
it didn't install
try it again
did you use winetricks through heroic ui?
generous-apricotOP•2y ago
Alright. I'm willing to try pretty much anything at this point.
Yes. Should I manually start Winetricks?
genetic-orange•2y ago
if I remember correctly this game had a bug with nvidia cards
no use heroic ui
generous-apricotOP•2y ago
Still the same
Fatal error occurred: DLMalloc Assert: file D:\dev\HRZ-PCR\Code\PIGS\PCore\dlmalloc_src.c, line 5535, func mspace_malloc
.
Here's what Winetricks shows as installed:
generous-apricotOP•2y ago
...Unless Winecfg needs overrides for those DLLs. Let me test that.
That would be a no.
generous-apricotOP•2y ago
generous-apricotOP•2y ago
No dice.
genetic-orange•2y ago
Could you send a new log
Wait it's right there
Ok all the d3dcompiler junk is gone
generous-apricotOP•2y ago
Yeah; it's a step in the right direction.
Window is still freezing though.
generous-apricotOP•2y ago

genetic-orange•2y ago
seems like some kind of wine bug
but then the game should be borked for everyone
hold on
generous-apricotOP•2y ago
It's not even refreshing itself or staying black; just crashing entirely and letting other windows smear all over them.
Yeah that's what's got me confused
genetic-orange•2y ago
what is your sysctl vm.max_map_count
generous-apricotOP•2y ago
vm.max_map_count = 65530
genetic-orange•2y ago
oof
that's VERY low
generous-apricotOP•2y ago
What exactly is it?
genetic-orange•2y ago
sudo sysctl -w vm.max_map_count=2147483642
number of memory maps a process can have
generous-apricotOP•2y ago
Oh. Yeah that would do it.
genetic-orange•2y ago
oversimplfying: malloc creates one per allocation
generous-apricotOP•2y ago
Alright let's try that.
Nothing. Do I need to reboot or is the change immediate?
genetic-orange•2y ago
immediate
reboot will remove it
generous-apricotOP•2y ago
Noted.
Yeah, still the same malloc() error.
generous-apricotOP•2y ago
continuing-cyan•2y ago
if you deleted your prefix, youwould have to reinstall the winetricks stuff btw
i think you may have done that in one of the earlier steps
generous-apricotOP•2y ago
Yep. I've cleared the prefix multiple times, but re-installed the appropriate DLLs after each step.
continuing-cyan•2y ago
cool just checking 🙂
generous-apricotOP•2y ago
Honestly I'm very convinced that I'm doing something incredibly stupid at this point. So any suggestions, however simple, are appreciated just to narrow down the possibilities.
genetic-orange•2y ago
try turning off fsync too
generous-apricotOP•2y ago
Leave Esync on? Or switch that off as well?
genetic-orange•2y ago
both off
generous-apricotOP•2y ago
No change.
generous-apricotOP•2y ago
generous-apricotOP•2y ago
I'm tempted to run a system upgrade just in case. The last one was two days ago, but it probably couldn't hurt.
ratty-blush•2y ago
one thing you could try (no idea if it will make a difference, maybe it's useless, but it's easy though) is to try with Heroic flatpak
generous-apricotOP•2y ago
Hmm, good point. I'll have to install flatpak though, which will take a while because rural internet exists.
I'll start the setup on that right away.
ratty-blush•2y ago
you won't have the game there, but you can import it so you don't have to download it at least
generous-apricotOP•2y ago
Yeah that's easy enough. Most of my storage is SSD so moving files around is plenty fast.
Before I do that, I'm going to give Wine-GE-Proton a shot just in case it is a WINE bug that plays off my specific system configuration.
Nothing on this. Starting the flatpak download now.
Just tried this. Still no luck.
---------------------------------------------------
UPDATE: (NOT) SOLVED
I have no idea why this worked. But booting using Proton 7.0 with
vcrun2019
, d3dcompiler_47
and d3dcompiler_43
via Winetricks allowed the initial circle at the loading screen to finish before it locked up.
Without wiping the wineprefix, I switched to Proton 8.0 and started the game again. To my shock, it launched without issue and I made it through the intro cutscene without any problems.
Marking this as solved. Thanks to everyone who contributed for their help.
----------------------------------------------------
UPDATE 2: BACK TO SQUARE ONE (almost)
I thought it was working great. Then I quit the game.
And we're back to square one. No dice yet again.
I'm going to test and see whether or not the above solution is consistent (nuke wineprefix -> reinstall DLLs -> boot in Proton 7.0 -> boot in Proton 8.0) and if so build a script to automate it, with a symlink for the savedata. It's a messy solution, but if it works then so be it.fascinating-indigo•2y ago
I think I know the answer looking at your log:
"winePrefix": "/home/Data/Games/Heroic/prefixes/HorizonZeroDawn",but your home folder is
/home/Lord_Berg/
which means you set up your mount point to be in /home/
as opposed to the more standard /mnt
. your prefix folder is not within the default permissible folders provided by the Flatpak Heroic
you really should fix your mount pointratty-blush•2y ago
this issue was happening without using flatpak though
one comment on this, if it works with Proton 7, maybe just keep using Proton 7? or is there anything you need from Proton 8 specifically?
generous-apricotOP•2y ago
I'm not using Flatpak at the moment.
It doesn't boot repeatedly with Proton 7, which is odd. It got past the usual point and hung - but then switching to Proton 8 got a full launch.
More progress. Switching to Proton Experimental and setting a few environment variables fixed the malloc() issue; VKD3D is now reporting a failure to allocate GPU memory in the log:
0128:warn:vkd3d_allocate_device_memory: Memory allocation failed, falling back to system memory.
This lines up with what I've seen elsewhere - Titanfall 2 can't detect any vRAM when opened through Steam Proton.
Thoughts?fascinating-indigo•2y ago
Sorry misread the log. Carry on
generous-apricotOP•2y ago

generous-apricotOP•2y ago
generous-apricotOP•2y ago
continuing-cyan•2y ago
fwiw this game works for me out of the box in steam
generous-apricotOP•2y ago
That's what confuses me. There shouldn't be that much of a difference between it and GOG.
Even launching it directly through Steam as a non-Steam game hasn't worked though.
I don't think it qualifies as piracy since you're not sharing the game itself - any chance you'd be willing to share a copy of your Proton prefix so I can rule that out?
continuing-cyan•2y ago
yeah i wouldnt expect that to work with steam like that
launching through steam doesnt go thruogh the same path as a steam native game
generous-apricotOP•2y ago
Yeah I figured. They seem to have install scripts for most games that do some basic prefix setup. Though it doesn't always work; I had to use a modded version of Origin to even start the Mass Effect trilogy.
continuing-cyan•2y ago
you have a lot going on in your settings.. i assume its all been started from a blank slate?
generous-apricotOP•2y ago
Yep. Started from 0 and worked my way up.
Most are recommendations from the ProtonDB. The OpenSSL variable is from Gog's storefront; it corrects for faulty code being handled poorly on 10th gen Intel CPUs. And then there's PROTON_LOG for the logging.
None of them have any effect on the launch from what I can tell.
There's no discernible difference between either Proton's or Heroic's log beyond the notes that the variables are set/unset.
-----------------------------------------------------------------
CURRENT STATUS
It seems the malloc() issue relates to vkd3d not being able to allocate GPU memory - an indicator that the GPU has run out of vRAM.
This makes zero sense. I can see the application has access to my GPU; vRAM usage climbs in Nvidia Settings as the game starts. But it ends at around 2400MB total allocated. From a hardware standpoint, this makes little sense. I have a 3070ti - there is more than enough vRAM to go around, and other games such as Monster Hunter World have no issue using up all of it.
The log ends with three of the same
vkd3d
errors: vkd3d_allocate_device_memory: Memory allocation failed, falling back to system memory.
So it has something to do with being denied memory access.generous-apricotOP•2y ago
generous-apricotOP•2y ago
I'm using Proton as opposed to Wine-GE because I managed to get the game to launch once with it. I've been unable to replicate this since, despite copying exactly what I did previously. I've also found that the Proton log itself is surprisingly more verbose than the Wine-GE output.
continuing-cyan•2y ago
ime memory problems could be physical, fwiw
i've had my share of nvidia cards have faulty memory
but it usually manifests as weird patterns and noise in the image
generous-apricotOP•2y ago
Yeah, I've seen nothing of the sort. Everything else works as expected, and my machine doubles as a workstation for modelling, rendering, CAD et cetera. Something else besides this would show up if the memory was faulty.
I've tested other games throughout to make sure that other Heroic-installed titles still work, my system as a whole is functional et cetera. But still, no luck.
continuing-cyan•2y ago
yeah in those cases the gpu did work in other cases too 😄
generous-apricotOP•2y ago
Huh; that's quite odd.
Is it worth running a few benchmarks to see if anything comes up - maybe an overnight stress test?
continuing-cyan•2y ago
possibly at least to rule out likeliness
generous-apricotOP•2y ago
Any recommendations for Linux? Or just Unigine Heaven through Wine/Proton?
Going to call it a night; I may keep working on it tomorrow.
continuing-cyan•2y ago
looks like lutris installs mfc140.. out of curiosity have you tried lutris? does it work there?
generous-apricotOP•2y ago
----------------------------------------------------------
FINAL UPDATE: PERMANENTLY SOLVED
Wow. Looks like WINE has been working perfectly the whole time; I could have ignored all those errors in the log.
https://steamcommunity.com/app/1151640/discussions/0/2791621875943055269/
Stumbled on this thread from Steam; apparently HZD hated USB DACs on launch and still does.
Unplugging my Fiio M3 Pro (set to DAC mode) causes the game to launch flawlessly. Plug it back in? Freeze.
This is easily reproducible. It also nicely explains why I was able to get it to launch once - the DAC hibernated while I was debugging and then woke up after the game started.
tl;dr: I spent 12 hours of my life debugging Vulkan calls and fixing warnings instead of unplugging an audio output
Crash on startup! :: Horizon Zero Dawn™ Complete Edition General Di...
So basically, the game opens, goes into a black loading screen with the loading icon in the bottom left corner, and then I get this. "Error. Unfortunately, the game has crashed. Do you want to help us fix the issue by sending a crash report?". I've tried everything from updating drivers, turning off steam overlay, running as administrator, etc e...
generous-apricotOP•2y ago
Tried it and no dice. Found the completely unexpected solution though lmao
It's past midnight and I'm going to bed. I'll see what I can do about using the DAC tomorrow.
continuing-cyan•2y ago
ah i've seen usb DACs like that cause other system issues in linux, so perhaps there's a bug with a particular chipset or the systems surrounding it
generous-apricotOP•2y ago
Yeah, that's a problem for another day though. Thanks again for your help.
continuing-cyan•2y ago
makes me wonder if the dac tries to claim a DMA address used by the GPU or something haha 🤔 since it manifested as malloc issues
anyway later!