Summary: | dolphin slow causes high cpu usage when copying files | ||
---|---|---|---|
Product: | [Frameworks and Libraries] kio | Reporter: | tim blechmann <tim> |
Component: | general | Assignee: | David Faure <faure> |
Status: | RESOLVED FIXED | ||
Severity: | wishlist | CC: | biasquez, jessie, peter.penz19, sailorweb2, toresoft |
Priority: | NOR | ||
Version: | 4.5 | ||
Target Milestone: | --- | ||
Platform: | Ubuntu | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | 4.7.2 | |
Attachments: |
high cpu on dual core
High i/o wait when copying file only with dolphin |
Description
tim blechmann
2010-12-01 17:50:59 UTC
same issue in kde 4.6.1 *** Bug 243237 has been marked as a duplicate of this bug. *** Created attachment 57801 [details]
high cpu on dual core
Created attachment 57802 [details]
High i/o wait when copying file only with dolphin
Same issue in KDE 4.6.2 with Kubuntu 11.04. Dolphin is using full cpu and file copying is very slow. *** This bug has been confirmed by popular vote. *** Same issue in KDE 4.7.0 with OpenSuse 11.4 (kernel 3.0). Why "wishlist"? IMO this is a bug with "normal" severity. Git commit 2cd2d1a4cfa1226f959047bd4a0a429382056f19 by Andreas Hartmetz. Committed on 21/09/2011 at 04:03. Pushed by ahartmetz into branch 'KDE/4.7'. Undo manager: Don't prepend() to a QVector which can contain many, many items. Use a QList instead. A QStack is a QVector, which has an O(n) prepend method. Conceptually it is a stack, but not always used like one, so I haven't renamed the typedefs, so the code looks a bit (more) confusing now. Sorry about that. I noticed that copying several 100k files slowed down to just a few files a second and found that most of the time was spent in QVector<KIO::BasicOperation>::prepend(), called from KIO::CommandRecorder::slotCopyingDone(). Another problem is memory usage, which was a few hundred megabytes. This patch does not fix memory usage because I have a lot of memory and it's a difficult problem :) BUG: 257907 BUG: 258497 CCBUG: 280088 M +9 -9 kio/kio/fileundomanager.cpp M +2 -2 kio/kio/fileundomanager_p.h http://commits.kde.org/kdelibs/2cd2d1a4cfa1226f959047bd4a0a429382056f19 are you sure that it fixes the problem, that i originally reported? possibly some part of the kdelibs changed since my original report, but my profiling showed that most of the time was spent in QUrl::operator=(QUrl const&). this does not seems to be addressed in the patch. Yes, I'm sure. There are BasicOperations in the vector, which contain two URLs. Moving around the BasicOperations in QVector::prepend() involves BasicOperation::operator=(), which uses QUrl::operator=(). If you think about it, there were only two possibilities: QUrl::operator=() is extremely slow - unlikely because Qt has enough users who would have noticed. Or it is called very often for no good reason. That is what happened here. ah, wonderful, great, thanks!!! I just upgraded to 4.7.2 to see if this fixed it, and it appeared to. My CPU usage still went up when copying files, but not anywhere near where it used to. Thanks! |