Bug 366689 - kwin_wayland segfault ... error 4 in libQt5Qml.so.5.7.0
Summary: kwin_wayland segfault ... error 4 in libQt5Qml.so.5.7.0
Status: RESOLVED WORKSFORME
Alias: None
Product: kwin
Classification: Plasma
Component: wayland-generic (show other bugs)
Version: 5.7.3
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords: triaged
Depends on:
Blocks:
 
Reported: 2016-08-12 04:21 UTC by James
Modified: 2018-10-27 03:58 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description James 2016-08-12 04:21:08 UTC
Is this necessarily a qt bug?

Running startplasmacompositor, the desktop appears and the applications seem to start normally,  but then immediately, the mouse cursor freezes and startplasmacompositor exits.  This has been happening across several recent versions of kwin, but since it is not going away, I'm reporting the bug.  This is on a Radeon 5570 multi-head display.

The system log only has:
kernel: kwin_wayland[560]: segfault at 7fc4c433 ip 00007fc4d9ea6980 sp 00007ffca1c20d80 error 4 in libQt5Qml.so.5.7.0[7fc4d9bee000+3dd000]
 ...
 Stack trace of thread 560:
 #0  0x00007fc4d9ea6980 n/a (n/a)

This is followed by a segfault in kactivitymanagerd:
kernel: kactivitymanage[591]: segfault at 7f03a6361cf0 ip 00007f03a6379ce1 sp 00007ffd45982768 error 4 in libQt5Sql.so.5.7.0[7f03a6363000+46000]


Reproducible: Always
Comment 1 Martin Flöser 2016-08-12 06:59:01 UTC
Can you get the complete backtrace? Otherwise we cannot see anything from that except that it crashes in Qt.
Comment 2 James 2016-08-12 10:14:29 UTC
Thanks.  If you tell me how to get the backtrace, I'll give it a shot.  Everything and the only thing that "systemd-coredump" put in the system log was that single line

 systemd-coredump[996]: Process 560 (kwin_wayland) of user 1000 dumped core.
 Stack trace of thread 560:
 #0  0x00007fc4d9ea6980 n/a (n/a)

This was followed by

systemd-coredump[1025]: Process 591 (kactivitymanage) of user 1000 dumped core.

Stack trace of thread 591:
#0  0x00007f03a6379ce1 _ZN12QSqlDatabase5closeEv (libQt5Sql.so.5)
#1  0x00007f03a637c359 _ZN12QSqlDatabaseD1Ev (libQt5Sql.so.5)
#2  0x00007f03a637f04d n/a (libQt5Sql.so.5)
#3  0x00007f03c7dc2109 _ZN9QHashData11free_helperEPFvPNS_4NodeEE (libQt5Core.so.5)
#4  0x00007f03a6379a37 n/a (libQt5Sql.so.5)
#5  0x00007f03c75c6990 __run_exit_handlers (libc.so.6)
#6  0x00007f03c75c69ea exit (libc.so.6)
#7  0x00007f03be8364ce _ZN15QtWaylandClient15QWaylandDisplay13exitWithErrorEv (libQt5WaylandC
#8  0x00007f03be836526 _ZN15QtWaylandClient15QWaylandDisplay13flushRequestsEv (libQt5WaylandC
#9  0x00007f03c7f694e9 _ZN11QMetaObject8activateEP7QObjectiiPPv (libQt5Core.so.5)
#10 0x00007f03c7fe3c6e _ZN15QSocketNotifier9activatedEiNS_14QPrivateSignalE (libQt5Core.so.5)
#11 0x00007f03c7f76192 _ZN15QSocketNotifier5eventEP6QEvent (libQt5Core.so.5)
#12 0x00007f03c8c6fe3c _ZN19QApplicationPrivate13notify_helperEP7QObjectP6QEvent (libQt5Widge
#13 0x00007f03c8c775b1 _ZN12QApplication6notifyEP7QObjectP6QEvent (libQt5Widgets.so.5)
#14 0x00007f03c7f3dc80 _ZN16QCoreApplication15notifyInternal2EP7QObjectP6QEvent (libQt5Core.s
#15 0x00007f03c7f92a2d n/a (libQt5Core.so.5)
#16 0x00007f03c49eedd7 g_main_context_dispatch (libglib-2.0.so.0)
#17 0x00007f03c49ef040 n/a (libglib-2.0.so.0)
#18 0x00007f03c49ef0ec g_main_context_iteration (libglib-2.0.so.0)
#19 0x00007f03c7f9259b _ZN20QEventDispatcherGlib13processEventsE6QFlagsIN10QEventLoop17Proces
#20 0x00007f03c7f3c0da _ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE (libQt5Core.so.5
#21 0x00007f03c7f445cc _ZN16QCoreApplication4execEv (libQt5Core.so.5)
#22 0x00000000004111d1 main (kactivitymanagerd)
#23 0x00007f03c75b1291 __libc_start_main (libc.so.6)
#24 0x0000000000411459 _start (kactivitymanagerd)

Stack trace of thread 592:
#0  0x00007f03c767048d poll (libc.so.6)
#1  0x00007f03c49eefd6 n/a (libglib-2.0.so.0)
#2  0x00007f03c49ef0ec g_main_context_iteration (libglib-2.0.so.0)
#3  0x00007f03c7f9257f _ZN20QEventDispatcherGlib13processEventsE6QFlagsIN10QEventLoop17Proces
#4  0x00007f03c7f3c0da _ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE (libQt5Core.so.5
#5  0x00007f03c7d5f0f3 _ZN7QThread4execEv (libQt5Core.so.5)
#6  0x00007f03c88a6e75 n/a (libQt5DBus.so.5)
#7  0x00007f03c7d63d78 n/a (libQt5Core.so.5)
#8  0x00007f03c62cc454 start_thread (libpthread.so.0)
#9  0x00007f03c76797df __clone (libc.so.6)

Stack trace of thread 593:
#0  0x00007f03c767048d poll (libc.so.6)
#1  0x00007f03c49eefd6 n/a (libglib-2.0.so.0)
#2  0x00007f03c49ef0ec g_main_context_iteration (libglib-2.0.so.0)
#3  0x00007f03c7f9259b _ZN20QEventDispatcherGlib13processEventsE6QFlagsIN10QEventLoop17Proces
#4  0x00007f03c7f3c0da _ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE (libQt5Core.so.5
#5  0x00007f03c7d5f0f3 _ZN7QThread4execEv (libQt5Core.so.5)
#6  0x000000000041355a _ZZ12runInQThreadI9ResourcesEPT_vEN6Thread3runEv (kactivitymanagerd)
#7  0x00007f03c7d63d78 n/a (libQt5Core.so.5)
#8  0x00007f03c62cc454 start_thread (libpthread.so.0)
#9  0x00007f03c76797df __clone (libc.so.6)

Stack trace of thread 594:
#0  0x00007f03c767048d poll (libc.so.6)
#1  0x00007f03c49eefd6 n/a (libglib-2.0.so.0)
#2  0x00007f03c49ef0ec g_main_context_iteration (libglib-2.0.so.0)
#3  0x00007f03c7f9257f _ZN20QEventDispatcherGlib13processEventsE6QFlagsIN10QEventLoop17Proces
#4  0x00007f03c7f3c0da _ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE (libQt5Core.so.5
#5  0x00007f03c7d5f0f3 _ZN7QThread4execEv (libQt5Core.so.5)
#6  0x000000000041358a _ZZ12runInQThreadI10ActivitiesEPT_vEN6Thread3runEv (kactivitymanagerd)
#7  0x00007f03c7d63d78 n/a (libQt5Core.so.5)
#8  0x00007f03c62cc454 start_thread (libpthread.so.0)
#9  0x00007f03c76797df __clone (libc.so.6)

Stack trace of thread 595:
#0  0x00007f03c767048d poll (libc.so.6)
#1  0x00007f03c49eefd6 n/a (libglib-2.0.so.0)
#2  0x00007f03c49ef0ec g_main_context_iteration (libglib-2.0.so.0)
#3  0x00007f03c7f9259b _ZN20QEventDispatcherGlib13processEventsE6QFlagsIN10QEventLoop17Proces
#4  0x00007f03c7f3c0da _ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE (libQt5Core.so.5
#5  0x00007f03c7d5f0f3 _ZN7QThread4execEv (libQt5Core.so.5)
#6  0x00000000004135ba _ZZ12runInQThreadI8FeaturesEPT_vEN6Thread3runEv (kactivitymanagerd)
#7  0x00007f03c7d63d78 n/a (libQt5Core.so.5)
#8  0x00007f03c62cc454 start_thread (libpthread.so.0)
#9  0x00007f03c76797df __clone (libc.so.6)
Comment 3 Martin Flöser 2016-08-12 11:25:03 UTC
In case you use an aurorae window decoration: switch to breeze.
Comment 4 James 2016-08-12 16:30:59 UTC
I'm not sure about aurorae decorations, but I opened system settings in  regular X Windows KDE, selected Workspace Theme / Look And Feel, and selected "Breeze" instead of "Oxygen".  Then I logged-out of KDE and logged-out of my virtual terminal - which terminates most of my  session processes - then logged-in again at the virtual terminal, and ran startplasmacompositor.  KDE opened with the new window decoration colors, but otherwise I get the same exact freeze and shutdown as before.  Checking the system log, I see the same segfaults for kwin_wayland and kactivitymanagerd, except that this time I also see

systemd-coredump[12180]: Process 12168 (drkonqi) of user 1000 dumped core.

Stack trace of thread 12168:
#0  0x00007fd18d66e04f raise (libc.so.6)
#1  0x00007fd18d66f47a abort (libc.so.6)
#2  0x00007fd18ddf44a1 _ZNK14QMessageLogger5fatalEPKcz (libQt5Core.so.5)
#3  0x00007fd1816e858e _ZN14QXcbConnectionC1EP19QXcbNativeInterfacebjPKc (libQt5XcbQpa.so.5)
#4  0x00007fd1816eb74e _ZN15QXcbIntegrationC1ERK11QStringListRiPPc (libQt5XcbQpa.so.5)
#5  0x00007fd1819ab32d n/a (libqxcb.so)
#6  0x00007fd18e52104d _ZN27QPlatformIntegrationFactory6createERK7QStringRK11QStringListRiPP
#7  0x00007fd18e52f252 _ZN22QGuiApplicationPrivate25createPlatformIntegrationEv (libQt5Gui.s
#8  0x00007fd18e52fced _ZN22QGuiApplicationPrivate21createEventDispatcherEv (libQt5Gui.so.5)
#9  0x00007fd18dfee3bf _ZN23QCoreApplicationPrivate4initEv (libQt5Core.so.5)
#10 0x00007fd18e5317af _ZN22QGuiApplicationPrivate4initEv (libQt5Gui.so.5)
#11 0x00007fd18ecccae9 _ZN19QApplicationPrivate4initEv (libQt5Widgets.so.5)
#12 0x000000000041c659 n/a (drkonqi)
#13 0x00007fd18d65b291 __libc_start_main (libc.so.6)
#14 0x000000000041d6e9 _start (drkonqi)

But then, there is no similar kernel log message about a drkonqi segfault, as there is for kwin_wayland and  kactivitymanagerd.
Comment 5 Martin Flöser 2016-08-13 11:17:51 UTC
I meant Systemsettings -> Application Style -> Window Style
Comment 6 James 2016-08-13 22:54:03 UTC
Success!

Actually, there is no "Window Style", but instead, there are  "Widget Style" and  "Window Decorations" menu items.  I just then changed everything I could find to "Breeze", and that worked.

I then tried to isolate the issue by turning the various selections *back* to non-Breeze settings, but there was nothing definite that seemed to make kwin_wayland segfault on start-up again.  Instead, there seemed to be a "land-mine" of various window actions that could segfault kwin_wayland.  For instance, dragging a window to another virtual desktop, or selecting another window after changing the Application Style settings.  I won't go into the particulars unless you think it will be useful.  You already know that kwin_wayland is still "fragile".

I was able to re-order my monitors - left to right - so congratulations there!  I also noticed that, while moving windows, the window will display on only one of the monitors while moving, and not on the other two.  I don't know if there is a one-to-one relationship between "screens" and "monitors" these days, of if those terms actually apply in a Wayland context - if you could comment on that?

The most awkward thing I've noticed in wanting to use kwin_wayland day-to-day is the number of extra mouse clicks required to simply cut and paste.  When cut and paste gets automated, kwin_wayland will become much more "approachable".

Thanks Martin!  Go ahead and close this if you think that's appropriate.
Comment 7 Martin Flöser 2016-08-15 05:41:19 UTC
> I won't go into the particulars unless you think it will be useful.

Yes please do. I need to know the conditions which don't work. Fixing those is mostly trivial, I just need to know what doesn't work.
Comment 8 James 2016-08-15 14:42:13 UTC
Ha!  Ok - thanks Martin.  This is going to turn into a long, one by one, set of issues, I suspect.

First - tell me, do you want to deal with making non-Breeze theming work right now?  The problem set changes with the theming configuration.  And you may need to clue me in to any issues which you already know are caused by Qt, so I can avoid raising those issues.

And while we're here, do you want to deal with konsole specific issues now?
Comment 9 James 2016-08-15 14:46:30 UTC
Oh - and do you want to deal with cut and paste right now?  Gnome claims to have solved the middle button paste function.

With the theming, let's decide on a baseline configuration, for the purpose of testing.
Comment 10 Martin Flöser 2016-08-16 12:23:21 UTC
>  And while we're here, do you want to deal with konsole specific issues now?

No. If you see konsole specific bugs, please report them against Konsole. I cannot track client specific bugs in KWin. Same for all other clients.

> Oh - and do you want to deal with cut and paste right now? Gnome claims to have solved the middle button paste function.

Yes they have an own extension.

> With the theming, let's decide on a baseline configuration, for the purpose of testing.

Please stay on breeze. We have random crashers in Aurorae unfortunately due to Qt.
Comment 11 James 2016-08-26 21:29:06 UTC
Ok - hopefully something simple:

While dragging a window, the dragged window is visible only on the "first" display, and is not visible on the second or third display.  The window becomes visible again when the mouse button is released. 

Also, the dragged window may appear to be "under" another window and not seen while dragging, but not always.

A dragged window should always be visible.
Comment 12 Martin Flöser 2016-08-29 09:19:44 UTC
> A dragged window should always be visible.

Please don't post multiple issues in the same bug report. This makes it really difficult to track what this bug report is about. Please report a new issue for this problem.
Comment 13 Andrew Crouthamel 2018-09-26 22:09:10 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information as soon as possible and set the bug status as REPORTED. Due to regular bug tracker maintenance, if the bug is still in NEEDSINFO status with no change in 30 days, the bug will be closed as RESOLVED > WORKSFORME due to lack of needed information.

For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please set the bug status as REPORTED so that the KDE team knows that the bug is ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 14 Andrew Crouthamel 2018-10-27 03:58:06 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least 30 days. The bug is now closed as RESOLVED > WORKSFORME due to lack of needed information.

For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!