All of lore.kernel.org
 help / color / mirror / Atom feed
From: Marat Radchenko <marat@slonopotamus.org>
To: git@vger.kernel.org
Subject: VERY slow git format-patch (tens on minutes) during rebase and rev-list during rebase -i
Date: Tue, 13 Jul 2010 06:56:45 +0000 (UTC)	[thread overview]
Message-ID: <loom.20100713T082913-327@post.gmane.org> (raw)

Hi.

My setup:
0. Quad-code machine with 8GB of ram, 10K RPM hdd.
1. SVN repo that i periodically fetch into origin/trunk branch. Has ~200 
commits/day.
2. My local branch with 1-5 commits which i often rebase against trunk.
3. I haven't rebased for 2 days, so i'm rebasing 3 (three) commits in my branch 
over 453 commits in trunk using "git rebase trunk".
4. trunk does contain "bad" from diff POV files (big & binary).
5. Sadly, data in repo is confidential.

Expected: rebase takes some reasonable amount of time (< 1 min?).

Actual: rebase takes 20 mins.

Almost all of that time was spent doing `git format-patch -k --stdout --full-
index --ignore-if-in-upstream 
80bb0dfe3d86f3cc9095ea616d9d1b1530fbe7b8..d3fde4ae7497981a6fe61b0366b105477896cf
52` (that's three commits from my branch) at 100% of one CPU core.

Additional info:

Another similar rebase but over 4.5k of commits took 2 hours.

Running without --ignore-if-in-upstream:
$ time git format-patch -k --stdout --full-index 
80bb0dfe3d86f3cc9095ea616d9d1b1530fbe7b8..d3fde4ae7497981a6fe61b0366b105477896cf
5 | wc -l
25823
Is it 
real	0m0.163s
user	0m0.140s
sys	0m0.020s

Proof there are only three commits:

$ git rev-list 
80bb0dfe3d86f3cc9095ea616d9d1b1530fbe7b8..d3fde4ae7497981a6fe61b0366b105477896cf
52d3fde4ae7497981a6fe61b0366b105477896cf52
e18069258806bda6a6165822003f5e9fd958f906
c8c2f2e157e615b73d0baab1d793a22991c9ba71

Questions:
1. Is it expected behavior (branch you rebase onto has binary files -> no 
performance for you)?
2. If [1] is yes, is it possible to prevent rebase from running --ignore-if-in-
upstream?
3. If [1] is no, should i run some kind of profiler (how?) to determine what 
exactly causes such performance drop?

             reply	other threads:[~2010-07-13  6:57 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-13  6:56 Marat Radchenko [this message]
2010-07-13  8:12 ` VERY slow git format-patch (tens on minutes) during rebase and rev-list during rebase -i Michael J Gruber
2010-07-13  8:13   ` [RFC/PATCH] rebase: Allow to turn of ignore-if-in-upstream Michael J Gruber
2010-07-13 19:33     ` Erik Faye-Lund
2010-09-04 15:03       ` Michael J Gruber
2010-09-09  8:05         ` Marat Radchenko
2010-10-13  7:56 ` [FEATURE REQUEST] allow enabling patience diff algorithm by default Marat Radchenko

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=loom.20100713T082913-327@post.gmane.org \
    --to=marat@slonopotamus.org \
    --cc=git@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.