Skip to content
Commit 2cd2d1a4 authored by Andreas Hartmetz's avatar Andreas Hartmetz
Browse files

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
parent 18b99d54
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment