doitsujin / dxvk

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

[d3d11] Zenless Zone Zero Zooting Ze VRAM #4118

Open cybik opened 2 weeks ago

cybik commented 2 weeks ago

Zenless Zone Zero (not a Steam-published game but hey) seems to be suffering from a VRAM leak. Whether it's from upstream or a DXVK quirk, I can't be sure, but Windows players seem to be unaffected, or at least affected far more slowly. Comparatively, there have been numerous reports of both AMD/ATI and nVidia users getting game crashes 30 minutes to an hour into a gameplay session. I myself have been suffering these slowdowns, so much so that at the mere HINT of frames being dropped, I close the game and restart it to be able to play another relatively stable bout of 30 minutes.

Before anyone wonders about the issue title, I was trying to go for maximum alliteration. Basically, ZZZ is "oversubscribing" the VRAM and it seems as if it's assuming more memory is available than there is. Could be due to some DX11 APIs related to resource loading that have implementation quirks, i dunno.

Software information

Game: Zenless Zone Zero Type: ARPG (Gacha, F2P - can be installed without paying) Core Engine: Unity 2019.4.40 (ultra-customized, most likely) Settings: High on everything. (No ultra available) Resolution: 3840x1600 (ultrawide 21:9)

System information

Apitrace file(s)

Log files

doitsujin commented 2 weeks ago

Unity Engine games are kinda known to load all resources into VRAM regardless of the GPU in use, this is generally not a leak, just the game asking us to put 20GB of data into far less available memory. DXVK_HUD=memory should show this too.

DXVK's memory management also cannot be improved due to some fundamental design flaws, we've been over this.

cybik commented 2 weeks ago

Fair point, but usually DXVK itself doesn't come close to the VRAM limit. For that matter, the game looks like it's averaging at 5.5~gb (for now), with occasional peaks that then go down after a bit (when they're not crashing the system). I'm guessing that everything else running in the background (composition, accelerated desktop, etc) takes precious resources away from DXVK, but still.

Is there an obvious way to mitigate this issue and limit the total allowed vidmem heap that I'm missing, or is this another one of these "can't be solved unless/until the dev stops being rude to memory" issues (which, per your statement, it certainly might be)?

SysError99 commented 1 week ago

I cannot run the game above 720p due to this issue. The game always shoots up VRAM usage above 3.5 GB on my 970.

RyuKay24 commented 2 days ago

Me neither, blows up to 60% of my vram on my 3070ti xd so 8gig gpu's are out of the question.