D11282: less expensive findByUrl in KCoreDirListerCache
Stefan BrĂ¼ns
noreply at phabricator.kde.org
Thu May 17 23:42:01 UTC 2018
bruns added inline comments.
INLINE COMMENTS
> mwolff wrote in kcoredirlister.cpp:2532
> this can be slow, see above
To make this more efficient, a little bit of reshuffling is needed IMHO:
1. Move the filter implementation from `KDL::Private::addNewItem(...)` to `KDL::Private::addNewItems(...)`, i.e. sort the `items` based on `->matchesMimeFilter(item)` into two new QHashes
2. For each partition, use QHash::unite() to merge it into the respective list
3. Make `KDL::Private::addNewItem(...)` a wrapper function for `KDL::Private::addNewItems(...)`.
REPOSITORY
R241 KIO
REVISION DETAIL
https://phabricator.kde.org/D11282
To: jtamate, #frameworks, dfaure
Cc: kde-frameworks-devel, bruns, mwolff, michaelh, ngraham
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20180517/a6f940e3/attachment.html>
More information about the Kde-frameworks-devel
mailing list