diff options
author | Junio C Hamano <junkio@cox.net> | 2005-05-04 01:45:24 -0700 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2005-05-04 01:45:24 -0700 |
commit | b46f0b6dfd09629645efc59cda76e7e4fad7ca39 (patch) | |
tree | 74a490c6a742801a5318f8c5a8be153a99d74e4b /commit-tree.c | |
parent | 6fa28064b0c9da9c2c8696b4eac28ee5beaee469 (diff) | |
download | git-b46f0b6dfd09629645efc59cda76e7e4fad7ca39.tar.gz git-b46f0b6dfd09629645efc59cda76e7e4fad7ca39.tar.xz |
Optimize diff-cache -p --cached
This patch optimizes "diff-cache -p --cached" by avoiding to
inflate blobs into temporary files when the blob recorded in the
cache matches the corresponding file in the work tree. The file
in the work tree is passed as the comparison source in such a
case instead.
This optimization kicks in only when we have already read the
cache this optimization and this is deliberate. Especially,
diff-tree does not use this code, because changes are contained
in small number of files relative to the project size most of
the time, and reading cache is so expensive for a large project
that the cost of reading it outweighs the savings by not
inflating blobs.
Also this patch cleans up the structure passed from diff clients
by removing one unused structure member.
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'commit-tree.c')
0 files changed, 0 insertions, 0 deletions