Bug 274550 - KWin crashes with Snap Helper effect when moving window
Summary: KWin crashes with Snap Helper effect when moving window
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Platform: Ubuntu Packages Linux
: NOR crash (vote)
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-05-30 21:52 UTC by Kai Uwe Broulik
Modified: 2011-06-24 09:58 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 4.7.0


Attachments
New crash information added by DrKonqi (4.46 KB, text/plain)
2011-06-24 09:58 UTC, Lach Sławomir
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kai Uwe Broulik 2011-05-30 21:52:56 UTC
Application: kwin (4.6.80 (4.7 Beta1))
KDE Platform Version: 4.6.80 (4.7 Beta1)
Qt Version: 4.7.1
Operating System: Linux 2.6.38-8-generic x86_64
Distribution: Ubuntu 11.04

-- Information about the crash:
- What I was doing when the application crashed:
I activated the Snap Helper effect and moved a window, after moving my mouse for about 50 pixels (when the effect should be shown?) KWin instantly crashes and restarts.

nVidia BLOB, GeForce 250 GTS
Compositing type: Open GL
Keep window thumbnails: Always
Scale method: Accurate
Direct render enabled, Open GL 2 Shaders enabled, VSync off.

Crashes independently from Open GL 2 setting or Direct rendering setting. With XRender KWin doesn't crash but the effect just doesn't work

The crash can be reproduced every time.

-- Backtrace:
Application: KWin (kwin), signal: Segmentation fault
[Current thread is 1 (Thread 0x7f740e3ec7c0 (LWP 11490))]

Thread 2 (Thread 0x7f74090eb700 (LWP 11494)):
#0  pthread_cond_wait@@GLIBC_2.3.2 () at ../nptl/sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:162
#1  0x00007f741886c02d in QTWTF::TCMalloc_PageHeap::scavengerThread (this=0x7f7418bf3a20) at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:2359
#2  0x00007f741886b688 in QTWTF::TCMalloc_PageHeap::runScavengerThread (context=0x7f7418bf3a20) at ../3rdparty/javascriptcore/JavaScriptCore/wtf/FastMalloc.cpp:1464
#3  0x0000003b0069e853 in ?? () from /usr/lib/nvidia-current/libGL.so.1
#4  0x000000301fe06d8c in start_thread (arg=0x7f74090eb700) at pthread_create.c:304
#5  0x000000301f6e604d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112
#6  0x0000000000000000 in ?? ()

Thread 1 (Thread 0x7f740e3ec7c0 (LWP 11490)):
[KCrash Handler]
#6  0x00007f74073f7359 in KWin::SnapHelperEffect::postPaintScreen (this=0x2722400) at /build/buildd/project-neon-kde-workspace-2+git20110529+r45991/kwin/effects/snaphelper/snaphelper.cpp:110
#7  0x00007f7418f65fef in KWin::EffectsHandlerImpl::postPaintScreen (this=0x1d171e0) at /build/buildd/project-neon-kde-workspace-2+git20110529+r45991/kwin/effects.cpp:221
#8  0x00007f740739f08a in KWin::DimScreenEffect::postPaintScreen (this=0x28013d0) at /build/buildd/project-neon-kde-workspace-2+git20110529+r45991/kwin/effects/dimscreen/dimscreen.cpp:76
#9  0x00007f7418f65fef in KWin::EffectsHandlerImpl::postPaintScreen (this=0x1d171e0) at /build/buildd/project-neon-kde-workspace-2+git20110529+r45991/kwin/effects.cpp:221
#10 0x00007f74073bb0a0 in KWin::ZoomEffect::postPaintScreen (this=0x2800970) at /build/buildd/project-neon-kde-workspace-2+git20110529+r45991/kwin/effects/zoom/zoom.cpp:364
#11 0x00007f7418f65fef in KWin::EffectsHandlerImpl::postPaintScreen (this=0x1d171e0) at /build/buildd/project-neon-kde-workspace-2+git20110529+r45991/kwin/effects.cpp:221
#12 0x00007f7418f44793 in KWin::Scene::paintScreen (this=0x1ec5220, mask=0x7fff5b98bc1c, region=0x7fff5b98bce0) at /build/buildd/project-neon-kde-workspace-2+git20110529+r45991/kwin/scene.cpp:139
#13 0x00007f7418f551cd in KWin::SceneOpenGL::paint (this=0x1ec5220, damage=..., toplevels=...) at /build/buildd/project-neon-kde-workspace-2+git20110529+r45991/kwin/scene_opengl_glx.cpp:455
#14 0x00007f7418f3d580 in KWin::Workspace::performCompositing (this=0x1e10560) at /build/buildd/project-neon-kde-workspace-2+git20110529+r45991/kwin/composite.cpp:432
#15 0x00007f7418f3cf92 in KWin::Workspace::timerEvent (this=0x1e10560, te=0x7fff5b98c670) at /build/buildd/project-neon-kde-workspace-2+git20110529+r45991/kwin/composite.cpp:374
#16 0x00007f7416555111 in QObject::event (this=0x1e10560, e=0x7fff5b98c670) at kernel/qobject.cpp:1183
#17 0x00007f7415609d46 in QApplicationPrivate::notify_helper (this=0x1d94850, receiver=0x1e10560, e=0x7fff5b98c670) at kernel/qapplication.cpp:4445
#18 0x00007f7415607334 in QApplication::notify (this=0x7fff5b98cb70, receiver=0x1e10560, e=0x7fff5b98c670) at kernel/qapplication.cpp:3845
#19 0x00007f74172f30a4 in KApplication::notify (this=0x7fff5b98cb70, receiver=0x1e10560, event=0x7fff5b98c670) at /build/buildd/project-neon-kdelibs-2+git20110529+r91803/kdeui/kernel/kapplication.cpp:311
#20 0x00007f7418ec7ba8 in KWin::Application::notify (this=0x7fff5b98cb70, o=0x1e10560, e=0x7fff5b98c670) at /build/buildd/project-neon-kde-workspace-2+git20110529+r45991/kwin/main.cpp:365
#21 0x00007f741653c99a in QCoreApplication::notifyInternal (this=0x7fff5b98cb70, receiver=0x1e10560, event=0x7fff5b98c670) at kernel/qcoreapplication.cpp:732
#22 0x00007f74165406e7 in QCoreApplication::sendEvent (receiver=0x1e10560, event=0x7fff5b98c670) at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:215
#23 0x00007f74165788dd in QTimerInfoList::activateTimers (this=0x1d8f820) at kernel/qeventdispatcher_unix.cpp:603
#24 0x00007f741657976f in QEventDispatcherUNIX::activateTimers (this=0x1ce40d0) at kernel/qeventdispatcher_unix.cpp:860
#25 0x00007f7416579ac5 in QEventDispatcherUNIX::processEvents (this=0x1ce40d0, flags=...) at kernel/qeventdispatcher_unix.cpp:922
#26 0x00007f74156e31a3 in QEventDispatcherX11::processEvents (this=0x1ce40d0, flags=...) at kernel/qeventdispatcher_x11.cpp:152
#27 0x00007f741653a532 in QEventLoop::processEvents (this=0x7fff5b98ca90, flags=...) at kernel/qeventloop.cpp:149
#28 0x00007f741653a686 in QEventLoop::exec (this=0x7fff5b98ca90, flags=...) at kernel/qeventloop.cpp:201
#29 0x00007f741653d08c in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1009
#30 0x00007f7415606ebe in QApplication::exec () at kernel/qapplication.cpp:3719
#31 0x00007f7418ec8bd1 in kdemain (argc=3, argv=0x7fff5b98d168) at /build/buildd/project-neon-kde-workspace-2+git20110529+r45991/kwin/main.cpp:514
#32 0x0000000000400966 in main (argc=3, argv=0x7fff5b98d168) at /build/buildd/project-neon-kde-workspace-2+git20110529+r45991/obj-x86_64-linux-gnu/kwin/kwin_dummy.cpp:3

Reported using DrKonqi
Comment 1 Thomas Lübking 2011-05-31 00:17:37 UTC
m_window is not NULLed on window deletion or after moveResize finished, also xrender is simply not implemented (but there's nothing techincally preventing it)

what's this effect supposed to be good for?
the center of your screen is the center of your screen - where you'd expect the crosshair ;-)

In other words: this effect would require some rework, but is it really useful for something so we should keep it at all?
Seems to be just a pointless visual annoyance to me - esp. since kwin can blindly snap windows anyway *shrug*
Comment 2 Kai Uwe Broulik 2011-05-31 05:36:39 UTC
Well, I wouldn't miss it *g* was just playing around with the effects
Comment 3 Martin Flöser 2011-05-31 06:51:17 UTC
It is on my to kill list but first I want to have a stable ABI...

KDE5 sounds like a good excuse for a cleanup :-P
Comment 4 Martin Flöser 2011-06-02 10:09:59 UTC
Git commit 21d8d143545d69e3e891d86266631f2907c6d93a by Martin Gräßlin.
Committed on 02/06/2011 at 10:08.
Pushed by graesslin into branch 'master'.

Only end effect if it is not active any more

BUG: 274550
FIXED-IN: 4.7.0

M  +1    -1    kwin/effects/snaphelper/snaphelper.cpp     

http://commits.kde.org/kde-workspace/21d8d143545d69e3e891d86266631f2907c6d93a
Comment 5 Lach Sławomir 2011-06-24 09:58:59 UTC
Created attachment 61293 [details]
New crash information added by DrKonqi

kwin (4.6.80 (4.7 Beta1) "release 6") on KDE Platform 4.6.80 (4.7 Beta1) "release 6" using Qt 4.7.3

- What I was doing when the application crashed:

I was moving window with compositing and snap helper enabled. Without compositing enabled there's no crashesh.

After disabling snap helper everything works.
/sbin/lspic output(only part):
00:02.0 VGA compatible controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (primary) (rev 03)
00:02.1 Display controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (secondary) (rev 03)

-- Backtrace (Reduced):
#6  KWin::SnapHelperEffect::postPaintScreen (this=0x1153200) at /usr/src/debug/kde-workspace-4.6.80/kwin/effects/snaphelper/snaphelper.cpp:110
#7  0x00007f7f1cdf1ca2 in KWin::EffectsHandlerImpl::postPaintScreen (this=0x1212720) at /usr/src/debug/kde-workspace-4.6.80/kwin/effects.cpp:221
#8  0x00007f7f1cdf1ca2 in KWin::EffectsHandlerImpl::postPaintScreen (this=0x1212720) at /usr/src/debug/kde-workspace-4.6.80/kwin/effects.cpp:221
#9  0x00007f7f1cdd3496 in KWin::Scene::paintScreen (this=0xb79e40, mask=<value optimized out>, region=0x7fffde3b6610) at /usr/src/debug/kde-workspace-4.6.80/kwin/scene.cpp:139
#10 0x00007f7f1cde92a9 in KWin::SceneOpenGL::paint (this=0xb79e40, damage=..., toplevels=<value optimized out>) at /usr/src/debug/kde-workspace-4.6.80/kwin/scene_opengl_glx.cpp:455