Bug 302764

Summary: Kwin crash when exiting screensaver
Product: [Plasma] kwin Reporter: gael07ol
Component: generalAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED DUPLICATE    
Severity: crash CC: ahepas1999
Priority: NOR Flags: mgraesslin: Intel+
Version: unspecified   
Target Milestone: ---   
Platform: Mageia RPMs   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: New crash information added by DrKonqi

Description gael07ol 2012-06-29 20:41:46 UTC
Application: kwin (4.8.4 (4.8.4))
KDE Platform Version: 4.8.95 (4.8.95)
Qt Version: 4.8.2
Operating System: Linux 3.4.4-desktop-1.mga3 i686
Distribution: "Mageia 3"

-- Information about the crash:
- What I was doing when the application crashed:

1/ Screensaver is running
2/ I move the mouse to disable screensaver
3/ Kwin crash...

The crash can be reproduced some of the time.

-- Backtrace:
Application: KWin (kwin), signal: Segmentation fault
Using host libthread_db library "/lib/i686/libthread_db.so.1".
[Current thread is 1 (Thread 0xb15a26f0 (LWP 1590))]

Thread 2 (Thread 0xad60bb70 (LWP 1598)):
#0  0xffffe424 in __kernel_vsyscall ()
#1  0xb5d561bb in pthread_cond_wait@@GLIBC_2.3.2 () from /lib/i686/libpthread.so.0
#2  0xb751f5ac in pthread_cond_wait@@GLIBC_2.3.2 () from /lib/i686/libc.so.6
#3  0xb66258cd in QTWTF::TCMalloc_PageHeap::scavengerThread (this=0xb6732560) at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:2359
#4  0xb66258ff in QTWTF::TCMalloc_PageHeap::runScavengerThread (context=0xb6732560) at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:1464
#5  0xb5d52b33 in start_thread () from /lib/i686/libpthread.so.0
#6  0xb751120e in clone () from /lib/i686/libc.so.6
Backtrace stopped: Not enough registers or memory available to unwind further

Thread 1 (Thread 0xb15a26f0 (LWP 1590)):
[KCrash Handler]
#7  brw_update_renderbuffer_surface (brw=0x9f50298, rb=0x9df5aa0, unit=0) at brw_wm_surface_state.c:959
#8  0xafb683f3 in brw_update_renderbuffer_surfaces (brw=0x9f50298) at brw_wm_surface_state.c:1052
#9  0xafb5124f in brw_upload_state (brw=0x9f50298) at brw_state_upload.c:503
#10 0xafb3c277 in brw_try_draw_prims (max_index=5, min_index=0, ib=0x0, nr_prims=1, prim=0xbff78b28, arrays=0x9ec71f8, ctx=0x9f50298) at brw_draw.c:482
#11 brw_draw_prims (ctx=0x9f50298, arrays=0x9ec71f8, prim=0xbff78b28, nr_prims=1, ib=0x0, index_bounds_valid=1 '\001', min_index=0, max_index=5, tfb_vertcount=0x0) at brw_draw.c:566
#12 0xaf896c8e in vbo_draw_arrays (ctx=0x9f50298, mode=4, start=0, count=6, numInstances=1) at vbo/vbo_exec_array.c:600
#13 0xb645bb77 in KWin::GLVertexBufferPrivate::fallbackPainting (this=0xa06e7c0, region=..., primitiveMode=4) at /usr/src/debug/kde-workspace-4.8.4/kwin/libkwineffects/kwinglutils.cpp:1217
#14 0xb645d556 in KWin::GLVertexBuffer::render (this=0x9f50260, region=..., primitiveMode=4) at /usr/src/debug/kde-workspace-4.8.4/kwin/libkwineffects/kwinglutils.cpp:1299
#15 0xb76782f7 in renderQuads (normalized=false, tex=0xa0ae858, quads=..., region=..., this=<optimized out>) at /usr/src/debug/kde-workspace-4.8.4/kwin/scene_opengl.cpp:788
#16 KWin::SceneOpenGL::Window::renderQuads (this=0xa0ae838, region=..., quads=..., tex=0xa0ae858, normalized=false) at /usr/src/debug/kde-workspace-4.8.4/kwin/scene_opengl.cpp:768
#17 0xb767fac7 in KWin::SceneOpenGL::Window::performPaint (this=0xa0ae838, mask=9, region=..., data=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/scene_opengl.cpp:592
#18 0xb76650e7 in KWin::Scene::finalDrawWindow (this=0x9df5820, w=0xa233b88, mask=9, region=..., data=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/scene.cpp:438
#19 0xb768d1ac in KWin::EffectsHandlerImpl::drawWindow (this=0x9e03268, w=0xa233b90, mask=9, region=..., data=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/effects.cpp:286
#20 0xb68d2cf2 in KWin::Effect::drawWindow (this=0xa0f1f28, w=0xa233b90, mask=9, region=..., data=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/libkwineffects/kwineffects.cpp:181
#21 0xb768d148 in KWin::EffectsHandlerImpl::drawWindow (this=0x9e03268, w=0xa233b90, mask=9, region=..., data=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/effects.cpp:283
#22 0xb7664524 in KWin::Scene::finalPaintWindow (this=0x9df5820, w=0xa233b88, mask=9, region=..., data=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/scene.cpp:429
#23 0xb768d42c in KWin::EffectsHandlerImpl::paintWindow (this=0x9e03268, w=0xa233b90, mask=9, region=..., data=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/effects.cpp:249
#24 0xadecbc98 in KWin::TranslucencyEffect::paintWindow (this=0xa0f1f28, w=0xa233b90, mask=9, region=..., data=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/effects/translucency/translucency.cpp:169
#25 0xb768d3c8 in KWin::EffectsHandlerImpl::paintWindow (this=0x9e03268, w=0xa233b90, mask=9, region=..., data=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/effects.cpp:246
#26 0xb766530e in KWin::Scene::paintWindow (this=0x9df5820, w=0xa0ae838, mask=9, region=..., quads=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/scene.cpp:385
#27 0xb76664b5 in KWin::Scene::paintSimpleScreen (this=0x9df5820, orig_mask=8, region=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/scene.cpp:330
#28 0xb766442a in KWin::Scene::finalPaintScreen (this=0x9df5820, mask=8, region=..., data=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/scene.cpp:198
#29 0xb768d5d0 in KWin::EffectsHandlerImpl::paintScreen (this=0x9e03268, mask=8, region=..., data=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/effects.cpp:222
#30 0xb68d2e8a in KWin::Effect::paintScreen (this=0xa0f1f28, mask=8, region=..., data=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/libkwineffects/kwineffects.cpp:141
#31 0xb768d580 in KWin::EffectsHandlerImpl::paintScreen (this=0x9e03268, mask=8, region=..., data=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/effects.cpp:219
#32 0xb7666f9f in KWin::Scene::paintScreen (this=0x9df5820, mask=0xbff79954, region=0xbff799e8) at /usr/src/debug/kde-workspace-4.8.4/kwin/scene.cpp:156
#33 0xb76806a9 in KWin::SceneOpenGL::paint (this=0x9df5820, damage=..., toplevels=...) at /usr/src/debug/kde-workspace-4.8.4/kwin/scene_opengl_glx.cpp:459
#34 0xb76606c4 in KWin::Workspace::performCompositing (this=0xa082b30) at /usr/src/debug/kde-workspace-4.8.4/kwin/composite.cpp:417
#35 0xb5ef40e4 in QObject::event (this=0xa082b30, e=0xbff79ec0) at kernel/qobject.cpp:1157
#36 0xb53b814c in QApplicationPrivate::notify_helper (this=0x9d64068, receiver=0xa082b30, e=0xbff79ec0) at kernel/qapplication.cpp:4551
#37 0xb53bcb4f in QApplication::notify (this=0xbff79ec0, receiver=0xa082b30, e=0xbff79ec0) at kernel/qapplication.cpp:3933
#38 0xb7149471 in KApplication::notify (this=0xbff7a1c8, receiver=0xa082b30, event=0xbff79ec0) at /usr/src/debug/kdelibs-4.8.95/kdeui/kernel/kapplication.cpp:311
#39 0xb760948f in notify (e=0xbff79ec0, o=0xa082b30, this=0xbff7a1c8) at /usr/src/debug/kde-workspace-4.8.4/kwin/main.cpp:368
#40 KWin::Application::notify (this=0xbff7a1c8, o=0xa082b30, e=0xbff79ec0) at /usr/src/debug/kde-workspace-4.8.4/kwin/main.cpp:364
#41 0xb5ede0de in QCoreApplication::notifyInternal (this=0xbff7a1c8, receiver=0xa082b30, event=0xbff79ec0) at kernel/qcoreapplication.cpp:915
#42 0xb5f125f0 in sendEvent (event=0xbff79ec0, receiver=<optimized out>) at kernel/qcoreapplication.h:231
#43 QTimerInfoList::activateTimers (this=0x9d647e4) at kernel/qeventdispatcher_unix.cpp:611
#44 0xb5f127e8 in QEventDispatcherUNIX::processEvents (this=0x9d27ea0, flags=...) at kernel/qeventdispatcher_unix.cpp:930
#45 0xb546a2c3 in QEventDispatcherX11::processEvents (this=0x9d27ea0, flags=...) at kernel/qeventdispatcher_x11.cpp:152
#46 0xb5edcbac in QEventLoop::processEvents (this=0xbff7a108, flags=...) at kernel/qeventloop.cpp:149
#47 0xb5edcea1 in QEventLoop::exec (this=0xbff7a108, flags=...) at kernel/qeventloop.cpp:204
#48 0xb5ee22aa in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1187
#49 0xb53b5fa4 in QApplication::exec () at kernel/qapplication.cpp:3812
#50 0xb760c455 in kdemain (argc=1, argv=0xbff7a474) at /usr/src/debug/kde-workspace-4.8.4/kwin/main.cpp:541
#51 0x0804850b in main (argc=1, argv=0xbff7a474) at /usr/src/debug/kde-workspace-4.8.4/build/kwin/kwin_dummy.cpp:3

Possible duplicates by query: bug 302169, bug 301529, bug 301403, bug 301131, bug 300886.

Reported using DrKonqi
Comment 1 Martin Flöser 2012-06-29 20:51:59 UTC
disable unredirection of fullscreen windows in advanced compositing settings and complain to your distribution to ship broken drivers. That issue was fixed about a year ago.

*** This bug has been marked as a duplicate of bug 252817 ***
Comment 2 Thomas Lübking 2012-06-29 20:57:20 UTC
> KWin::GLVertexBufferPrivate::fallbackPainting (this=0xa06e7c0, region=..., primitiveMode=4)

i'm not sure it's /that/ intel bug and a don't think he should be in that codepath either (doesn't look like an i810)

we got a couple of those ones recently and only one ended in the fallback path (for accidentally using UMS drivers)

@gael07ol
please post the output of "qdbus org.kde.kwin /KWin supportInformation"
Comment 3 gael07ol 2012-06-30 21:12:54 UTC
Output of "qdbus org.kde.kwin /KWin supportInformation"

The following information should be used when requesting support on e.g. http://forum.kde.org.
It provides information about the currently running instance, which options are used,
what OpenGL driver and which effects are running.
Please post the information provided underneath this introductory text to a paste bin service
like http://paste.kde.org instead of pasting into support threads.

==========================

Options
=======
focusPolicy: 0
nextFocusPrefersMouse: false
clickRaise: true
autoRaise: false
autoRaiseInterval: 0
delayFocusInterval: 0
shadeHover: false
shadeHoverInterval: 250
tiling: false
tilingLayout: 1
tilingRaisePolicy: 0
separateScreenFocus: false
activeMouseScreen: false
placement: 4
focusPolicyIsReasonable: true
borderSnapZone: 10
windowSnapZone: 10
centerSnapZone: 0
snapOnlyWhenOverlapping: false
showDesktopIsMinimizeAll: false
rollOverDesktops: true
focusStealingPreventionLevel: 1
legacyFullscreenSupport: false
operationTitlebarDblClick: 
commandActiveTitlebar1: 0
commandActiveTitlebar2: 30
commandActiveTitlebar3: 2                                                                                                                                                      
commandInactiveTitlebar1: 4                                                                                                                                                    
commandInactiveTitlebar2: 30
commandInactiveTitlebar3: 2
commandWindow1: 7
commandWindow2: 8
commandWindow3: 8
commandWindowWheel: 31
commandAll1: 10
commandAll2: 3
commandAll3: 14
keyCmdAllModKey: 16777251
showGeometryTip: false
electricBorders: false
electricBorderDelay: 150
electricBorderCooldown: 350
electricBorderPushbackPixels: 1
electricBorderMaximize: true
electricBorderTiling: true
borderlessMaximizedWindows: false
killPingTimeout: 5000
hideUtilityWindowsForInactive: true
inactiveTabsSkipTaskbar: false
autogroupSimilarWindows: false
autogroupInForeground: true
compositingMode: 1
useCompositing: true
compositingInitialized: true
hiddenPreviews: 1
unredirectFullscreen: false
glSmoothScale: 2
glVSync: false
xrenderSmoothScale: false
maxFpsInterval: 17
refreshRate: 0
vBlankTime: 6144
glDirect: true
glStrictBinding: true
glStrictBindingFollowsDriver: true

Compositing
===========
Qt Graphics System: raster
Compositing is active
Compositing Type: OpenGL
OpenGL vendor string: Tungsten Graphics, Inc
OpenGL renderer string: Mesa DRI Intel(R) Ironlake Desktop x86/MMX/SSE2
OpenGL version string: 2.1 Mesa 8.0.3
Driver: Intel
GPU class: i965
OpenGL version: 2.1
Mesa version: 8.0.3
X server version: 1.12.2
Linux kernel version: 3.4.4
Direct rendering: yes
Requires strict binding: yes
GLSL shaders:  yes
Texture NPOT support:  yes
OpenGL 2 Shaders are used

Loaded Effects:
---------------
kwin4_effect_zoom
kwin4_effect_trackmouse
kwin4_effect_login
kwin4_effect_slidingpopups
kwin4_effect_minimizeanimation
kwin4_effect_translucency
kwin4_effect_screenshot
kwin4_effect_cube
kwin4_effect_boxswitch
kwin4_effect_slide
kwin4_effect_desktopgrid
kwin4_effect_fade
kwin4_effect_dialogparent
kwin4_effect_highlightwindow
kwin4_effect_taskbarthumbnail
kwin4_effect_presentwindows
kwin4_effect_dashboard
kwin4_effect_outline
kwin4_effect_startupfeedback

Currently Active Effects:
-------------------------
kwin4_effect_translucency



CPU info :
vendor_id : GenuineIntel
family : 6
model : 37
model name : Intel(R) Core(TM) i3 CPU 540 @ 3.07GHz
Comment 4 Thomas Lübking 2012-07-01 07:27:28 UTC
>> KWin::GLVertexBufferPrivate::fallbackPainting (this=0xa06e7c0, region=..., primitiveMode=4)
> GPU class: i965

likely bug #302169, ie. you've UMS drivers installed.

start "kwin --replace &" from konsole and watch for the same "Shaders are not supported" message then.
also attempt to start "kwin_gles --replace &" and check whether you get similar failures.

> unredirectFullscreen: false
did you change the setting as martin suggested before dumping the information or was the value like this?
Comment 5 gael07ol 2012-07-01 08:50:28 UTC
Output for "kwin --replace &" :
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
OpenGL vendor string:                   Tungsten Graphics, Inc
OpenGL renderer string:                 Mesa DRI Intel(R) Ironlake Desktop x86/MMX/SSE2
OpenGL version string:                  2.1 Mesa 8.0.3
OpenGL shading language version string: 1.20
Driver:                                 Intel
GPU class:                              i965
OpenGL version:                         2.1
GLSL version:                           1.20
Mesa version:                           8.0.3
X server version:                       1.12.2
Linux kernel version:                   3.4.4
Direct rendering:                       yes
Requires strict binding:                yes
GLSL shaders:                           yes
Texture NPOT support:                   yes
Object::connect: No such signal KWin::WorkspaceWrapper::currentActivityChanged(QString)
Object::connect: No such signal KWin::WorkspaceWrapper::activitiesChanged()
Object::connect: No such signal KWin::WorkspaceWrapper::activitiesChanged()


Output for "kwin_gles --replace &":
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
libEGL warning: failed to create a pipe screen for i965
OpenGL vendor string:                   Tungsten Graphics, Inc
OpenGL renderer string:                 Mesa DRI Intel(R) Ironlake Desktop x86/MMX/SSE2
OpenGL version string:                  OpenGL ES 2.0 Mesa 8.0.3
OpenGL shading language version string: OpenGL ES GLSL ES 1.0.16
Driver:                                 Intel
GPU class:                              i965
OpenGL version:                         2.0
GLSL version:                           1.0.16
Mesa version:                           8.0.3
X server version:                       1.12.2
Linux kernel version:                   3.4.4
Direct rendering:                       yes
Requires strict binding:                no
GLSL shaders:                           yes
Texture NPOT support:                   yes
Object::connect: No such signal KWin::WorkspaceWrapper::currentActivityChanged(QString)
Object::connect: No such signal KWin::WorkspaceWrapper::activitiesChanged()
Object::connect: No such signal KWin::WorkspaceWrapper::activitiesChanged()


> unredirectFullscreen: false : this is the default value, i've not changed this.
Comment 6 Jannis Liapis 2012-10-29 10:15:36 UTC
Created attachment 74863 [details]
New crash information added by DrKonqi

kwin (4.9.2) on KDE Platform 4.9.2 using Qt 4.8.3

- What I was doing when the application crashed:

every time exiting screensaver mode kwin crashes.

-- Backtrace (Reduced):
#6  brw_update_renderbuffer_surface (brw=0x1df4a50, rb=0x1daed70, unit=0) at brw_wm_surface_state.c:1109
#7  0x00007fa135040aa0 in brw_update_renderbuffer_surfaces (brw=0x1df4a50) at brw_wm_surface_state.c:1205
#8  0x00007fa13502aae2 in brw_upload_state (brw=brw@entry=0x1df4a50) at brw_state_upload.c:498
#9  0x00007fa1350181d7 in brw_try_draw_prims (max_index=23, min_index=2314515928, ib=<optimized out>, nr_prims=<optimized out>, prim=0x7fff89f4b5c0, arrays=<optimized out>, ctx=0x1df4a50) at brw_draw.c:493
#10 brw_draw_prims (ctx=0x1df4a50, prim=0x7fff89f4b5c0, nr_prims=<optimized out>, ib=<optimized out>, index_bounds_valid=<optimized out>, min_index=0, max_index=23, tfb_vertcount=0x0) at brw_draw.c:589