Bug 355458 - kwin_x11 sometimes uses 100% cpu
Summary: kwin_x11 sometimes uses 100% cpu
Status: RESOLVED WORKSFORME
Alias: None
Product: kwin
Classification: Plasma
Component: core (show other bugs)
Version: 5.4.3
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-11-16 23:22 UTC by nazgul17@gmail.com
Modified: 2020-12-22 04:34 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
See bug report (glamor) (100 bytes, text/plain)
2015-11-16 23:23 UTC, nazgul17@gmail.com
Details
See bug report (qbus) (5.16 KB, text/plain)
2015-11-16 23:24 UTC, nazgul17@gmail.com
Details
See bug report (gdb) (31.30 KB, text/plain)
2015-11-16 23:25 UTC, nazgul17@gmail.com
Details
gdb for all threads (27.81 KB, text/plain)
2015-11-17 03:58 UTC, nazgul17@gmail.com
Details

Note You need to log in before you can comment on or make changes to this bug.
Description nazgul17@gmail.com 2015-11-16 23:22:56 UTC
I am using Kubuntu 15.10 with kwin 5.4.3.

I am not sure how to replicate this.. it just happens from time to time.

Here are some additional information (found the commands to get them on https://bugs.kde.org/show_bug.cgi?id=340294 but I don't really know what these are)

$ grep -i glamor /var/log/Xorg.0.log` > glamor_kwin.txt
$ qdbus org.kde.KWin /KWin supportInformation > qdbus_kwin.txt
[press Ctrl+Alt+F1]
[login] # this will allow you to attach gdb to kwin
$ echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope # run gdb, log to "kwin.gdb"
$ gdb --pid `pidof kwin` 2>&1 | tee gdb_kwin.txt
# you're not in the gdb prompt ">"
> bt [enter, enter, enter, ... until there's no more output]
> detach
> quit
$ exit
[press Ctrl+Alt+F7]

Reproducible: Didn't try

Steps to Reproduce:
1. Login
2. Do stuff
3. Flip a coin: sometimes the problem happens
Comment 1 nazgul17@gmail.com 2015-11-16 23:23:37 UTC
Created attachment 95547 [details]
See bug report (glamor)
Comment 2 nazgul17@gmail.com 2015-11-16 23:24:11 UTC
Created attachment 95548 [details]
See bug report (qbus)
Comment 3 nazgul17@gmail.com 2015-11-16 23:24:37 UTC
(In reply to Marco T. from comment #1)
> Created attachment 95547 [details]
> See bug report

(glamor)
Comment 4 nazgul17@gmail.com 2015-11-16 23:25:03 UTC
Created attachment 95549 [details]
See bug report (gdb)
Comment 5 Thomas Lübking 2015-11-16 23:42:19 UTC
The stacktrace shows a dormant thread.
If this was dumped while the process was hich loading, the load will be in another thread.
The stacktrace will only be of value if the system is loaded at that time.
In case, switch the threads in gdb:
> thread 2
> bt
> thread 3
> bt
> thread 4
> bt
... until you get "Thread ID <n> not known."


Wild guess: is the CPU load related to switching the virtual terminal?
Comment 6 nazgul17@gmail.com 2015-11-17 03:58:38 UTC
Created attachment 95553 [details]
gdb for all threads
Comment 7 nazgul17@gmail.com 2015-11-17 03:59:29 UTC
Sorry about that; it's exactly what I meant by "I don't really know what these are". I hope the new file helps.
Comment 8 Martin Flöser 2015-11-17 07:59:32 UTC
just a hint for future:
"t a a bt" gives one all thread backtraces.
Comment 9 Thomas Lübking 2015-11-17 08:51:58 UTC
Threads 2 & 3 may lock each other, unfortunately Qt has no debug symbols (you typically need to install the *-dev packages on debian based distros)

Since it's QtQuick and you're not using an aurorae deco: can you relate this to some circumstances (you referenced a bug in the tabbox QML => alt+tab related?)
Comment 10 nazgul17@gmail.com 2015-11-17 13:12:48 UTC
On top of my head, I cannot come up with any explanation. Tomorrow I will do a few of the usual things and see which one triggers the problem. What -dev packages should I install to make the reports more useful?
Comment 11 Thomas Lübking 2015-11-17 17:20:51 UTC
qt5-quick1
qt5-quickcontrols 5.5.1-3
qt5-script

They might have slightly different names, though (no ubuntu here)
Comment 12 Martin Flöser 2015-11-18 07:37:46 UTC
and you need the -dbg not -dev packages.
Comment 13 Thiago Sueto 2020-11-22 04:34:35 UTC
Hello Nazgul, it seems you were pending a better backtrace. Is this issue still reproducible for you with newer Plasma? If it's still somehow reproducible you can follow the instructions of the Kubuntu wiki to provide a better backtrace: https://wiki.kubuntu.org/Debug%20Symbol%20Packages

Although depending on the package manager integration gdb itself might provide you with the correct command to install the missing debug packages.
Comment 14 Bug Janitor Service 2020-12-07 04:34:04 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
mark the bug 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 15 Bug Janitor Service 2020-12-22 04:34:52 UTC
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!