git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Alexander Gavrilov <angavrilov@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: [RFC/PATCH 0/2] Enhance performance of blame -C -C
Date: Tue, 15 Jul 2008 15:25:29 -0700	[thread overview]
Message-ID: <7vhcaqzsx2.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <200807160158.34994.angavrilov@gmail.com> (Alexander Gavrilov's message of "Wed, 16 Jul 2008 01:58:34 +0400")

Alexander Gavrilov <angavrilov@gmail.com> writes:

> 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.

      parent reply	other threads:[~2008-07-15 22:26 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-07-15 21:58 [RFC/PATCH 0/2] Enhance performance of blame -C -C Alexander Gavrilov
2008-07-15 21:59 ` [RFC/PATCH 1/2] Avoid rescanning unchanged entries in search for copies Alexander Gavrilov
2008-07-15 22:00   ` [RFC/PATCH 2/2] Do not try to detect move/copy for entries below threshold Alexander Gavrilov
2008-07-15 22:05   ` [RFC/PATCH 1/2 (No Wrap)] Avoid rescanning unchanged entries in search for copies Alexander Gavrilov
2008-07-15 22:25 ` Junio C Hamano [this message]

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=7vhcaqzsx2.fsf@gitster.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=angavrilov@gmail.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).