very slow "git gc --aggressive" in GIT-1.6.4.4
- From
- Leo Razoumov <slonik.az@gmail.com>
- Date
- Sep 18, 2009, 19:23 UTC
- Message-ID
- <ee2a733e0909181223j1ffc99edkdb3700adb37fa147@mail.gmail.com>
I noticed that "git gc --agressive" takes 5 times longer with git-1.6.4.4 than with git-1.6.2.5.
Below are benchmarks on my Linux Ubuntu-9.04 laptop (Core2 Duo 2.54GHz). As a test repo I use a mirror of the official GIT upstream.
GIT-v1.6.4.4 ----------------- git.upstream> time git gc --agressive Counting objects: 105217, done. Delta compression using up to 2 threads. Compressing objects: 100% (103507/103507), done. Writing objects: 100% (105217/105217), done. Total 105217 (delta 77228), reused 0 (delta 0) git gc --aggressive 168.31s user 0.58s system 180% cpu 1:33.52 total
GIT-1.6.2.5.LR1 --------------------- git.upstream> time git gc --aggressive Counting objects: 105217, done. Delta compression using 2 threads. Compressing objects: 100% (103507/103507), done. Writing objects: 100% (105217/105217), done. Total 105217 (delta 76235), reused 0 (delta 0) git gc --aggressive 30.97s user 0.48s system 141% cpu 22.177 total ==========================================
168 seconds for git-1.6.4.4 versus 22 seconds for git-1.6.2.5.
What gives?
--Leo--