DirectX12 performance is terrible on Linux

Fun fact… or rather, interesting fact perhaps.
I tried vkd3d-proton under Windows with Control (RT on)… The performance is ~ the same as Linux… At least when it’s comes to that game,

So in this specific case I don’t think it’s the Linux drivers fault really… which makes me wonder where the problem really lies.

3 Likes

That is interesting. OP mentioned that:

" DXVK and VKD3D developers have acknowledged this and they can’t do much about it due to the driver’s closed source nature. They can’t tell how exactly it works behind the scenes."

It is quite possible that, aside from some of the possible power state/vram performance related issues, that there are limitations related to the fact that the devs don’t have the same visibility to driver code.

In that case you would need some type of cooperation between the devs.

2 Likes

fwiw, once I limit vram via dxvk.conf is on par with what I would expect given I upgraded from a 6950xt to a 4080 super … if I get some time I will try playing in windows and see what performance is like on the same pc

1 Like

Worth mentioning is that the limit is not a hard limit tho’, some games might decide to go above it anyway.

1 Like

that is true, 14GB (or sometimes 13GB) just seems to be the sweet spot for me to keep total use below 16GB, I still frequently see 15+GB usage when switching scenes, it eventually goes back to the limit though from what I have seen

1 Like

Did a quick test with the black myth benchmark, vkd3d-proton performance in Windows is worse than DX12.
And again, vkd3d-proton performance Windows vs Linux is roughly the same…

So I don’t really “blame” the Linux drivers alone anymore, it’s something else that’s causing it.
Nvidia added VK_NV_raw_access_chains (with help from the vkd3d-proton dev i believe) which improved things for some games.
I don’t know what’s happening behind the scenes but they got to figure it out…

3 Likes

Raw access chains ext should improve gpu bound perf in DXBC games, not DXIL. Which means most DX11 games and early DX12 games and DX12 games that uses older revisions of UE4 etc. Such as Lies of P etc as that game is DXBC.

3 Likes

@esullivan sorry for the ping, it’s a onetimer.
But there’s an obvious bottleneck when using vkd3d-proton in both Linux and Windows.
You know this, perhaps you also know why. But if you can, have a look at it, perhaps collaborate with the vkd3d-proton devs.

Thank you

6 Likes

Space Marine 2 Run 30% Worst , sadly it doesn’t have directx 11 rendered path , i heard amd is not suffering from this issue .

to update on this issue , Stormgate DX11 works as good as windows , however Dx12 also suffering from performance regression by around 25% comparing to windows .

1 Like

So I’ve done some more testing here which kind of confirms my findings.
Native Vulkan runs fine, better or on par with Windows
DXVK (DX11 titles) runs ~the same as in Windows.
vkd3d-proton got a performance hit in both Windows and Linux, up to 30%

2 Likes

We see different numbers of fps loss, depending on the resolution atm. That is why we see 50% 30% and on. Where 1080p users will see a bigger loss in fps, then one in 1440p or 4k. Its comes down to the head room of the total fps of the resolution, and how demanding it is on the card. It also depends if you run RT or not, where RT can kill the game, with the 50% fps loss.

I was testing between CachyOs Arch Linux and Windows 11 23H2 with the KB patch that fixed some of the fps issues around CI today.

Space Marine 2 in linux was around 80-110ish fps at max. Where windows starts at 154-180ish fps. Same setting, same resolution 3840x2160. This is also very noticable on an 138hz 42" oled screen. When I hit the 138hz, and can maintain 138 fps, the game just blast off in the smoothness. Where under, its responsive, but still, its not that smooth comparing em. Its a different experience. Frame time, seems pretty ok in Linux. But still, Its a major fps loss.

This is pretty much the same problem as we saw in Wukong.

Problem here, is when you need the fps in 4k resolution, even on my 4090, I get pretty much the same performance in windows as i was running a 4070ti. That is not much fun, when you pay the price of a high end card.

The lucky part that linux gets away with here, its what all linux people say, its playable. Because I can run it over 60 fps. This was not the case in Wukong, that is more demanding. I could not maintain 60 fps, and ended down in the 45fps in 4k. That was not playable at all. It worked, but was not enjoyable at all.

This is a typical syndrom that we see, where people say things are working, but is it working good? Then they have not touched windows, then think the game should run like that. Most people are running either 1080p and 1440p, where the can somewhat get away with the issues. But more the demanding side of the AAA titles get, the more issues we see.

2 Likes

Alienware M18R2 4090 / i9 14900HX

2560x1440 / DLSS Quality / No FG / All settings maxed except PNJ on low.

Windows :

Linux :

At least the FPS are stable…

3 Likes

This needs more Attention. Is NVIDIA investigating this?

Just out of curiosity, does this impact people who are using new NVIDIA Open Kernel Module the same as the original proprietary one when using the latest drivers?

The reason I ask is that the proprietary module limits VRAM usage entirely to that of what the graphics card has, which is something the AMD driver does not, and is also not a limitation on Windows with NVIDIA drivers either.

If I remember rightly, HMM support landed for the Open Kernel Module which would allow non-game processes to have their memory allocations shoved into system RAM (just like with AMD) which might restore some of the performance…

1 Like

Same perf Open Kernel Module VS Closed

That sounds like the problem I see with diablo 4 where I need to limit vgpu memory to 13G even though the card has 16G.

Sure, games suffer if they overallocate vram, even on windows really, but that’s really not the core issue.

The core issue is vkd3d-performance, which is roughly the same in windows if you try it there (install dxvk, vkd3d-proton and dxvk-nvapi and set env properly)
Obivously vkd3d-proton performs pretty much fine with AMD and if the vkd3d-proton devs can fix the performance issue that exists with Nvidia I’m sure they would have.

I don’t know why vkd3d-proton got performance issues. Tbh, I think only Nvidia can fix it.

I say it again:
Vulkan by itself is fine
OpenGL is fine
dxvk is fine
vkd3d-proton got issues, some games however run pretty good.

4 Likes

the weird thing the dx11 render path is very very good linux , amd have no problem with dx12 render path on linux which on par with their dx11 one , nvidia suffering big issue -30% is not a small number we’re speaking about here , this is a priority issue for nvidia to fix .

2 Likes

God Of War Regnarok Perform 37% Worst on nvidia linux

99fps to 137fps , on the same pc/ same settings / different OS .

PROTON_HIDE_NVIDIA_GPU=1 %command% works wonders as workaround in several DX12 games like FFXVI and Dragon’s Dogma 2, for example. It’s very impressive in some areas, like the second village in FFXVI where you arrive at night. The FPS is doubled, and the framerate is much more stable.

Using the command PROTON_HIDE_NVIDIA_GPU=1 %command% significantly improves performance and stability in several DirectX 12 games, like Final Fantasy XVI and Dragon’s Dogma 2, on Linux with my Nvidia card. However, this command also disables Nvidia-specific features like DLSS and Reflex. Even when manually turning off those options in settings, I couldn’t achieve the same performance boost.

I’ve noticed a real increase in performance, especially in areas with lots of AI, such as towns and villages. For example, in certain spots, I managed to double my FPS, although the difference is less noticeable in open fields or less populated areas. I’ve tested this command across multiple OSes, whether it’s Arch, Ubuntu, or CachyOS, and I’ve consistently had similar results, whether using GNOME or KDE.

However, we still lose about 15% to 40% of performance in DX12 games compared to Windows. This workaround simply makes the worst areas playable when they were previously unplayable.

3 Likes