Ideas for improving sorting. Goal: under 1 second for 200.000 files.
Christoph Feck
christoph at maxiom.de
Wed Oct 24 00:22:00 BST 2012
On Wednesday 24 October 2012 01:13:40 Christoph Feck wrote:
> Speed of comparing the sequences is that of a memcpy()
Of course I meant memcmp().
> So what you have to work on before doing anything else, is to ask
> Frank, if he is okey with adding a sort key (QByteArray basically)
> for each file item. Your code would have to make sure it is always
> updated on file renames, locale changes, sort mode changes
> (natural vs. simple) etc.
Another idea is to not store this side information "permanently", but
only create it temporarily when sorting. So you effectively only sort
a list with side information.
struct SortEntry
{
QByteArray collatingKey;
KFileItem *fileItem;
};
Christoph Feck (kdepepo)
More information about the kfm-devel
mailing list