git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] rebase -i: avoid --cherry-pick when rebasing to a direct ancestor

From
Thomas Rast <trast@student.ethz.ch>
Date
Feb 20, 2010, 13:38 UTC
Message-ID
<201002201438.29635.trast@student.ethz.ch>
In-Reply-To
<20100220072728.GA12168@coredump.intra.peff.net>
On Saturday 20 February 2010 08:27:28 Jeff King wrote:
> But it is probably the source of the slowness to xdiff that
> gigantic files.
BTW, here's a weird data point:

$ ls -l a b -rw-r--r-- 1 thomas users 3300765 2010-02-20 12:48 a -rw-r--r-- 1 thomas users 3253762 2010-02-20 12:48 b $ time diff -u a b | wc -l 54530

real 0m0.644s user 0m0.562s sys 0m0.044s $ time git diff --no-index a b >/dev/null

real 0m22.848s user 0m21.956s sys 0m0.137s $ time git diff --no-index --patience a b >/dev/null

real 0m19.508s user 0m18.673s sys 0m0.273s

'a' and 'b' are two pnm's as per the OPs specification, I made 'a' a gradient and 'b' the same with two crosses drawn over it. You can find them at

  http://thomasrast.ch/download/slow-diff-pnms.zip
if you want to reproduce.
So what on earth does 'diff' do that makes it 35 times as fast?
-- 
Thomas Rast
trast@{inf,student}.ethz.ch
Previous: Jeff KingNext: Jeff King
Message 7 of 8 in “Git has bad performance when traversing change-sets with large PPM files”
  1. Laine Walker-AvinaFeb 19, 2010
  2. rebase -i: avoid --cherry-pick when rebasing to a direct ancestorThomas Rast, Feb 19, 2010
  3. Thomas RastFeb 20, 2010
  4. Jeff KingFeb 20, 2010
  5. cherry_pick_list: quit early if one side is emptyThomas Rast, Feb 20, 2010
  6. Jeff KingFeb 21, 2010
  7. Thomas RastFeb 20, 2010
  8. Jeff KingFeb 21, 2010

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.