KIconLoader: reduce number of lookups when doing fallbacks

Review Request #128514 - Created July 24, 2016 and submitted

Information
David Faure
kiconthemes
master
Reviewers
kdeframeworks
cfeck
In the first pass, we already checked whether the icon exists in all icon themes.
So in the second pass, there's no point in starting with that again, we can go
ahead and start doing fallbacks right away.

(The comment about the two passes was removed in b84858c, but some of it still
applies.)

Tested with: strace -e file ./kiconengine_unittest testUnknownIconNotCached |& wc -l
Before: 6341
After: 4589

strace as mentionned above.

All unittests still pass (incl fallback lookups, didn't check how complete those were, though)

Issues

  • 1
  • 0
  • 1
  • 2
Description From Last Updated
This is not correct. When you have genericFallback && !currentName.empty() you never reach line 1071 to get an icon. So ... Anthony Fieroni Anthony Fieroni
Christoph Feck
Christoph Feck
Anthony Fieroni
Christoph Feck
Aleix Pol Gonzalez
David Faure
David Faure
Christoph Feck
David Faure
Review request changed

Status: Closed (submitted)

Change Summary:

Submitted with commit 757afa83ac74c51421cf16bcc44d53623bcfa908 by David Faure to branch master.
Loading...