Commit 24fcacc
fetch-pack.c: enable fscache for stats under .git/objects
When I do git fetch, git call file stats under .git/objects for each
refs. This takes time when there are many refs.
By enabling fscache, git takes file stats by directory traversing and that
improved the speed of fetch-pack for repository having large number of
refs.
In my windows workstation, this improves the time of `git fetch` for
chromium repository like below. I took stats 3 times.
* With this patch
TotalSeconds: 9.9825165
TotalSeconds: 9.1862075
TotalSeconds: 10.1956256
Avg: 9.78811653333333
* Without this patch
TotalSeconds: 15.8406702
TotalSeconds: 15.6248053
TotalSeconds: 15.2085938
Avg: 15.5580231
Signed-off-by: Takuto Ikuta <[email protected]>
Signed-off-by: Johannes Schindelin <[email protected]>1 parent 7468ac1 commit 24fcacc
1 file changed
+2
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
760 | 760 | | |
761 | 761 | | |
762 | 762 | | |
| 763 | + | |
763 | 764 | | |
764 | 765 | | |
765 | 766 | | |
| |||
784 | 785 | | |
785 | 786 | | |
786 | 787 | | |
| 788 | + | |
787 | 789 | | |
788 | 790 | | |
789 | 791 | | |
| |||
0 commit comments