Bug 40059 - [SNB] hang in "Amnesia: The Dark Descent" demo
Summary: [SNB] hang in "Amnesia: The Dark Descent" demo
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/DRI/i965 (show other bugs)
Version: 8.0
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Kenneth Graunke
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-08-13 09:39 UTC by nobled
Modified: 2012-02-28 13:12 UTC (History)
8 users (show)

See Also:
i915 platform:
i915 features:


Attachments
i915_error_state after X restart (2.14 MB, text/plain)
2011-08-13 09:39 UTC, nobled
Details
dmesg log after X restart (238.07 KB, text/plain)
2011-08-13 09:40 UTC, nobled
Details

Description nobled 2011-08-13 09:39:13 UTC
Created attachment 50183 [details]
i915_error_state after X restart

All versions are from the xorg-edgers PPA packages I installed:
Distribution: Ubuntu 11.04 amd64
kernel: 3.0.0
libdrm: 2.4.6+git20110808.2acaf160
mesa: 7.12.0~git20110811.9cd64ec3
DDX (xserver-xorg-video-intel): 2:2.15.901+git20110808.f4bbbd1d
Xorg: 2:1.10.2.902+git20110708+server-1.10-branch.bc3c539e

I hit this trying the Linux demo for Amnesia: The Dark Descent:
http://www.amnesiagame.com/#demo

I started it at its lowest settings in windowed, 640x480 mode. As soon as it starts trying to render the start-screen's background scene, the desktop session/window manager starts going crazy, as the window decorations turn white or disappear, as does the taskbar/shell at the top and bottom of the screen. (I'm running the 'Ubuntu Classic' session, so it was probably compiz.)

Nothing was responding to my clicks, my Alt+F4s, or my Ctrl+Cs (I launched Amnesia from gnome-terminal -- the "^C" would appear but nothing happened). I VT-switched with Ctrl+Alt+F1 and back again, and it threw me back to the gnome login screen. After I logged in again, only the Software Rasterizer was available according to glxinfo.

I'll attach the dmesg log, and a dump of the i915_error_state file.
Comment 1 nobled 2011-08-13 09:40:21 UTC
Created attachment 50184 [details]
dmesg log after X restart
Comment 2 nobled 2011-10-10 17:18:03 UTC
Ping--Is there any other info needed?
Comment 3 nobled 2012-01-23 11:36:06 UTC
http://www.mediafire.com/?qm7nckc1da444rc

Here's an apitrace file (with the bigger CompressedTexImage2DARB calls ripped out to cut down on size dramatically) that still reproduces the hang with mesa 5a7c3433 and kernel 3.2.0.
Comment 4 Kenneth Graunke 2012-02-21 12:16:37 UTC
This is fixed by the last render target select patch on the mailing list.  Will commit it shortly...
Comment 5 Kenneth Graunke 2012-02-21 12:40:40 UTC
Fixed on master by:

commit 172bb92db1a3c317867d9cfec6f15c09c37a0f6c
Author: Kenneth Graunke <kenneth@whitecape.org>
Date:   Sat Feb 18 21:29:29 2012 -0800

    i965: Only set Last Render Target Select on the last FB write.
    
    Fixes GPU hangs in OilRush, Trine, and Amnesia: The Dark Descent,
    which all use MRT (multiple render targets).
    
    NOTE: This is a candidate for release branches.
    
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=38720
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=40059
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=45216
    Reviewed-by: Eric Anholt <eric@anholt.net>
    Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>

Thanks for the trimmed apitrace!
Comment 6 Kenneth Graunke 2012-02-28 13:12:20 UTC
Fixed on the 8.0 branch:

commit 16cc79f975816c0741711560be48fc498d4b4794
Author: Kenneth Graunke <kenneth@whitecape.org>
Date:   Sat Feb 18 21:29:29 2012 -0800

    i965: Only set Last Render Target Select on the last FB write.
    
    Fixes GPU hangs in OilRush, Trine, and Amnesia: The Dark Descent,
    which all use MRT (multiple render targets).
    
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=38720
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=40059
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=45216
    Reviewed-by: Eric Anholt <eric@anholt.net>
    Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
    (cherry picked from commit 172bb92db1a3c317867d9cfec6f15c09c37a0f6c)


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.