Review Request: VCS: Speedup the check for non-existant git-repositories

Andreas Pakulat apaku at gmx.de
Thu Apr 9 23:43:41 UTC 2009


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://reviewboard.kde.org/r/532/#review888
-----------------------------------------------------------

Ship it!


I'm not sure its a noticeable speed improvement, however David is right, if we don't need to start an executable, then we shouldn't.

- Andreas


On 2009-04-07 10:00:25, Fabian Wiesel wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://reviewboard.kde.org/r/532/
> -----------------------------------------------------------
> 
> (Updated 2009-04-07 10:00:25)
> 
> 
> Review request for KDevelop.
> 
> 
> Summary
> -------
> 
> In the case that a directory is not under the control of git, a check whether a directory is under version control accounts roughly 40ms of a total 70ms (Peak ~200ms) in the creation of a context menu.
> By first checking for the existence of a .git directory in all parent directories, one avoids the call to an external program.  Should a correctly named directory be found, the external program is still called, which does a more sophisticated check.
> 
> In my limited "benchmark", the additional calling costs seem to be up to 1ms.
> 
> 
> Diffs
> -----
> 
>   /trunk/KDE/kdevplatform/plugins/git/gitplugin.h 950727 
>   /trunk/KDE/kdevplatform/plugins/git/gitplugin.cpp 950727 
>   /trunk/KDE/kdevplatform/plugins/mercurial/mercurialplugin.h 950727 
>   /trunk/KDE/kdevplatform/plugins/mercurial/mercurialplugin.cpp 950727 
> 
> Diff: http://reviewboard.kde.org/r/532/diff
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Fabian
> 
>





More information about the KDevelop-devel mailing list