Disk usage optimizations

Alexander Neundorf neundorf at kde.org
Tue Feb 22 22:36:34 CET 2005


On Tuesday 22 February 2005 22:25, Waldo Bastian wrote:
...
> Well, from the sound of it, yes :-) It's probably due to the icon loading,
> when a menu is first shown we need to load the icons, and for each icon we
> need to hit the disk. If the IO-system is under load that can take a
> significant time.
>
> For KDE4 it would be nice if we could load icons more efficiently, e.g. if
> we could load all icons for a single menu with one disk access instead of
> 10.
>
> Oh, and did you know that the iconloader tests for 464 different icons
> before deciding that we can't find an icon for gedit? I assume that the
> kernel has cached most of that information already, if it had to hit the
> disk 464 times we would be in deep shit.

Yes, the icon loader looks in very many directories. This takes a lot of time. 
Just reordering icons improved killustrator startup time significantly (like 5 
years ago or something).
There have been several ideas for accelerating icon loading, like a shared 
memory icon server and other stuff.
Maybe creating a binary file which contains the location of all icons, so that 
we don't have to use stat() or access() but just have a look into 
QMap<QString iconDesc, QString path) or something like this. Don't know if 
this would help anything.

Bye
Alex
-- 
Work: alexander.neundorf at jenoptik.com - http://www.jenoptik-los.de
Home: neundorf at kde.org                - http://www.kde.org
      alex at neundorf.net               - http://www.neundorf.net


More information about the Kde-optimize mailing list