Re: [PATCH 0/3] Un-pessimize "diff-index $commit -- $pathspec"
Junio C Hamano venit, vidit, dixit 29.08.2011 23:33:
Show 5 quoted lines
> "git diff A B -- $pathspec" to compare two tree-ishes knew how to apply
> pathspec to avoid opening trees that fall outside the area of interest,
> but "git diff A -- $pathspec" used unpack_trees() machinery that was meant
> for full-tree merges, and ended up reading the whole tree only to discard
> potentially major part of the work it does.
Seems my analysis wasn't that far off (though, admittedly, unspecific):
MG:
> Well, we have to read the full tree before diffing. But I can't
> I meant: The way "git diff" is now, it does that.
> anything to do with it (iow, your "The way 'git diff' is now, it does
> that" is not just incorrect---we don't read the full tree to begin
> with---but irrelevant).
Anyways, as MR writes:
MR:
> 30s without patch and 0.3s with it. You rock ;)
I agree with all of that ;)
Michael