Skip to content

Commit caf388c

Browse files
derrickstoleegitster
authored andcommitted
bloom: ignore renames when computing changed paths
The changed-path Bloom filters record an entry in the filter for every path that was changed. This includes every add and delete, regardless of whether a rename was detected. Detecting renames causes significant performance issues, but also will trigger downloading missing blobs in partial clone. The simple fix is to disable rename detection when computing a changed-path Bloom filter. This should already be disabled by default, but it is good to explicitly enforce the intended behavior. Signed-off-by: Derrick Stolee <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent d5b873c commit caf388c

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

bloom.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,7 @@ struct bloom_filter *get_bloom_filter(struct repository *r,
189189

190190
repo_diff_setup(r, &diffopt);
191191
diffopt.flags.recursive = 1;
192+
diffopt.detect_rename = 0;
192193
diffopt.max_changes = max_changes;
193194
diff_setup_done(&diffopt);
194195

0 commit comments

Comments
 (0)