New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nvidia driver discussion #267

Open
zaps166 opened this Issue Apr 10, 2018 · 239 comments

Comments

Projects
None yet
@zaps166

zaps166 commented Apr 10, 2018

Nvidia introduced new Vulkan SPIR-V compiler. Games using DXVK runs very slow with it (it can be disabled by using __GL_NextGenCompiler envvar).

Comparision [3840x2160, new vs old, disabled by envvar]:

  • Tomb Raider 2013 main menu (ultra, but without tesselation): [7 FPS vs 40 FPS]
  • NieR:Automata (some scene, full details, anti-aliasing off): [14.5 FPS vs 24 FPS]
  • Sword Art Online Hollow Realization (Teleport Gate Plaza, full details, anti-aliasing off): [13 FPS vs 45 FPS]

Moreover:

  • Tomb Raider 2013 scene with tesselation enabled is black (on old nvidia shader compiler graphics is corrupted, but visible)
  • Sword Art Online Fatal Bullet scene is also black
  • No performance difference on Unigine Heaven (DXVK) and Vulkan Examples (native Linux)

System information

  • GPU: GeForce GTX 1080
  • Driver: 396.18
  • Wine version: 3.5
  • DXVK version: 41132b8
  • X11 Compositor: none/disabled
  • Nvidia Force Composition Pipeline: enabled
  • UseNvKmsCompositionPipeline: false

@doitsujin doitsujin added the nvidia label Apr 10, 2018

@doitsujin

This comment has been minimized.

Owner

doitsujin commented Apr 10, 2018

Well, the new compiler doesn't seem to be mature yet, don't use it for gaming with DXVK. Gathering some feedback might help them improve it though, and maybe uncover some new bugs in DXVK.

As for Tessellation in Tomb Raider 2013 not working properly, that is a DXVK bug I think.

@pdaniell-nv Could you keep an eye on this thread as well?

@pdaniell-nv

This comment has been minimized.

pdaniell-nv commented Apr 10, 2018

Thanks for the heads up. I'll report back when I know more.

@xpander69

This comment has been minimized.

xpander69 commented Apr 10, 2018

Confirming its slow. GTA V usual 60-90FPS went to 20-35 FPS
Fixes GTA V sun issue though

396.18 with __GL_NextGenCompiler=1
ss_10042018_23 03 48

396.18 with __GL_NextGenCompiler=0
ss_10042018_23 06 47

Crysis 2 Tesselation got broken and performance went down

396.18 with __GL_NextGenCompiler=1
ss_10042018_23 21 15

396.18 with __GL_NextGenCompiler=0
ss_10042018_23 24 26

@vesim987

This comment has been minimized.

Contributor

vesim987 commented Apr 10, 2018

@pdaniell-nv
There is example from The Witcher 3: https://streamable.com/0zgjl it is approximately 1/3 of performance of the old compiler.
Disabling Hull and Domain Shaders bumps up performance twice.
witcher_3_wo_tess

@pingubot

This comment has been minimized.

pingubot commented Apr 10, 2018

Hi,

here are the issues i noticed so far:

My Card: GTX 970
Driver: 396.18

Crysis2:

  • Tesselation is broken, see pictures of XPander
  • Performance is minimum cut into half (gpu is fully loaded all the time)

Crysis3:

  • Performance is minimum cut into half (gpu is fully loaded all the time)
  • Didn't notice huge display issues yet, need to check

Battlefield Bad Company 2:

  • I can enable MSAA now which crashes the game before
  • Performance is 30% of the old driver and gpu load increased from ~60% to 100%
  • Graphical issue, file attached:
  • Enabling MSAA fixes those graphical issues
    bildschirmfoto von 2018-04-10 20-00-52

Battlefield 3:

  • I can enable MSAA now which crashed the driver before
  • Without MSAA the performance is unaffacted with the new driver. With MSAA 2x enabled the per is cut down to 30%, from ~ 100fps to ~30fps.

Far Cry 3:

  • I can enable MSAA now which crashed the driver before
  • Without MSAA the performance is unaffacted with the new driver. With MSAA 2x enabled the perf is cut down to ~36fps, from ~ 56fps.

Diablo 3:

  • I can enable MSAA now which crashed the driver instntly before. But it is still not usable due to game freezes
  • Performance is ~ 30 fps in the menu, was >100 fps before with MSAA disabled

Unigine Heaven.

  • Doesn't launch for me anymore with Tesselation on, works with tesselation off
  • No graphical issues detected so far, but was a super quick test

Many thanks !
Christian

@doitsujin

This comment has been minimized.

Owner

doitsujin commented Apr 10, 2018

It should be noted that not all of the games @pingubot mentioned are well-tested and some of them have known issues. I think only Crysis 2 and Unigine Heaven are expected to work properly.

@pingubot

This comment has been minimized.

pingubot commented Apr 10, 2018

I haven't played all the games from beginning to the end (i did that for crysis 2, also a few hours into crysis 3, for the rest it is really less than 1 hour per game), but the things i mentioned are the things that have changed between the new and the old nvidia driver spirv compiler. So it is just to show the differences.

@pdaniell-nv

This comment has been minimized.

pdaniell-nv commented Apr 10, 2018

@doitsujin Are there any SPIR-V work arounds in place for our old compiler? If so, they probably need to be removed for the new compiler in 396.18 and beyond.

@doitsujin

This comment has been minimized.

Owner

doitsujin commented Apr 10, 2018

@pdaniell-nv the only Nvidia-specific workaround in my compiler is adding an extra component to the coordinate vector for the OpImageSampleDref* instructions, which is legal in SPIR-V and doesn't actually seem to cause any issues with the new compiler.

With the exception of the aforementioned workaround, as well as GPUs which do not support the ShaderImageReadWithoutFormat capability, it generates the same code for all GPUs.

@pingubot What I'm trying to say is that you might simply be hitting undefined behaviour in some cases, which just happened to work for some reason with the old compiler.

@pdaniell-nv

This comment has been minimized.

pdaniell-nv commented Apr 10, 2018

Ok, thanks. We're looking into the functionality and performance regressions described above.

@SveSop

This comment has been minimized.

Contributor

SveSop commented Apr 11, 2018

Using __GL_NextGenCompiler=1 (default) causes some sort of "black/green'ish" picture in Unigine benchmarks. This is with commit: 140dc27
On the other hand, there was a change vs. previous in Unigine Superposition with the setting __GL_NextGenCompiler=0 when it comes to lightreflections.. (Did not start with default =1 setting)
00000

@pchome

This comment has been minimized.

Contributor

pchome commented Apr 12, 2018

TW3:

  • CPU usage: ~18%
  • GPU usage: 100%
  • Inverted colors (yellow == green)
  • Texture glitches
  • low fps (1/3, due to low cpu usage ?)
  • log diff:
    old : warn: D3D11Device: No matching border color found for (1e+10,1e+10,1e+10,1e+10)
    new: warn: D3D11Device: No matching border color found for (1e+010,1e+010,1e+010,1e+010)
@pchome

This comment has been minimized.

Contributor

pchome commented Apr 12, 2018

As an opposite effect to bugs in other games/applications I can report Just Cause 3 runs without issues (except green color dominated) now.

This is for wine-staging, game was launched from steam menu, no other settings touched.
Without DXVK it fully unplayable, a lot of glitches and missing textures.

@dmitry64

This comment has been minimized.

dmitry64 commented Apr 12, 2018

Tested Dark Souls 2 and Dark Souls 3 on this commit: adb1789.
Both games now have inverted colors (yellow is now green) with __GL_NextGenCompiler=1. With old compiler colors are normal.

UPDATE: On the latest commit 8dfe708 color issues are gone (with new compiler). Or maybe it was just a glitch.

On my GTX 970 with 396.18 driver, with 1440p resolution, wine 3.5, on low settings Dark Souls 3 is playable at 40-55 FPS. If i enable shadows in graphics settings (Off->Low) performance drops to 1-2 FPS.

@nairaner

This comment has been minimized.

nairaner commented Apr 14, 2018

With new compiler Path of Exile crash while loading with:
NVRM: Xid (PCI:0000:01:00): 8, Channel 0000006a
Setting __GL_NextGenCompiler=0 makes the game work
Using DXVK: 8dfe708
PathOfExile_x64_d3d11.log
PathOfExile_x64_dxgi.log
shaders.zip

@pingubot

This comment has been minimized.

pingubot commented Apr 15, 2018

Want to add FEAR 3 to the list of affected games:
All game settings at max, 1920x1080, MSAAx 4. GPU load is 100% with the new and with the old compiler:

Driver 396.18:

New Compiler: 9 fps
Old Compiler: 63 fps

Disabling MSAA leads to:

New Compiler: ~ 35fps
Old Compiler: ~ 150fps

Many thanks !
Christian

@Glog78

This comment has been minimized.

Glog78 commented Apr 15, 2018

Want to add Skyrim SE to the list of affected games:

New Compiler = 3.5 to 5 fps
Old Compiler = 60+ fps (vsync on)

Settings have no influence at all on the bad performance of the New Compiler.

@tpruzina

This comment has been minimized.

tpruzina commented Apr 16, 2018

I suggest using __GL_NextGenCompiler=0 until this gets resolved (presumably upstream problem).

@pingubot

This comment has been minimized.

pingubot commented Apr 17, 2018

Want to add Dirt 2 demo to the list:

Old Compiler: No graphical issues, ca. 100fps in menu outside
New Comppiler: ~ 15fps in menu outisde and those funky pictures:

bildschirmfoto von 2018-04-17 20-41-32

@pdaniell-nv

This comment has been minimized.

pdaniell-nv commented Apr 17, 2018

Thanks for all the reports posted here on our 396.18 driver. We have just released a new 396.18.02 beta driver on our Vulkan driver page here: https://developer.nvidia.com/vulkan-driver

This should resolve some of the performance and corruption issues reported. As an added bonus this driver also increases the number of UBOs allowed per shader stage from 12 to 15 as discussed in issue #90.

We look forward to hearing feedback on the new 396.18.02 driver. Thanks!

@varris1

This comment has been minimized.

Contributor

varris1 commented Apr 17, 2018

Driver version: 396.18.02
DXVK: b82ae16
Card: GTX 970

This is what Overwatch via DXVK (b82ae16) looks like with:
__GL_NextGenCompiler=1
https://imgur.com/a/eNRnK

__GL_NextGenCompiler=0
https://imgur.com/a/9Knko

So it seems like there is still some corruption going on.

EDIT: fixed with commit 5eaacf7

@varris1

This comment has been minimized.

Contributor

varris1 commented Apr 17, 2018

Driver version: 396.18.02
DXVK: 05a96e9
Card: GTX 970

This Unity engine demo seems to have issues with corruption as well:
https://blogs.unity3d.com/en/2015/06/24/releasing-the-blacksmith/

__GL_NextGenCompiler=1:
https://imgur.com/a/9xfhs

__GL_NextGenCompiler=0:
https://imgur.com/a/mZKTi

EDIT: fixed with commit 5eaacf7

@sambow23

This comment has been minimized.

sambow23 commented Apr 17, 2018

Driver: 396.18.02
DXVK: 05a96e9
GPU: GTX 1060 6GB

The performance issues on GTAV with __GL_NextGenCompiler=1 are fixed, but with the maximum settings, this line exists onscreen
image

This does not happen with __GL_NextGenCompiler=0
image

@pdaniell-nv

This comment has been minimized.

pdaniell-nv commented Apr 18, 2018

For the issue with the Unity engine demo that @varris1 reported, it appears the SPIR-V is invalid in at least one of the shaders. In one of them there is this:

        %84 = OpFAdd %v3float %79 %83
        %85 = OpLoad %float %o0
        %86 = OpVectorShuffle %float %85 %84
              OpStore %o0 %86

In this example %o0 is actually a pointer to v4float and the OpVectorShuffle should have be used with vector types. So some kind of scalar/vector mixup going on. Actually the spir-v validator catches the OpLoad type mismatch above, but not the OpVectorShuffle issue.

@doitsujin

This comment has been minimized.

Owner

doitsujin commented Apr 18, 2018

@pdaniell-nv what are the settings that generate the invalid shader? Just tested with Higher and I'm not getting spirv-val errors on any of the spir-v shaders.

Edit: Not getting any errors with the other presets either.

@Tk-Glitch

This comment has been minimized.

Contributor

Tk-Glitch commented Oct 11, 2018

@kakra It has been benchmarked by other people already, on multiple games. 410.57 was consistently slower. Also, the min framerates on Heaven/Valley can't be relied on at all.

@ryao

This comment has been minimized.

Contributor

ryao commented Oct 12, 2018

@SveSop 410.57 is not a Vulkan beta driver. The latest Vulkan beta driver is still 396.54.06. 410.57 hasn't regressed because in terms of Vulkan support, it is actually older, despite the larger version number suggesting otherwise.

@SveSop

This comment has been minimized.

Contributor

SveSop commented Oct 12, 2018

@kakra No way to do a reliable comparison of frame-dips/min/max vs. cpu usage that i know of. Some sort of profiling software perhaps? Have no clue...

Its: Avg fps (Score) min/max.
How the score is calculated i dunno.. Cos Heaven is a longer-lasting test than valley although the fps is a bit lower, the scores are almost half :)

@pedrofleck

This comment has been minimized.

pedrofleck commented Oct 13, 2018

@ryao What's the Vulkan beta driver equivalent to 410.57? For dxvk it's better stick to the final driver version or install the Vulkan beta?

@Stanzilla

This comment has been minimized.

Stanzilla commented Oct 13, 2018

Release Updates
October 14th, 2018 - Windows 399.41, Linux 396.54.09

New Extensions:
VK_EXT_external_memory_host (Windows only)
VK_EXT_transform_feedback

@jp7677

This comment has been minimized.

Contributor

jp7677 commented Oct 13, 2018

Does 396.54.09 fixes the black spots in Shadow of the Tomb Raider as shown here ValveSoftware/Proton#1417 (comment) ?

@ryao

This comment has been minimized.

Contributor

ryao commented Oct 15, 2018

@pedrofleck As far as I know, the Vulkan beta driver improvements have not been merged into that branch by Nvidia.

@kakra

This comment has been minimized.

kakra commented Oct 15, 2018

For Gentoo users, I've made an overlay for obtaining the correct driver:
https://github.com/kakra/nvidia-vulkan

@Bumbadawg

This comment has been minimized.

Bumbadawg commented Oct 22, 2018

__GL_NextGenCompiler=1
works great on Quake Champions, DXVK 0.90 and nvidia-396.54.09.

@SveSop

This comment has been minimized.

Contributor

SveSop commented Oct 22, 2018

I thought __GL_NextGenCompiler=1 was the default for newer drivers? In that "if-not-otherwise-specified-it-will-use"?

@damienleone

This comment has been minimized.

damienleone commented Oct 22, 2018

I thought __GL_NextGenCompiler=1 was the default for newer drivers? In that "if-not-otherwise-specified-it-will-use"?

Correct

@Bumbadawg

This comment has been minimized.

Bumbadawg commented Oct 23, 2018

I thought __GL_NextGenCompiler=1 was the default for newer drivers? In that "if-not-otherwise-specified-it-will-use"?

Indeed, my bad.
https://www.gamingonlinux.com/articles/nvidia-39618-beta-driver-is-out-with-a-new-vulkan-spir-v-compiler-to-reduce-shader-compilation-time.11568

@mrdeathjr28

This comment has been minimized.

mrdeathjr28 commented Oct 25, 2018

Nvidia Drivers 410.73 Released

https://www.nvidia.com/download/driverResults.aspx/139110/en-us

Added support for the following GPUs:

Quadro RTX 6000

Quadro RTX 5000

Added a USB-C display connector type identifier, such that a display connected using Turing's USB-C connector will be named, e.g., "USB-C-0" rather than "DP-5".

Scripts and configuration files that use the DP identifier for this connector will be affected.

Fixed a bug that caused vkGetPhysicalDeviceDisplayPropertiesKHR() to occasionally return incorrect values for physicalResolution.

Added the synchronization state for PRIME Displays to nvidia-settings.

According nvidia_icd.json.template (unzipped run file)

This drivers come with vulkan 1.1.82

Turing based cards aka Geforce RTX dont can use trandform feedback until nvidia release driver with vulkan 1.1.88

@varris1

This comment has been minimized.

Contributor

varris1 commented Nov 3, 2018

@pdaniell-nv

There seems to be an issue with Overwatch, DXVK and Nvidia causing a wallhack effect: (related bug report: #738)
https://streamable.com/l75oz

As I am unable to record a trace via apitrace, I had to resort to a renderdoc capture (recorded on a GTX 970 & 396.54.09 and Renderdoc v1.1)
https://mega.nz/#!O6RW0ShR!IiPHjjdm2J2D3WKRFUsW8aPlYThTSvkpZDR1Rdp7zJo

AMD users said that they haven't seen a bug like this, so it may be a bug in the Nvidia driver. Can you take a look at it?

EDIT: It seems that this issue starts to happen in EID 6499. The previous draw call (EID 6489) seems to be unaffected. The depth-only pass 4 may be of interest as well.

@linkjay

This comment has been minimized.

linkjay commented Nov 4, 2018

@varris1

Would also like to add (stated on my issue of this), this only seems to happen on the nvidia-vulkan package for arch which is version 396. Using the latest 4XX on the nvidia master branch seems to fix this issue so it seems like an issue with the nvidia drivers relating to vulkan, vulkan itself, dxvk, or some weird combo with the entire program chain.

@varris1

This comment has been minimized.

Contributor

varris1 commented Nov 4, 2018

You sure? I just tested 410.73 and it happened there as well.
screenshot

@kakra

This comment has been minimized.

kakra commented Nov 4, 2018

Similar effects can also be seen in The Witcher 3, it looks like you see outlines of lakes and water from inside of caves.

@tannisroot

This comment has been minimized.

tannisroot commented Nov 5, 2018

@kakra can you make a screenshot of that + an apitrace?

@kakra

This comment has been minimized.

kakra commented Nov 5, 2018

@tannisroot I can do a screenshot but not sure how to do an apitrace... I don't have a Windows machine here to do an apitrace. I think that's needed?

@tannisroot

This comment has been minimized.

tannisroot commented Nov 5, 2018

@kakra you need to put the x64 dlls from here https://www.dropbox.com/sh/o769ius47wpu3pw/AABYFKQFFNsCsosXhl7_HReDa?dl=0
into the same directory as game's executable, disable DXVK, and add overrides in winecfg for d3d11, dxgi and dxgitrace set to native, builtin. Then launch a game and go to that problematic location. Try to do it quickly, the .trace will that will be generated after you do that and exit the game may get huge (several gigabytes) as it grows bigger the more time you spend in game.

@tannisroot

This comment has been minimized.

tannisroot commented Nov 5, 2018

@kakra also, is there a specific spot where it happens?

@tannisroot

This comment has been minimized.

tannisroot commented Nov 5, 2018

Also, what are your video settings?

@kakra

This comment has been minimized.

kakra commented Nov 5, 2018

@tannisroot Yes, the spot is the first Elven cave you visit with Keira, near the exit. The exit points right onto a nice lake view to Fyke Island: https://witcher3map.com/v/#6/53.961/53.617

If I'd generate this apitrace, is there a way to redirect the file to another disk? If I'll spool multiple gigabytes within a few moments to the game disk, I guess that I'm going to have a hard time (it's on btrfs, it may choke when writing multi-GB while the game is running and reading files).

Video settings are maxed out, full-HD, hairworks on for all characters (AA-4).

@doitsujin

This comment has been minimized.

Owner

doitsujin commented Nov 5, 2018

@kakra can you please upload a savegame in that location? Makes it easier to reproduce.

@kakra

This comment has been minimized.

kakra commented Nov 5, 2018

I'll try to reproduce this evening. Have to head to work now. ;-)

@kakra

This comment has been minimized.

kakra commented Nov 5, 2018

Okay, here's a screenshot, the effect is barely visible so I amended it with some green text. I also found that this exclusively occurs during bad weather. So it probably doesn't result from rendering outlines of lakes (and revisiting the issue, it also doesn't match the geometry of the lake):

screenshot_20181105_205855

Saved game:
issue-267.zip

@pchome

This comment has been minimized.

Contributor

pchome commented Nov 6, 2018

Probably the same issue: while inside a building, sun rays can be seen through the closed door. But this depends on the distance, everything is normal while you staying close enough to the closed door.
Noticed in Toussaint.

@infoman

This comment has been minimized.

infoman commented Nov 14, 2018

MTG Arena and Hearthstone both fail with GetThreadContext failed on 415.13-0ubuntu0~gpu18.04.1 (from Ubuntu's graphics-drivers ppa). Rollback to 410.73 makes them work again.

@Vash63

This comment has been minimized.

Vash63 commented Nov 14, 2018

MTG Arena and Hearthstone both fail with GetThreadContext failed on 415.13-0ubuntu0~gpu18.04.1 (from Ubuntu's graphics-drivers ppa). Rollback to 410.73 makes them work again.

I can duplicate this issue in Beat Saber and Cuphead - both Unity games, even when using the oldest versions of DXVK included with Proton. This is on Arch. I need to do some further testing later tonight but this also might be causing a failure to load in CryEngine games.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment