New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Zeal makes Xorg use 100% cpu #211
Comments
My guess would be, that there were something wrong with the old global hot key code, as it was the only place where we talked to X directly. That has been removed recently. Hopefully, the problem is gone, but please reopen the report if the issue still persists. |
I have the same problem on my Fedora 20 and 21. I have two cores and everytime I open Zeal and read some docs (this means if I don't open any doc or just open one or two things will be okay), Xorg.bin starts to occupy one of them completely making my machine nearly frozen, and once I quit Zeal everything gets normal. |
@Shihira, what Zeal version did you try? If you build from sources, please give Qt WebEngine a try. Could be enabled with |
@trollixx , yes I just pull the latest commit adee352 and build from source.
I suspected that if I have had some Qt libraries missed but yum search failed to find the word "webengine". |
I built with |
I am still trying to reproduce this problem, but Zeal works pretty stable on my ArchLinux and Ubuntu. @asdrubalivan How did you obtain Qt WebEngine on Fedora? I don't see any packages available for it. Own build or binary from qt.io? |
@trollixx: I used the |
I can install Fedora in VirtualBox, but I am not sure it would reproduce the issue. |
I too am having the same problem on Korora 21 (based on Fedora 21) with Cinnamon desktop. I've built from source from the master branch plus the 0.1 branch + the 0.1.1 tag all with the same problem. If I build with I'm running a well spec'd Dell M3800 (quad core i7) and it really slows the OS down. |
I'd be really happy to hear any ideas about possible causes. I have Fedora 21 installed in VirtualBox, but I cannot reproduce the issue. |
@trollixx I sent you an email with a video attached illustrating how the problem is like on my machine. Hope it helps. Repeatedly dragging scrollbar on the treeView and the search result listView raises CPU usage, no matter how short the list is. In the video we can see my desktop got into slow response and animations were delaying, CPU usage didn't reach 100% though. For clearing the suspicious of Qt, I opened Assistant and dragged repeatedly the listView there, which didn't have any impact. |
@Shihira Thanks! Indeed there's a major slowdown caused by the treeview item delegate. Now I need to figure out how to fix that. For those willing to test, comment out the following line in ui->treeView->setItemDelegate(new SearchItemDelegate(ui->lineEdit, ui->treeView)); |
This avoids additional rendering in SearchItemDelegate when there is nothing to highlight.
I've just pushed a partial fix for the delegate issue. Now it should not cause slowness when no search term is set. |
Thanks! This commit works well while not searching as expected. |
@Shihira What do you mean by |
@trollixx Sorry for my awful English. I'm not a native speaker. Please ignore the two words "as expected". |
@Shihira could you also pull all recent changes from 0.1 branch? It should work much better now even with search results. It would be nice to hear back from multiple people to know whether issue is fixed or not. |
@trollixx I believe that the situation improved, but my system performance still degrades while running Zeal (just not crippled). I will try to provide some more detailed feedback when I can. |
I pulled ab317d0 and recompiled, regretfully, finding the performance problem in searching list is not yet fixed. I know too little about Xorg, but I'm still wondering why the CPU fixed high. Even if the delegate class occupies a large quantity of resources while rendering, CPU usage should have declined after I had the search result cleared. |
That's exactly what I see on my ArchLinux, relatively high (up to 60% on one core) CPU usage while I am doing some insane scrolling, but it drops immediately after I stop. So, the issue only occurs on Fedora as far as I can see, but even there not for everyone. For example, no problems with Zeal running on Fedora 21 in VirtualBox. I would really appreciate any crazy ideas about possible reasons. Perhaps #265 is also related to the same problem. |
I have installed latest 0.1.1 git on Fedora 21 x86_64 with qt5-qtwebkit and qt5-qtx11extras and here are some observations: When typing one letter, the search list comes up pretty fast (<1sec to 2secs max), and CPU usage spikes only briefly then settles. All I can say is maybe it is optimized to look for a single letter, and when typing more letters, the search process for every step of the formation of the word is done to completion before finally showing the list. Is there a way to set a delay before a search process is initiated when starting to type, and/or cancel any previous searches in process? |
Below is some hack I did to lessen the slow search and CPU usage. I just wanted to make the search process not run every time I type a letter, but only when pressing Return or something like that. It still takes 3 to 6 seconds to search all documents, but at least it doesn't multiply the delay by the number of keystrokes. When I also specifiy the document to search, it is instantaneous, e.g. "bash:return".
|
@rajeebk thanks for sharing your research! I have to rewrite several core module to make this issue go away, notably docset indexing and parallel search. Unfortunately, I have no idea when I get enough time for that. |
There have been a lot of improvements made in search logic, UI responsiveness, and list item delegate has been completely rewritten to make it more efficient. I hope we can consider this fixed in the 0.3.0 release, which is coming shortly. |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for a related request. |
I'm on Ubuntu 14.10 and when using Zeal from the ppa, after a few minutes, Xorg starts using 100% cpu.The weird thing is that the zeal process itself doesn't show much cpu usage in top.
The text was updated successfully, but these errors were encountered: