Ideas for improving sorting. Goal: under 1 second for 200.000 files.

Mark markg85 at gmail.com
Sat Dec 8 15:30:04 GMT 2012


On Sat, Dec 8, 2012 at 10:05 AM, David Faure <faure at kde.org> wrote:
> On Tuesday 23 October 2012 14:38:43 Mark wrote:
>> 2.3 Pass around QChar* and get rid of QString
>> -------------------
>> Right now naturalCompare takes two QString arguments while it
>> internally grabs a QChar* from the string. I'm not sure here, but i
>> think you save some time if you prevent QString passing around and
>> simply pass around QChar* then i imagine that you have a lot less
>> unicode since the string arrays are already in unicode. That might be
>> another (small?) speed improvement i guess.
>
> This makes no sense, given that QString is really just a wrapper around
> QChar* to add API on top.
> "You have a lot less unicode" makes no sense, both QString and QChar* are
> unicode data.
>
> There is no speed improvement to be gained by not calling this method:
> inline const QChar *QString::unicode() const
> { return reinterpret_cast<const QChar*>(d->data); }
> -> no work is done here.
>
> --
> David Faure, faure at kde.org, http://www.davidfaure.fr
> Working on KDE, in particular KDE Frameworks 5
>

Ohh, i'm long past that point. I'm fighting the collation sequence
stuff now. It's working fairly well, but a few values always seem to
fall outside the logic there.. I will get there since i nearly am
already, but the last part to get it fully working is very tricky.




More information about the kfm-devel mailing list