topcontexts

Milian Wolff mail at milianw.de
Mon Apr 9 11:23:12 UTC 2018


On Saturday, April 7, 2018 10:33:53 AM CEST René J.V. Bertin wrote:
> Hi,
> 
> I hadn't run my kdevelop cache cleanup script for a while (on my Mac) and
> when I did so the other day it spent a minute or more just deleting all
> topcontexts directories. A good reminder why I delete them in the 1st
> place: they're full of often tiny files which slow down the HFS directory
> compression tool significantly. By extension it doesn't seem far-fetched to
> assume the current implementation must have some negative impact on overal
> performance in KDevelop too. I can't back that up, of course;

Without a profile, this is very far fetched to me. mmapping a small file is 
super fast, if you compress the dir and do other stuff to it, then you are on 
your own and have to live with the caveats of these approaches.

> the only way I can think of not to use those topcontexts files is to empty 
and  write-protect the topcontexts directories.

Wich would of course completely break KDevelop.

> Anyway: normally I'm all for database approaches that use the filesystem but
> I can't help but wonder in this case if it wouldn't be more efficient to
> store this information via one of the lightweight database libraries that
> have been appearing (leveldb, lmdb). Would that make sense here?

Yes and no. Yes for non-performance related reasons such as cross-process 
support. No for performance related reasons (the current approach, while old, 
is *exactly* what the DUChain code built around it needs - no wonder it beats 
the other generic solutions).

Bye

-- 
Milian Wolff
mail at milianw.de
http://milianw.de




More information about the KDevelop-devel mailing list