Re: how to speed up "git log"?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On Sun, 11 Feb 2007, Bruno Haible wrote:

> Are there some known tricks to speed up the operation of "git log"?
> 
> On a file in a local copy of the coreutils git repository,
> "git log tr.c > output" takes
>   - 33 seconds of CPU time (33 user, 0 system) on a Linux/x86 500MHz system,
>   - 24 seconds of CPU time (12 user, 12 system) on a MacOS X PowerPC 1.1 GHz
>     system.
> The result shows only 147 commits and a total of 40 KB textual output.

Yes, because there were only 147 commits which changed the file. But git 
looked at all commits to find that.

Basically, we don't do file versions. File versions do not make sense, 
since they strip away the context. See also

http://news.gmane.org/group/gmane.comp.version-control.git/thread=37838

for a real flamewar revolving around that very subject.

> 1) Why so much user CPU time?

See above.

Plus, you are probably not really interested in _all_ revisions changing 
that file, are you? Usually the output of git-log -- even with pathname 
filtering -- starts almost instantaneous, and is piped to your pager. So, 
your numbers are misleading.

> 2) Why so much system CPU time, but only on MacOS X?

Probably the mmap() problem. Does it go away when you use git 1.5.0-rc4?

Hth,
Dscho

-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]