aboutsummaryrefslogtreecommitdiff
path: root/diffcore.h
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2010-08-13 10:36:01 -0700
committerJunio C Hamano <gitster@pobox.com>2010-08-13 11:01:51 -0700
commit39f75d26e235798681394e46625716c187a4ee3e (patch)
tree013f8c704216ac73b577ace828e4e80a672e0967 /diffcore.h
parent452c6d506b1a6dcf24d4ceaa592afc39c1c1a60e (diff)
downloadgit-39f75d26e235798681394e46625716c187a4ee3e.tar.gz
git-39f75d26e235798681394e46625716c187a4ee3e.tar.xz
diff --follow: do not waste cycles while recursing
The "--follow" logic is called from diff_tree_sha1() function, but the input trees to diff_tree_sha1() are not necessarily the top-level trees (compare_tree_entry() calls it while it recursively descends into subtrees). When a newly created path lives in somewhere deep in the source hierarchy, e.g. "platform/", but the rename source is in a totally different place in the destination hierarchy, e.g. "lang-api/src/com/...", running "try_to_find_renames()" while base is set to "platform/" is a wasted call. We only need to run the rename following at the very top level. Signed-off-by: Junio C Hamano <gitster@pobox.com> Acked-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'diffcore.h')
0 files changed, 0 insertions, 0 deletions