Re: speeding up cg-log -u
- From
Petr Baudis <pasky@ucw.cz>
- Date
- May 14, 2005, 10:39 UTC
- Message-ID
- <20050514103937.GA3905@pasky.ji.cz>
- In-Reply-To
- <7vu0l62l27.fsf@assigned-by-dhcp.cox.net>
Dear diary, on Sat, May 14, 2005 at 08:19:14AM CEST, I got a letter where Zack Brown <zbrown@tumblerings.org> told me that...
> Currently cg-log handles this by grabbing all the log data from git, and > then grepping through it.
Which is clearly suboptimal since cg-log now does git-cat-file up to _three_ times per commit. It should instead process the commit only once.
Dear diary, on Sat, May 14, 2005 at 11:50:24AM CEST, I got a letter where Junio C Hamano <junkio@cox.net> told me that...
> + buffer = read_sha1_file(item->object.sha1, type, &size);
If it do that, I wonder how much speedup would be using this instead. But probably still significant one.
What I don't like is that it searches only the author field. I find the behaviour that it searches in the committer field as well very useful, since I can easily check whose patches on a file I checked it - that's useful when porting own stuff to another branch, or frequently it's the only thing I actually remember. :-)
-- Petr "Pasky" Baudis Stuff: http://pasky.or.cz/ C++: an octopus made by nailing extra legs onto a dog. -- Steve Taylor