From: Al Viro <viro@ftp.linux.org.uk>
To: Linus Torvalds <torvalds@osdl.org>
Cc: Junio C Hamano <junkio@cox.net>,
git@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [ANNOUNCE] GIT 1.4.3
Date: Sat, 21 Oct 2006 03:12:35 +0100 [thread overview]
Message-ID: <20061021021235.GA29920@ftp.linux.org.uk> (raw)
In-Reply-To: <Pine.LNX.4.64.0610201709430.3962@g5.osdl.org>
On Fri, Oct 20, 2006 at 05:14:39PM -0700, Linus Torvalds wrote:
>
>
> On Fri, 20 Oct 2006, Junio C Hamano wrote:
> >
> > I am considering the following to address irritation some people
> > (including me, actually) are experiencing with this change when
> > viewing a small (or no) diff. Any objections?
>
> Not from me. I use "git diff" just to check that the tree is empty, and
> the fact that it now throws me into an empty pager is irritating.
Speaking of irritations... There is a major (and AFAICS fixable)
suckitude in git-cherry. Basically, what it does is
* use git-rev-list to find commits on our branches
* do git-diff-tree -p for each commit
* do git-patch-id on each delta
* compare sets.
For one thing, there are better ways to do set comparison than creating
a file for each element in one set and going through another checking
if corresponding files exist (join(1) and sort(1) or just use perl hashes).
That one is annoying on journalling filesystems (a lot of files being
created, read and removed - fsckloads of disk traffic), but it's actually
not the worst problem.
Far more annoying is that we keep recalculating git-diff-tree -p | git-patch-id
again and again; try to do git cherry on a dozen short branches forked at
2.6.18 and you'll see the damn thing recalculated a dozen of times for
each commit from 2.6.18 to current. It's not cheap, to put it mildly.
git-rev-list ^v2.6.18 HEAD|while read i; do git-diff-tree -p $i; done |git-patch-id >/dev/null
out of hot cache on 2GHz amd64 box (Athlon 64 3400+) takes 3 minutes of
wall time. Repeat that for each branch and it's starting to get old very
fast.
Note that we are calculating a function of commit; it _never_ changes.
Even if we don't just calculate and memorize it at commit time, a cache
somewhere under .git would speed the things up a lot...
next prev parent reply other threads:[~2006-10-21 2:12 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-10-18 23:53 [ANNOUNCE] GIT 1.4.3 Junio C Hamano
2006-10-20 12:31 ` Horst H. von Brand
2006-10-20 13:26 ` Peter Eriksen
2006-10-20 23:35 ` Junio C Hamano
2006-10-21 0:14 ` Linus Torvalds
2006-10-21 0:22 ` Petr Baudis
2006-10-21 0:31 ` Linus Torvalds
2006-10-21 9:53 ` Andreas Schwab
2006-10-22 21:09 ` Anders Larsen
2006-10-21 2:12 ` Al Viro [this message]
2006-10-21 5:29 ` Junio C Hamano
2006-10-21 5:40 ` Al Viro
2006-10-21 14:29 ` Rene Scharfe
2006-10-21 0:47 ` Nicolas Pitre
2006-10-23 0:53 ` prune/prune-packed J. Bruce Fields
2006-10-23 1:26 ` prune/prune-packed A Large Angry SCM
2006-10-23 2:36 ` [ANNOUNCE] GIT 1.4.3 J. Bruce Fields
2006-10-23 3:27 ` prune/prune-packed Junio C Hamano
2006-10-23 18:39 ` prune/prune-packed Petr Baudis
2006-10-27 21:19 ` prune/prune-packed Jon Loeliger
2006-10-27 21:55 ` prune/prune-packed Junio C Hamano
-- strict thread matches above, loose matches on Subject: below --
2006-10-22 3:59 prune/prune-packed J. Bruce Fields
2006-10-22 4:59 ` prune/prune-packed Junio C Hamano
2006-10-22 23:14 ` prune/prune-packed J. Bruce Fields
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20061021021235.GA29920@ftp.linux.org.uk \
--to=viro@ftp.linux.org.uk \
--cc=git@vger.kernel.org \
--cc=junkio@cox.net \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@osdl.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).