Bug 80933 - Fullscreen OpenGL programs (e.g. games) crash if focus lost then regained, something to do with automatic compositing suspension
Summary: Fullscreen OpenGL programs (e.g. games) crash if focus lost then regained, so...
Status: RESOLVED INVALID
Alias: None
Product: Mesa
Classification: Unclassified
Component: Other (show other bugs)
Version: 10.2
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: mesa-dev
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-07-05 00:53 UTC by Nicholas O'Connor
Modified: 2018-03-08 03:18 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Nicholas O'Connor 2014-07-05 00:53:08 UTC
See also: https://github.com/ValveSoftware/Dota-2/issues/886

Yes, the above link is specific to Dota 2, though I've found that I have the exact same problem with all other *fullscreen* programs (including Flash and Silverlight plugins running in Wine/Pipelight): namely, if the program loses focus for whatever reason (something appears in front of it, I use my Alt-Tab window switch hotkey, et cetera), then occasionally when I return to the program in question, it crashes.

The problem seems to be related to compositing window managers and the feature they have to automatically suspend compositing. Disabling compositing, as well as disabling the automatic suspension feature, causes the problem to cease. And due to the nature of the feature in question, running the game in "window mode" also avoids the problem.

Having redirected both stderr and stdout to a log file in the case of Civilization V, no error message seems to be present when the crash occurs. Silverlight in Wine/Pipelight brings up a mockup of the Windows "Program has encountered an error" dialog, so I suspect Linux native programs merely segfault or something equally unhelpful in troubleshooting. :V

I believe this is a bug within Mesa, and not my drivers or window manager, because the above link shows the problem occuring across multiple driver and WM combinations (and my own tests have ruled out the possibility of it being a bug in the specific program). With KDE/KWin, the workaround is painless - if you disable the automatic suspension feature in the advanced tab of its "Desktop Effects" page, the problem ceases and you can forget it was ever a problem to begin with. I am unsure of the instructions for other window managers, but I would imagine they have a similar checkbox stashed away somewhere, or you can of course disable compositing entirely if you prefer.
Comment 1 almos 2014-07-05 14:06:35 UTC
I believe this has nothing to do with Mesa, because all commenters on github use closed (nvidia and amd) drivers. BTW I'm using Mesa 10.1.4 with KDE4, compositing is disabled for fullscreen windows, and I have no problems with fullscreen applications.
Comment 2 Michel Dänzer 2014-07-09 03:01:05 UTC
We'll need to see a backtrace of an application crash, with symbols for as many entries of the backtrace as possible.
Comment 3 Benjamin Bellec 2014-07-09 18:37:33 UTC
(In reply to comment #0)
> See also: https://github.com/ValveSoftware/Dota-2/issues/886

In this thread, all the bugs reports have been done with a proprietary driver (NVIDIA mostly, and also AMD).
Comment 4 Timothy Arceri 2018-03-08 03:18:28 UTC
I suspect the reporter might be misunderstanding what Mesa is.

"I believe this is a bug within Mesa, and not my drivers ... "

As per the other comments it seems like the reporter might have been using a closed driver. Closing.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.