Bug 79756 - [Radeon] Resizing Steam windows freezes Xorg
Summary: [Radeon] Resizing Steam windows freezes Xorg
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/Gallium/radeonsi (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Default DRI bug account
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-06-06 23:59 UTC by Marti Raudsepp
Modified: 2016-02-15 02:38 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
kernel.log (96.19 KB, text/plain)
2014-06-06 23:59 UTC, Marti Raudsepp
Details
gdm-Xorg-:0.log (91.00 KB, text/plain)
2014-06-07 00:00 UTC, Marti Raudsepp
Details
steam.desktop.log (12.64 KB, text/plain)
2014-06-07 00:01 UTC, Marti Raudsepp
Details
gdm-Xorg-:1.log (243.42 KB, text/plain)
2014-06-07 10:42 UTC, Marti Raudsepp
Details
gdb-backtrace.txt (12.20 KB, text/plain)
2014-06-11 19:38 UTC, Marti Raudsepp
Details

Description Marti Raudsepp 2014-06-06 23:59:23 UTC
Created attachment 100572 [details]
kernel.log

The gauntlet continues... After solving bug 79325, Steam now starts, but when I try to resize any Steam windows, Xorg freezes: it does not react to keyboard input (VT switching or num lock) and killing Steam doesn't unlock it. But the mouse cursor still responds to mouse movements.

There is nothing in Xorg logs after the freeze. 

xorg-server 1.15.1
linux 3.15-rc8
linux-firmware a4f3bc03f1e7b1f25cc52328981c2a35871e55a1 (with PITCAIRN_mc2.bin)
xf86-video-ati 7.3.0
Tried ati-dri/mesa versions 10.2.0rc5 as well as 10.1.3
Tried glamor-egl git a4fbc7732a1e56de385f50b778aafbdd186e015c as well as 0.6.0 (patched with cccfea4454949e3e376be42bb230603848997195 per bug 79325)

gdb dump at the time of freeze:
(gdb) thread apply all bt

Thread 2 (Thread 0x7f34a3efd700 (LWP 630)):
#0  0x00007f34ae00cb2f in pthread_cond_wait@@GLIBC_2.3.2 () from /usr/lib/libpthread.so.0
#1  0x00007f34a65679cb in ?? () from /usr/lib/xorg/modules/dri/radeonsi_dri.so
#2  0x00007f34a6567117 in ?? () from /usr/lib/xorg/modules/dri/radeonsi_dri.so
#3  0x00007f34ae008124 in start_thread () from /usr/lib/libpthread.so.0
#4  0x00007f34acd374bd in clone () from /usr/lib/libc.so.6

Thread 1 (Thread 0x7f34aeac5880 (LWP 553)):
#0  0x00007f34ae00f38c in __lll_lock_wait () from /usr/lib/libpthread.so.0
#1  0x00007f34ae00ab3c in _L_lock_553 () from /usr/lib/libpthread.so.0
#2  0x00007f34ae00a91a in pthread_mutex_lock () from /usr/lib/libpthread.so.0
#3  0x00007f34aad16fae in eglCreateImageKHR () from /usr/lib/libEGL.so.1
#4  0x00007f34aaf35e21 in glamor_egl_create_textured_pixmap () from /usr/lib/xorg/modules/libglamoregl.so
#5  0x00007f34a77e1ac0 in ?? () from /usr/lib/xorg/modules/drivers/radeon_drv.so
#6  0x00007f34a77e1e26 in ?? () from /usr/lib/xorg/modules/drivers/radeon_drv.so
#7  0x00007f34a77d8819 in ?? () from /usr/lib/xorg/modules/drivers/radeon_drv.so
#8  0x00000000005554c3 in ?? ()
#9  0x000000000055628f in ?? ()
#10 0x0000000000556690 in DRI2GetBuffersWithFormat ()
#11 0x00007f34a7c2e661 in ?? () from /usr/lib/xorg/modules/extensions/libglx.so
#12 0x00007f34a656383a in ?? () from /usr/lib/xorg/modules/dri/radeonsi_dri.so
#13 0x00007f34a656190a in ?? () from /usr/lib/xorg/modules/dri/radeonsi_dri.so
#14 0x00007f34a66baa2e in ?? () from /usr/lib/xorg/modules/dri/radeonsi_dri.so
#15 0x00007f34a66bbb98 in ?? () from /usr/lib/xorg/modules/dri/radeonsi_dri.so
#16 0x00007f34a668d9c0 in ?? () from /usr/lib/xorg/modules/dri/radeonsi_dri.so
#17 0x00007f34a66a19d5 in ?? () from /usr/lib/xorg/modules/dri/radeonsi_dri.so
#18 0x00007f34a6676577 in ?? () from /usr/lib/xorg/modules/dri/radeonsi_dri.so
#19 0x00007f34a665d74c in ?? () from /usr/lib/xorg/modules/dri/radeonsi_dri.so
#20 0x00007f34a66735d4 in ?? () from /usr/lib/xorg/modules/dri/radeonsi_dri.so
#21 0x00007f34a659d403 in ?? () from /usr/lib/xorg/modules/dri/radeonsi_dri.so
#22 0x00007f34aad20fee in ?? () from /usr/lib/libEGL.so.1
#23 0x00007f34aad193c5 in eglMakeCurrent () from /usr/lib/libEGL.so.1
#24 0x00007f34aaf35c08 in glamor_egl_make_current () from /usr/lib/xorg/modules/libglamoregl.so
#25 0x00007f34aa8cdc69 in glamor_block_handler () from /usr/lib/libglamor.so.0
#26 0x000000000043ad64 in _CallCallbacks ()
#27 0x0000000000588096 in WriteToClient ()
#28 0x00007f34a7c13761 in ?? () from /usr/lib/xorg/modules/extensions/libglx.so
#29 0x00007f34a7c271d0 in ?? () from /usr/lib/xorg/modules/extensions/libglx.so
#30 0x0000000000435c8e in ?? ()
#31 0x0000000000439aaa in ?? ()
#32 0x00007f34acc6e000 in __libc_start_main () from /usr/lib/libc.so.6
#33 0x000000000042507e in _start ()
Comment 1 Marti Raudsepp 2014-06-07 00:00:55 UTC
Created attachment 100573 [details]
gdm-Xorg-:0.log
Comment 2 Marti Raudsepp 2014-06-07 00:01:42 UTC
Created attachment 100574 [details]
steam.desktop.log
Comment 3 Marti Raudsepp 2014-06-07 10:36:12 UTC
Also occurs with mesa 10.2.1.
Comment 4 Marti Raudsepp 2014-06-07 10:42:29 UTC
Created attachment 100599 [details]
gdm-Xorg-:1.log

Oh, after waiting long enough, I also see the following messages in Xorg log... There are multiple such traces in the attached file.

[mi] EQ overflowing.  Additional events will be discarded until existing events are processed.

Backtrace:
0: /usr/bin/Xorg (xorg_backtrace+0x48) [0x584b08]
1: /usr/bin/Xorg (mieqEnqueue+0x22b) [0x566b7b]
2: /usr/bin/Xorg (QueuePointerEvents+0x52) [0x44cc72]
3: /usr/lib/xorg/modules/input/evdev_drv.so (0x7f417ddd9000+0x60ba) [0x7f417dddf0ba]
4: /usr/lib/xorg/modules/input/evdev_drv.so (0x7f417ddd9000+0x657d) [0x7f417dddf57d]
5: /usr/bin/Xorg (0x400000+0x72f08) [0x472f08]
6: /usr/bin/Xorg (0x400000+0x9b4b0) [0x49b4b0]
7: /usr/lib/libpthread.so.0 (0x7f4184c61000+0xf4b0) [0x7f4184c704b0]
8: /usr/lib/libpthread.so.0 (0x7f4184c61000+0xe38c) [0x7f4184c6f38c]
9: /usr/lib/libpthread.so.0 (0x7f4184c61000+0x9b3c) [0x7f4184c6ab3c]
10: /usr/lib/libpthread.so.0 (pthread_mutex_lock+0x6a) [0x7f4184c6a91a]
11: /usr/lib/libEGL.so.1 (eglCreateImageKHR+0x3e) [0x7f4181976fde]
12: /usr/lib/xorg/modules/libglamoregl.so (glamor_egl_create_textured_pixmap+0xf1) [0x7f4181b95e21]
13: /usr/lib/xorg/modules/drivers/radeon_drv.so (0x7f417e3f6000+0x4bac0) [0x7f417e441ac0]
14: /usr/lib/xorg/modules/drivers/radeon_drv.so (0x7f417e3f6000+0x4be26) [0x7f417e441e26]
15: /usr/lib/xorg/modules/drivers/radeon_drv.so (0x7f417e3f6000+0x42819) [0x7f417e438819]
16: /usr/bin/Xorg (0x400000+0x1554c3) [0x5554c3]
17: /usr/bin/Xorg (0x400000+0x15628f) [0x55628f]
18: /usr/bin/Xorg (DRI2GetBuffersWithFormat+0x10) [0x556690]
19: /usr/lib/xorg/modules/extensions/libglx.so (0x7f417e862000+0x2c661) [0x7f417e88e661]
20: /usr/lib/xorg/modules/dri/radeonsi_dri.so (0x7f417d15a000+0x6886a) [0x7f417d1c286a]
21: /usr/lib/xorg/modules/dri/radeonsi_dri.so (0x7f417d15a000+0x6693a) [0x7f417d1c093a]
22: /usr/lib/xorg/modules/dri/radeonsi_dri.so (0x7f417d15a000+0x1bfade) [0x7f417d319ade]
23: /usr/lib/xorg/modules/dri/radeonsi_dri.so (0x7f417d15a000+0x1c0c48) [0x7f417d31ac48]
24: /usr/lib/xorg/modules/dri/radeonsi_dri.so (0x7f417d15a000+0x192a70) [0x7f417d2eca70]
25: /usr/lib/xorg/modules/dri/radeonsi_dri.so (0x7f417d15a000+0x1a6a85) [0x7f417d300a85]
26: /usr/lib/xorg/modules/dri/radeonsi_dri.so (0x7f417d15a000+0x17b627) [0x7f417d2d5627]
27: /usr/lib/xorg/modules/dri/radeonsi_dri.so (0x7f417d15a000+0x1627fc) [0x7f417d2bc7fc]
28: /usr/lib/xorg/modules/dri/radeonsi_dri.so (0x7f417d15a000+0x178684) [0x7f417d2d2684]
29: /usr/lib/xorg/modules/dri/radeonsi_dri.so (0x7f417d15a000+0xa2433) [0x7f417d1fc433]
30: /usr/lib/libEGL.so.1 (0x7f4181970000+0x10ffe) [0x7f4181980ffe]
31: /usr/lib/libEGL.so.1 (eglMakeCurrent+0x1cd) [0x7f418197940d]
32: /usr/lib/xorg/modules/libglamoregl.so (glamor_egl_make_current+0x48) [0x7f4181b95c08]
33: /usr/lib/libglamor.so.0 (glamor_block_handler+0x69) [0x7f418152dc69]
34: /usr/bin/Xorg (_CallCallbacks+0x34) [0x43ad64]
35: /usr/bin/Xorg (WriteToClient+0x1a6) [0x588096]
36: /usr/lib/xorg/modules/extensions/libglx.so (0x7f417e862000+0x11761) [0x7f417e873761]
37: /usr/lib/xorg/modules/extensions/libglx.so (0x7f417e862000+0x251d0) [0x7f417e8871d0]
38: /usr/bin/Xorg (0x400000+0x35c8e) [0x435c8e]
39: /usr/bin/Xorg (0x400000+0x39aaa) [0x439aaa]
40: /usr/lib/libc.so.6 (__libc_start_main+0xf0) [0x7f41838ce000]
41: /usr/bin/Xorg (0x400000+0x2507e) [0x42507e]

[mi] These backtraces from mieqEnqueue may point to a culprit higher up the stack.
[mi] mieq is *NOT* the cause.  It is a victim.
....
Comment 5 Michel Dänzer 2014-06-09 07:30:35 UTC
I can't reproduce this with glamor from xserver Git, can you try that?

If not, or if it still happens with that, please get a backtrace with gdb, and make sure /usr/lib/xorg/modules/dri/radeonsi_dri.so and /usr/lib/xorg/modules/extensions/libglx.so have debugging symbols.
Comment 6 Marti Raudsepp 2014-06-11 19:38:39 UTC
Created attachment 100901 [details]
gdb-backtrace.txt

Yeah, still crashes with Glamor as of git 081a537.

Attached the gdb backtrace (both "bt" and "bt full" in this file). I also rebuilt mesa with debug symbols. I'm using kernel 3.14.4 this time.

I figured out that the "mieqEnqueue" backtraces appear when I move my mouse after the X server freezes.
Comment 7 Michel Dänzer 2014-06-12 06:50:27 UTC
(In reply to comment #6)
> Yeah, still crashes with Glamor as of git 081a537.

That's the standalone glamor tree. I mean glamor from the current xserver Git tree.

Anyway, I think the attached backtrace can only happen if Steam uses GLX indirect rendering (current versions of Steam present a warning dialog on startup when that's the case). You can try starting Steam with LIBGL_DEBUG=verbose to see why it's not getting direct rendering.
Comment 8 Marti Raudsepp 2014-06-12 10:28:57 UTC
(In reply to comment #7)
> That's the standalone glamor tree. I mean glamor from the current xserver
> Git tree.

Can/should I build glamor separately or should just build the whole xorg-server from git?

> Anyway, I think the attached backtrace can only happen if Steam uses GLX
> indirect rendering (current versions of Steam present a warning dialog on
> startup when that's the case).

Yeah, I'm aware there are some ABI issues on Arch Linux with Steam's bundled libgcc_s.so.
Comment 9 Marti Raudsepp 2014-06-12 17:45:49 UTC
(In reply to comment #7)
> That's the standalone glamor tree. I mean glamor from the current xserver
> Git tree.

You're right, it no longer crashes when building xorg-server 1.15.99.903 with --enable-glamor. I do see severe graphics glitches during resizing, but they disappear quickly after and it's not clear whose fault this is.

Is standalone glamor officialy deprecated with xorg-server 1.16?

Are you going to do anything about users of 1.15 or can indirect GLX be safely neglected? :)
Comment 10 Michel Dänzer 2014-06-13 05:48:26 UTC
(In reply to comment #8)
> Yeah, I'm aware there are some ABI issues on Arch Linux with Steam's bundled
> libgcc_s.so.

You can probably avoid the issues by moving away the bundled libraries.


(In reply to comment #9)
> Is standalone glamor officialy deprecated with xorg-server 1.16?

There's no reason to use glamor from the standalone tree with a version of xserver which includes glamor.


> Are you going to do anything about users of 1.15

There are plans for backporting the glamor changes from xserver to the standalone tree, but the details are still being worked out.


> or can indirect GLX be safely neglected? :)

GLX indirect rendering is never desirable for local clients.
Comment 11 EoD 2016-02-14 04:47:41 UTC
As xorg-server 1.15 is not supported any more, can this issue be closed?
Comment 12 Michel Dänzer 2016-02-15 02:38:07 UTC
Fixed with glamor from current xserver.


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.