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

Re: [RFC/PATCH 0/2] Enhance performance of blame -C -C

From
Junio C Hamano <gitster@pobox.com>
Date
Jul 15, 2008, 22:25 UTC
Message-ID
<7vhcaqzsx2.fsf@gitster.siamese.dyndns.org>
In-Reply-To
<200807160158.34994.angavrilov@gmail.com>
Alexander Gavrilov <angavrilov@gmail.com> writes:
Show 22 quoted lines
> This pair of patches aims at increasing performance of copy detection in
> blame by avoiding unnecessary comparisons. Note that since I'm new to
> this code, I might have misunderstood something.
>
> There are two cases than I aim to fix:
>
> 1) Copy detection is done by comparing all outstanding chunks of the
> target file to all blobs in the parent. After that, chunks with suitable
> matches are split, and comparison is repeated again, until there are no
> new matches. The trouble is, chunks that didn't match the first time,
> and weren't split, are compared against the same set of blobs again and
> again. I add a flag to track that.
>
>   On my test case it decreased blame -C -C time from over 10min to
>   ~6min; 4min with -C80.
>
> 2) Chunks are split only if the match scores above a certain
> threshold. I understand that a split of an entry cannot score more than
> the entry itself. Thus, it is pointless to even try doing costly
> comparisons for small entries.
>
>   (Time goes down to 4min; 2min with -C80)
Ideas for both patches sound very sane.  Will take a deeper look later.
Thanks.
Previous: Alexander Gavrilov
Message 5 of 5 in “Enhance performance of blame -C -C”
  1. 0/2 Enhance performance of blame -C -CAlexander Gavrilov, Jul 15, 2008
  2. 1/2 Avoid rescanning unchanged entries in search for copies.Alexander Gavrilov, Jul 15, 2008
  3. 2/2 Do not try to detect move/copy for entries below threshold.Alexander Gavrilov, Jul 15, 2008
  4. 1/2 Avoid rescanning unchanged entries in search for copies.Alexander Gavrilov, Jul 15, 2008
  5. Junio C HamanoJul 15, 2008

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.