If you disable scanning for untracked files, of course it’ll be faster. While they both hit the roof on total blob size, note that chromium scores much higher across the board in other areas too. | * Total size of files | 2.62 GiB | ** | | * Number of directories | 4.46 k | ** |Īnd here’s chromium/chromium: | Name | Value | Level of concern | Here’s torvalds/linux: | Name | Value | Level of concern | “Large” has many dimensions when it comes to a git repository – git-sizer is a useful tool for looking at a bunch of them. gitstatusd received another 2.6x speedup after I reimplemented the core algorithm from scratch on top of a different inmemory index data structure. These changes are in my libgit2 fork on github. To make it faster, I kept optimizing libgit2 and eventually achieved 18x speedup over the original. In fact, gitstatusd has started as a simple binary built on libgit2 API. libgit2 and git could be just as fast if they used the same data structures and algorithms as gitstatusd. There is no cheap trick in gitstatusd or a simple explanation that accounts for its lead in performance over the standard alternatives. gitstatusd solves the problem 46.3 times faster due to having more efficient userland code using cheaper system calls and making fewer of them and engaging all available CPU cores. Why fast section is a true orange-to-orange comparison of gitstatusd and libgit2 where they do the same work under the same constraints. Perhaps it’s hooking all filesystem accesses, or maybe it’s refreshing repository state in the background and then serving precomputed results when requested? This is not the case. | - | - |įor more improvment (set in Git 2.17, Q2 2018), see this answer.By the way, it may appear that gitstatusd is faster than git and libgit2 because it’s a daemon. This can have a significant improvement in 'git status -ignored' performance in repositories with a large number of files in ignored directories.įor an example of the performance difference on an example repository withġ96,000 files in 400 ignored directories: | Command | Time (s) | This change introduces the optimization to stop iterating through the contents once it finds the first file. In order to show non-empty ignored directories, the existing logic will recursively iterate through all contents of an ignored directory. Improve the performance of the directory listing logic when it wants to list non-empty ignored directories. (Merged by Junio C Hamano - gitster - in commit 075bc9c, ) Improve performance of git status -ignored See commit 5aaa7fd () by Jameson Miller ( jamill). The codepath has been optimized to avoid this overhead. Tracked path is ignored, still enumerated all the ignored paths in " git status -ignored", when noticing that a directory without any For files you do not version, see also " UNTRACKED FILES AND PERFORMANCE" with git status.Īnother aspect of git status which will be improved (in Git 2.14.x/2.15, Q4 2017) is when it shows ignored files as well ( git status -ignored)
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |