diff options
author | Junio C Hamano <gitster@pobox.com> | 2019-05-13 23:50:31 +0900 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2019-05-13 23:50:32 +0900 |
commit | 5b51f0d38d24a21dc69a53e972497928183d399e (patch) | |
tree | f6a2e1ec6e7984f0550c1099bc210dc79627f345 /connected.h | |
parent | 5b2d1c0c6eceb5fd6c9527bc2863179644dce840 (diff) | |
parent | 1bb10d4f7c074ac13a61d6d20be89c2bff9488a4 (diff) |
Merge branch 'js/partial-clone-connectivity-check'
During an initial "git clone --depth=..." partial clone, it is
pointless to spend cycles for a large portion of the connectivity
check that enumerates and skips promisor objects (which by
definition is all objects fetched from the other side). This has
been optimized out.
* js/partial-clone-connectivity-check:
t/perf: add perf script for partial clones
clone: do faster object check for partial clones
Diffstat (limited to 'connected.h')
-rw-r--r-- | connected.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/connected.h b/connected.h index 8d5a6b3ad6..ce2e7d8f2e 100644 --- a/connected.h +++ b/connected.h @@ -46,6 +46,14 @@ struct check_connected_options { * during a fetch. */ unsigned is_deepening_fetch : 1; + + /* + * If non-zero, only check the top-level objects referenced by the + * wanted refs (passed in as cb_data). This is useful for partial + * clones, where enumerating and excluding all promisor objects is very + * slow and the commit-walk itself becomes a no-op. + */ + unsigned check_refs_only : 1; }; #define CHECK_CONNECTED_INIT { 0 } |