Commit a462bee
submodule: suppress checking for file name and ref ambiguity for object ids
The argv argument of collect_changed_submodules() contains only object ids
(the objects references of all the refs).
Notify setup_revisions() that the input is not filenames by passing
assume_dashdash, so it can avoid redundant stat for each ref.
Also suppress refname_ambiguity flag to avoid filesystem lookups for
each object. Similar logic can be found in cat-file, pack-objects and more.
This change reduces the time for git fetch in my repo from 25s to 6s.
Signed-off-by: Orgad Shaneh <orgads@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>1 parent 3a238e5 commit a462bee
1 file changed
+8
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
840 | 840 | | |
841 | 841 | | |
842 | 842 | | |
| 843 | + | |
| 844 | + | |
| 845 | + | |
| 846 | + | |
843 | 847 | | |
| 848 | + | |
| 849 | + | |
844 | 850 | | |
845 | | - | |
| 851 | + | |
| 852 | + | |
846 | 853 | | |
847 | 854 | | |
848 | 855 | | |
| |||
0 commit comments