Bug? Having two monitor connected (X11) causes initial stutter when opening steam

Hello!

I noticed a minor annoyance and I’m not sure where the issue really is.
I first thought it was a wine/proton problem but I’m not so sure since it also happens when starting steam.

When I launch the steam client, wine apps or proton games, the mouse pointer stutters for a few seconds. Disabling the second monitor does not mitigate the issue. The only way get rid of the stutter, is to disconnect the monitor display cable so the monitor isn’t “visible” in X11 at all.

Since I only have an Nvidia card I can not test if it happens with intel or AMD…

It does not happen in Wayland,. only X11. I know at least 2 more people having the same symptoms, so it’s not only a problem that I have.

I created a bug report over at WineHQ as well, WineHQ Bugzilla – Bug 56098 – Mouse pointer lags when using two monitors in X11

You’re not alone, I have this issue as well. It seems there might be some vsyncing issues with X11 (and XWayland) which seems to become worse with any Vulkan application running with vsync enabled see:

Other users in this thread also mentioned similar issues with X11:

Maybe some of the steps suggested by the moderators might help?

I experience this and sometimes it even extends to a full freeze of the second monitor; thus I’m not sure if it’s the same issue (see also External monitor freezes when using dedicated GPU). I also thought it was wine, then i realised steam would stutter, too.

It might still be wine, steam launches wine/proton tasks when it’s started, don’t asky me why tho’.
All points to wine but the real root cause is unkown really because why does the stutter stop if I physically disconnect the monitor cable? So… wine, NV driver or Xorg issuee? I have no idea.

Try running __NV_PRIME_RENDER_OFFLOAD=1 __GLX_VENDOR_LIBRARY_NAME=nvidia glxgears on the external display and resize the window a bunch of times; if you get stutters and freezes then maybe we’re looking at the same bug.

My issue is that when a secondary monitor is connected, the mouse pointer stutters bit when starting steam, same goes for any wine/proton related application.
Disabling the secondary screen with software xrandr/kde/gnome before starting any of wine based app/game does not fix the issue, you have to physically disconnect it.

Experiencing this as well. This seems to be a problem with NVIDIA’s RandR implementation, as disabling Wine’s use of RandR via the registry eliminates the stutters for me when launching apps in Wine. The severity and presence of the stutter does seem to be related to the monitors connected. Disconnecting my primary monitor (an ASUS VX228 connected via DisplayPort->HDMI) and only having my secondary monitor connected (an Acer X203W connected via DisplayPort->DVI-D) significantly reduces the length of each stutter but does not eliminate it. Doing the opposite seems to only slightly reduce the length of each stutter.

A minimal repro:

for i in {1..10}; do xrandr; done

nvidia-bug-report.log.gz (1006.2 KB)

2 Likes

Wow, impressive find, I’ve really tried to find out why it happens.

Update, I set UseXRandR to N and UseXVidMode to Y in the registry and the stutter seems to be gone.

Nvidia, please open a ticket for this.

I think I may be having a similar issue Weird DE Lag in KDE with X 550.1.54.14-1, Refresh rate drops with other drivers and in wayland

Hi @shelter
Please share nvidia bug report from repro state and also confirm the last passing driver where you did not observe this issue.
It would be good to know if repro rate is 100% or intermittent.

Hi @amrits
I think you have everything you need in @IntriguingTiles comment above.
It’s been like this since at last driver 535, I don’t remember how 515 and 525 was.
It’s easy to reproduce, have 2 monitors connected, start steam, move the mouse while steam is started and do that for 10 seconds, notice the mouse pointer stutter. Or start a game from steam, do the same thing (move the mouse). or start a wine application.

I can provide an nvidia bug report later.

@amrits
nvidia-bug-report.log.gz (1.2 MB)