[cmake-developers] dependency scanning speed

Matt Rogers mattr at kde.org
Sat Sep 9 19:19:12 EDT 2006


On Saturday 09 September 2006 16:57, Alexander Neundorf wrote:
> Hi,
>
> today I compiled unity (khtml ported to WebKit ported back to KDE) on a
> Pentium 4 1.8 GHz, 512 MB RAM notebook.
>
> Dependency scanning takes approx. 30 seconds for the WebCore subdir there.
> At http://www.neundorf.net/cmake/unity you can find the cmake files for
> this directory. As you can see they are BIG. build.make is 2 MB,
> depend.make is 10 MB.
> Any ideas how the scanning could be made faster ?
> includecache.C and includecache.CXX cache the #includes, so only the files
> which have really changed are scanned again. Then the dependencies for all
> files are calculated again.
> I see two things (but I didn't measure):
> -save/load the cache files faster: is there a way to write/read a map more
> faster ?
> -cache which files are checked during the dependency checking.
> Then when checking the next time, at first check which of these files have
> changed. Then for each file, load which files it depends on, and only
> calculate the dependencies new if if any of the depend files have changed.
> I'm not sure the logic is right and how much it could gain.
>
> What do you think ?
>
> Bye
> Alex

did you use valgrind's callgrind tool to profile this? I think you'll really 
get more concrete data on what's taking up the most time by using that 
tool. :)
-- 
Matt



More information about the cmake-developers mailing list