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

Andreas Pakulat apaku at gmx.de
Mon Apr 6 21:43:16 UTC 2009


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


How deep was your test tree? I suggest to take a directory hierarchy thats at least 100 levels deep (counted from the .git directory, not '/') as "worst case" scenario.


/trunk/KDE/kdevplatform/plugins/git/gitplugin.cpp
<http://reviewboard.kde.org/r/532/#comment533>

    Did you verify that cdUp() returns false when hitting '/'?


- Andreas


On 2009-04-06 11:08:09, Fabian Wiesel wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://reviewboard.kde.org/r/532/
> -----------------------------------------------------------
> 
> (Updated 2009-04-06 11:08:09)
> 
> 
> 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.cpp 950241 
> 
> Diff: http://reviewboard.kde.org/r/532/diff
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Fabian
> 
>





More information about the KDevelop-devel mailing list