[Ubuntu-x-swat] [Bug 1318584] Re: qt crashed when switching video out mode to external or internal only mode
Ok, I can reproduce the crash pretty easily here. Let's see what I can shake out with a full debug stack. -- You received this bug notification because you are a member of Ubuntu-X, which is subscribed to libxcb in Ubuntu. https://bugs.launchpad.net/bugs/1318584 Title: qt crashed when switching video out mode to external or internal only mode To manage notifications about this bug go to: https://bugs.launchpad.net/checkbox-gui/+bug/1318584/+subscriptions ___ Mailing list: https://launchpad.net/~ubuntu-x-swat Post to : ubuntu-x-swat@lists.launchpad.net Unsubscribe : https://launchpad.net/~ubuntu-x-swat More help : https://help.launchpad.net/ListHelp
[Ubuntu-x-swat] [Bug 1318584] Re: qt crashed when switching video out mode to external or internal only mode
So, the relevant madness appears to be: …snip all the glib detritus… ==30400== Invalid read of size 8 ==30400==at 0xE8587FB: QGLXContext::makeCurrent(QPlatformSurface*) (qglxintegration.cpp:333) ==30400==by 0x6339772: QOpenGLContext::makeCurrent(QSurface*) (qopenglcontext.cpp:812) ==30400==by 0x4F9626A: ??? (in /usr/lib/x86_64-linux-gnu/libQt5Quick.so.5.3.0) ==30400==by 0x4F96F1D: ??? (in /usr/lib/x86_64-linux-gnu/libQt5Quick.so.5.3.0) ==30400==by 0x6301448: QWindow::event(QEvent*) (qwindow.cpp:1956) ==30400==by 0x4FC0D72: QQuickWindow::event(QEvent*) (in /usr/lib/x86_64-linux-gnu/libQt5Quick.so.5.3.0) ==30400==by 0x5B2E6DB: QApplicationPrivate::notify_helper(QObject*, QEvent*) (qapplication.cpp:3504) ==30400==by 0x5B33455: QApplication::notify(QObject*, QEvent*) (qapplication.cpp:3287) ==30400==by 0x6BDB9D4: QCoreApplication::notifyInternal(QObject*, QEvent*) (qcoreapplication.cpp:935) ==30400==by 0x62FABC5: QGuiApplicationPrivate::processExposeEvent(QWindowSystemInterfacePrivate::ExposeEvent*) (qcoreapplication.h:240) ==30400==by 0x62FB724: QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*) (qguiapplication.cpp:1566) ==30400==by 0x62E2427: QWindowSystemInterface::sendWindowSystemEvents(QFlagsQEventLoop::ProcessEventsFlag) (qwindowsysteminterface.cpp:579) ==30400== Address 0xe1a8f90 is 16 bytes inside a block of size 192 free'd ==30400==at 0x4C2C2BC: operator delete(void*) (vg_replace_malloc.c:503) ==30400==by 0xE83611A: QXcbConnection::updateScreens() (qxcbconnection.cpp:258) ==30400==by 0xE836814: QXcbConnection::handleXcbEvent(xcb_generic_event_t*) (qxcbconnection.cpp:928) ==30400==by 0xE837A0A: QXcbConnection::processXcbEvents() (qxcbconnection.cpp:1232) ==30400==by 0x6C0B5B5: QObject::event(QEvent*) (qobject.cpp:1241) ==30400==by 0x5B2E6DB: QApplicationPrivate::notify_helper(QObject*, QEvent*) (qapplication.cpp:3504) ==30400==by 0x5B33455: QApplication::notify(QObject*, QEvent*) (qapplication.cpp:3287) ==30400==by 0x6BDB9D4: QCoreApplication::notifyInternal(QObject*, QEvent*) (qcoreapplication.cpp:935) ==30400==by 0x6BDD826: QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) (qcoreapplication.h:237) ==30400==by 0x6C33242: postEventSourceDispatch(_GSource*, int (*)(void*), void*) (qeventdispatcher_glib.cpp:279) ==30400==by 0x849FDE3: g_main_context_dispatch (in /lib/x86_64-linux-gnu/libglib-2.0.so.0.4101.0) ==30400==by 0x84A0027: g_main_context_iterate.isra.24 (in /lib/x86_64-linux-gnu/libglib-2.0.so.0.4101.0) ==30400== ==30400== Invalid read of size 8 ==30400==at 0xE858525: QGLXContext::swapBuffers(QPlatformSurface*) (qglxintegration.cpp:392) ==30400==by 0x6339A71: QOpenGLContext::swapBuffers(QSurface*) (qopenglcontext.cpp:906) ==30400==by 0x4F96A8B: ??? (in /usr/lib/x86_64-linux-gnu/libQt5Quick.so.5.3.0) ==30400==by 0x4F96F1D: ??? (in /usr/lib/x86_64-linux-gnu/libQt5Quick.so.5.3.0) ==30400==by 0x6301448: QWindow::event(QEvent*) (qwindow.cpp:1956) ==30400==by 0x4FC0D72: QQuickWindow::event(QEvent*) (in /usr/lib/x86_64-linux-gnu/libQt5Quick.so.5.3.0) ==30400==by 0x5B2E6DB: QApplicationPrivate::notify_helper(QObject*, QEvent*) (qapplication.cpp:3504) ==30400==by 0x5B33455: QApplication::notify(QObject*, QEvent*) (qapplication.cpp:3287) ==30400==by 0x6BDB9D4: QCoreApplication::notifyInternal(QObject*, QEvent*) (qcoreapplication.cpp:935) ==30400==by 0x62FABC5: QGuiApplicationPrivate::processExposeEvent(QWindowSystemInterfacePrivate::ExposeEvent*) (qcoreapplication.h:240) ==30400==by 0x62FB724: QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*) (qguiapplication.cpp:1566) ==30400==by 0x62E2427: QWindowSystemInterface::sendWindowSystemEvents(QFlagsQEventLoop::ProcessEventsFlag) (qwindowsysteminterface.cpp:579) ==30400== Address 0xe1a8f90 is 16 bytes inside a block of size 192 free'd ==30400==at 0x4C2C2BC: operator delete(void*) (vg_replace_malloc.c:503) ==30400==by 0xE83611A: QXcbConnection::updateScreens() (qxcbconnection.cpp:258) ==30400==by 0xE836814: QXcbConnection::handleXcbEvent(xcb_generic_event_t*) (qxcbconnection.cpp:928) ==30400==by 0xE837A0A: QXcbConnection::processXcbEvents() (qxcbconnection.cpp:1232) ==30400==by 0x6C0B5B5: QObject::event(QEvent*) (qobject.cpp:1241) ==30400==by 0x5B2E6DB: QApplicationPrivate::notify_helper(QObject*, QEvent*) (qapplication.cpp:3504) ==30400==by 0x5B33455: QApplication::notify(QObject*, QEvent*) (qapplication.cpp:3287) ==30400==by 0x6BDB9D4: QCoreApplication::notifyInternal(QObject*, QEvent*) (qcoreapplication.cpp:935) ==30400==by 0x6BDD826: QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) (qcoreapplication.h:237) ==30400==by 0x6C33242: postEventSourceDispatch(_GSource*, int (*)(void*), void*)
[Ubuntu-x-swat] [Bug 1318584] Re: qt crashed when switching video out mode to external or internal only mode
So, it looks like there's a race between the destruction of an QXcbScreen in response to a RANDR event in handleXcbEvent and (a) expose handling and (b) some timer. I'll forward this upstream and might let someone more familiar with Qt take over. -- You received this bug notification because you are a member of Ubuntu-X, which is subscribed to libxcb in Ubuntu. https://bugs.launchpad.net/bugs/1318584 Title: qt crashed when switching video out mode to external or internal only mode To manage notifications about this bug go to: https://bugs.launchpad.net/checkbox-gui/+bug/1318584/+subscriptions ___ Mailing list: https://launchpad.net/~ubuntu-x-swat Post to : ubuntu-x-swat@lists.launchpad.net Unsubscribe : https://launchpad.net/~ubuntu-x-swat More help : https://help.launchpad.net/ListHelp
[Ubuntu-x-swat] [Bug 1318584] Re: qt crashed when switching video out mode to external or internal only mode
On utopic when I disable the active screen I get the following backtrace: pure virtual method called terminate called without an active exception Program received signal SIGABRT, Aborted. 0x74e4c117 in __GI_raise (sig=sig@entry=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56 56 ../nptl/sysdeps/unix/sysv/linux/raise.c: Bestand of map bestaat niet. (gdb) bt #0 0x74e4c117 in __GI_raise (sig=sig@entry=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56 #1 0x74e4d808 in __GI_abort () at abort.c:89 #2 0x75453285 in __gnu_cxx::__verbose_terminate_handler() () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6 #3 0x754510f6 in ?? () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6 #4 0x75451141 in std::terminate() () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6 #5 0x75451c8f in __cxa_pure_virtual () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6 #6 0x75ef6efa in QPlatformScreen::physicalSize (this=optimized out) at kernel/qplatformscreen.cpp:139 #7 0x75f30772 in QScreen::physicalSize (this=this@entry=0x6620c0) at kernel/qscreen.cpp:243 #8 0x75f30819 in QScreen::physicalDotsPerInch (this=this@entry=0x6620c0) at kernel/qscreen.cpp:166 #9 0x778343d2 in QQuickScreenAttached::screenChanged (this=0x2e16f20, screen=0x6621b0) at items/qquickscreen.cpp:315 #10 0x759f391e in QMetaObject::activate (sender=sender@entry=0x7fffe7b0, signalOffset=optimized out, local_signal_index=local_signal_index@entry=0, argv=argv@entry=0x7fffd9a0) at kernel/qobject.cpp:3680 #11 0x759f3dd7 in QMetaObject::activate (sender=sender@entry=0x7fffe7b0, m=m@entry=0x765125c0 QWindow::staticMetaObject, local_signal_index=local_signal_index@entry=0, argv=argv@entry=0x7fffd9a0) at kernel/qobject.cpp:3546 #12 0x75f0b78f in QWindow::screenChanged (this=this@entry=0x7fffe7b0, _t1=_t1@entry=0x6621b0) at .moc/moc_qwindow.cpp:623 #13 0x75f0e160 in QWindowPrivate::setScreen (this=0x8aa3a0, newScreen=0x6621b0, recreate=optimized out) at kernel/qwindow.cpp:372 #14 0x75f0e2e2 in QWindow::screenDestroyed (this=0x7fffe7b0, object=optimized out) at kernel/qwindow.cpp:1637 #15 0x759f391e in QMetaObject::activate (sender=sender@entry=0x6620c0, signalOffset=optimized out, local_signal_index=local_signal_index@entry=0, argv=argv@entry=0x7fffdb60) at kernel/qobject.cpp:3680 #16 0x759f3dd7 in QMetaObject::activate (sender=sender@entry=0x6620c0, m=m@entry=0x75e1bf20 QObject::staticMetaObject, local_signal_index=local_signal_index@entry=0, argv=argv@entry=0x7fffdb60) at kernel/qobject.cpp:3546 #17 0x759f3e6f in QObject::destroyed (this=this@entry=0x6620c0, _t1=_t1@entry=0x6620c0) at .moc/moc_qobject.cpp:202 #18 0x759fb308 in QObject::~QObject (this=0x6620c0, __in_chrg=optimized out) at kernel/qobject.cpp:901 #19 0x7624faf7 in ~QScreen (this=0x6620c0, __in_chrg=optimized out) at .moc/../kernel/qscreen.h:64 #20 QScreen::~QScreen (this=0x6620c0, __in_chrg=optimized out) at .moc/../kernel/qscreen.h:64 #21 0x75ef70aa in QPlatformScreen::~QPlatformScreen (this=0x65b8e0, __in_chrg=optimized out) at kernel/qplatformscreen.cpp:65 #22 0x7fffedf51a99 in QXcbScreen::~QXcbScreen (this=0x65b8e0, __in_chrg=optimized out) at qxcbscreen.cpp:209 #23 0x7fffedf4511b in QXcbConnection::updateScreens (this=this@entry=0x6492b0) at qxcbconnection.cpp:258 #24 0x7fffedf45815 in QXcbConnection::handleXcbEvent (this=this@entry=0x6492b0, event=event@entry=0x7fffe4003490) at qxcbconnection.cpp:928 #25 0x7fffedf46a0b in QXcbConnection::processXcbEvents (this=0x6492b0) at qxcbconnection.cpp:1232 #26 0x759f45b6 in QObject::event (this=0x6492b0, e=optimized out) at kernel/qobject.cpp:1241 #27 0x768e66dc in QApplicationPrivate::notify_helper (this=this@entry=0x63cce0, receiver=receiver@entry=0x6492b0, e=e@entry=0x7fffe4004260) at kernel/qapplication.cpp:3504 #28 0x768eb456 in QApplication::notify (this=0x7fffe750, receiver=0x6492b0, e=0x7fffe4004260) at kernel/qapplication.cpp:3287 #29 0x759c49d5 in QCoreApplication::notifyInternal (this=0x7fffe750, receiver=0x6492b0, event=event@entry=0x7fffe4004260) at kernel/qcoreapplication.cpp:935 #30 0x759c6827 in sendEvent (event=0x7fffe4004260, receiver=optimized out) at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:237 #31 QCoreApplicationPrivate::sendPostedEvents (receiver=receiver@entry=0x0, event_type=event_type@entry=0, data=0x63ce40) at kernel/qcoreapplication.cpp:1539 #32 0x759c6e58 in QCoreApplication::sendPostedEvents (receiver=receiver@entry=0x0, event_type=event_type@entry=0) at kernel/qcoreapplication.cpp:1397 #33 0x75a1c243 in postEventSourceDispatch (s=0x6ca730) at kernel/qeventdispatcher_glib.cpp:279 #34 0x73beade4 in g_main_context_dispatch () from
[Ubuntu-x-swat] [Bug 1318584] Re: qt crashed when switching video out mode to external or internal only mode
For completeness sake, here's mine on Latitude D630 (Intel 965GM graphics), also inside qglxintegration.cpp but slightly different. Program received signal SIGSEGV, Segmentation fault. 0x7fffee0aa81c in QGLXContext::swapBuffers (this=0x81d790, surface=0x638450) at qglxintegration.cpp:392 (gdb) bt #0 0x7fffee0aa81c in QGLXContext::swapBuffers (this=0x81d790, surface=0x638450) at qglxintegration.cpp:392 #1 0x7641cd92 in QOpenGLContext::swapBuffers (this=0x6c6b60, surface=optimized out) at kernel/qopenglcontext.cpp:906 #2 0x77990a8c in QSGGuiThreadRenderLoop::renderWindow ( this=this@entry=0xb44110, window=0x7943c0) at scenegraph/qsgrenderloop.cpp:381 #3 0x77990f1e in QSGGuiThreadRenderLoop::exposureChanged ( this=0xb44110, window=0x7943c0) at scenegraph/qsgrenderloop.cpp:414 #4 0x763e4769 in QWindow::event (this=this@entry=0x7943c0, ev=ev@entry=0x7fffd8a0) at kernel/qwindow.cpp:1956 #5 0x779bad73 in QQuickWindow::event (this=0x7943c0, e=0x7fffd8a0) at items/qquickwindow.cpp:1339 #6 0x76b3a6dc in QApplicationPrivate::notify_helper ( this=this@entry=0x616560, receiver=receiver@entry=0x7943c0, e=e@entry=0x7fffd8a0) at kernel/qapplication.cpp:3504 #7 0x76b3f456 in QApplication::notify (this=0x7fffddc0, receiver=0x7943c0, e=0x7fffd8a0) at kernel/qapplication.cpp:3287 #8 0x75e999d5 in QCoreApplication::notifyInternal (this= 0x7fffddc0, receiver=receiver@entry=0x7943c0, event=event@entry=0x7fffd8a0) at kernel/qcoreapplication.cpp:935 #9 0x763ddee6 in sendSpontaneousEvent (event=0x7fffd8a0, receiver=0x7943c0) at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:240 #10 QGuiApplicationPrivate::processExposeEvent (e=0x62f080) at kernel/qguiapplication.cpp:2528 #11 0x763dea45 in QGuiApplicationPrivate::processWindowSystemEvent ( e=e@entry=0x62f080) at kernel/qguiapplication.cpp:1566 #12 0x763c54d8 in QWindowSystemInterface::sendWindowSystemEvents ( flags=...) at kernel/qwindowsysteminterface.cpp:579 #13 0x7fffee0ad000 in userEventSourceDispatch (source=optimized out) at eventdispatchers/qeventdispatcher_glib.cpp:78 #14 0x74512de4 in g_main_context_dispatch () from /lib/x86_64-linux-gnu/libglib-2.0.so.0 #15 0x74513028 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0 #16 0x745130cc in g_main_context_iteration () from /lib/x86_64-linux-gnu/libglib-2.0.so.0 #17 0x75ef06bc in QEventDispatcherGlib::processEvents (this=0x6ece20, flags=...) at kernel/qeventdispatcher_glib.cpp:426 #18 0x75e978eb in QEventLoop::exec (this=this@entry=0x7fffdb60, flags=..., flags@entry=...) at kernel/qeventloop.cpp:212 #19 0x75e9ef46 in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1188 #20 0x763d60cc in QGuiApplication::exec () at kernel/qguiapplication.cpp:1436 #21 0x76b38e05 in QApplication::exec () at kernel/qapplication.cpp:2749 #22 0x00404301 in main (argc=2, argv=optimized out) at main.cpp:548 I also added one more patch to the qt5-beta1 PPA's qtbase: https://qt.gitorious.org/qt/qtbase/commit/075c36e39beedb33ec4b239d57075f54acb21acf Since Maarten experienced a trace that also concerned qtdeclarative (Qt Quick), it's worth mentioning there's an updated 5.3 branch snapshot build of qtdeclarative (made compatible with 5.3.0) soon finished building at: https://launchpad.net/~canonical- qt5-edgers/+archive/ubuntu/qt5-proper -- You received this bug notification because you are a member of Ubuntu-X, which is subscribed to libxcb in Ubuntu. https://bugs.launchpad.net/bugs/1318584 Title: qt crashed when switching video out mode to external or internal only mode To manage notifications about this bug go to: https://bugs.launchpad.net/checkbox-gui/+bug/1318584/+subscriptions ___ Mailing list: https://launchpad.net/~ubuntu-x-swat Post to : ubuntu-x-swat@lists.launchpad.net Unsubscribe : https://launchpad.net/~ubuntu-x-swat More help : https://help.launchpad.net/ListHelp
[Ubuntu-x-swat] [Bug 1318584] Re: qt crashed when switching video out mode to external or internal only mode
It seems display driver is not important, I always hit this bug it seems, on nvidia, nouveau, radeon and intel. -- You received this bug notification because you are a member of Ubuntu-X, which is subscribed to libxcb in Ubuntu. https://bugs.launchpad.net/bugs/1318584 Title: qt crashed when switching video out mode to external or internal only mode To manage notifications about this bug go to: https://bugs.launchpad.net/checkbox-gui/+bug/1318584/+subscriptions ___ Mailing list: https://launchpad.net/~ubuntu-x-swat Post to : ubuntu-x-swat@lists.launchpad.net Unsubscribe : https://launchpad.net/~ubuntu-x-swat More help : https://help.launchpad.net/ListHelp
[Ubuntu-x-swat] [Bug 1318584] Re: qt crashed when switching video out mode to external or internal only mode
I think it only depends on whether opengl acceleration is enabled whether you get the former or latter behavior. ** No longer affects: libxcb (Ubuntu) -- You received this bug notification because you are a member of Ubuntu-X, which is subscribed to libxcb in Ubuntu. https://bugs.launchpad.net/bugs/1318584 Title: qt crashed when switching video out mode to external or internal only mode To manage notifications about this bug go to: https://bugs.launchpad.net/checkbox-gui/+bug/1318584/+subscriptions ___ Mailing list: https://launchpad.net/~ubuntu-x-swat Post to : ubuntu-x-swat@lists.launchpad.net Unsubscribe : https://launchpad.net/~ubuntu-x-swat More help : https://help.launchpad.net/ListHelp
[Ubuntu-x-swat] [Bug 1318584] Re: qt crashed when switching video out mode to external or internal only mode
** Also affects: libxcb (Ubuntu) Importance: Undecided Status: New ** Description changed: - checkbox-gui crashed with following console outputs: pure virtual method called terminate called without an active exception Aborted (core dumped) Steps to reproduce: 1. open checkbox-gui 2. connected external display 3. switch video output mode, usually by using the common video output switch hotkey. Expected result: checkbox-gui still running when switching back to extended desktop video out mode. Actual result: checkbox-gui crashed + + --- + https://bugreports.qt-project.org/browse/QTBUG-39663 -- You received this bug notification because you are a member of Ubuntu-X, which is subscribed to libxcb in Ubuntu. https://bugs.launchpad.net/bugs/1318584 Title: qt crashed when switching video out mode to external or internal only mode To manage notifications about this bug go to: https://bugs.launchpad.net/checkbox-gui/+bug/1318584/+subscriptions ___ Mailing list: https://launchpad.net/~ubuntu-x-swat Post to : ubuntu-x-swat@lists.launchpad.net Unsubscribe : https://launchpad.net/~ubuntu-x-swat More help : https://help.launchpad.net/ListHelp
[Ubuntu-x-swat] [Bug 1318584] Re: qt crashed when switching video out mode to external or internal only mode
Unfortunately the two patches I cherry-picked for qtbase do not seem to fix the problem for me on that Dell laptop where I'm able to reproduce the problem. I also included updated libxcb since I saw http://cgit.freedesktop.org/xcb/libxcb/commit/?id=be0fe56c3bcad5124dcc6c47a2fad01acd16f71a mentioned in a bug report and the bug might be something fixable there too. For now I'm out of ideas. An X.org expert would be welcome to investigate, since most probably the bug is either in libxcb itself or the Qt's xcb plugin. ** Changed in: qtbase-opensource-src (Ubuntu) Assignee: Timo Jyrinki (timo-jyrinki) = (unassigned) -- You received this bug notification because you are a member of Ubuntu-X, which is subscribed to libxcb in Ubuntu. https://bugs.launchpad.net/bugs/1318584 Title: qt crashed when switching video out mode to external or internal only mode To manage notifications about this bug go to: https://bugs.launchpad.net/checkbox-gui/+bug/1318584/+subscriptions ___ Mailing list: https://launchpad.net/~ubuntu-x-swat Post to : ubuntu-x-swat@lists.launchpad.net Unsubscribe : https://launchpad.net/~ubuntu-x-swat More help : https://help.launchpad.net/ListHelp