git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: bdowning@lavos.net (Brian Downing)
Cc: git@vger.kernel.org
Subject: Re: [PATCHv3 1/2] Make xdi_diff_outf interface for running xdiff_outf diffs
Date: Wed, 20 Aug 2008 22:24:22 -0700	[thread overview]
Message-ID: <7vzln7j5yx.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <20080821033756.GC31114@lavos.net> (Brian Downing's message of "Wed, 20 Aug 2008 22:37:57 -0500")

bdowning@lavos.net (Brian Downing) writes:

> On Wed, Aug 13, 2008 at 11:18:22PM -0700, Junio C Hamano wrote:
>> Much nicer.  xdi_diff() is just a performance thing that only kicks in
>> when you are running -U0 diff, so it is unsurprising that you did not see
>> any test failures.
>
> Interesting point here.  In playing with trying to cache the diff hashes
> to speed up blame, I had to basically disable the xdi_diff tail trimming
> when building the hash the first time, because it needed to see the
> whole file.  In doing this, I discovered that just changing from
> xdi_diff to xdl_diff /does/ change the blame -M -C -C --incremental
> result for my test case.  (Unfortunately, my test case is proprietary
> code...)

Is the reason why you mention "incremental" specifically because you only
tested incremental, or you get identical result in non-incremental mode?

If your material is repetitive, say you have lines "A A A B C A A A" in
the parent blob and "A A A B A A A" in the child blob, and you are trying
to pass blame on three line block "A A A" at the beginning of the child,
we can pass blame to the three lines at the beginning part, or to the end
part, without Linus's common tail trimming optimization.  But there is no
way it can match the end part with the optimization.

You cannot say one result is more correct than the other --- both are
equally correct.  Of course, you could argue that with such a highly
repetitive material, it may be better to match closer ones, but it's a
judgement call.

  reply	other threads:[~2008-08-21  5:25 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-13  7:05 [PATCH 1/2] Make xdiff_outf_{init,release} interface Brian Downing
2008-08-14  0:46 ` Junio C Hamano
2008-08-14  2:06   ` Brian Downing
2008-08-14  2:13     ` Junio C Hamano
2008-08-14  5:13       ` [PATCHv2 1/2] Make xdi_diff_outf interface for running xdiff_outf diffs Brian Downing
2008-08-14  5:13         ` [PATCHv2 2/2] Use strbuf for struct xdiff_emit_state's remainder Brian Downing
2008-08-14  5:31         ` [PATCHv2 1/2] Make xdi_diff_outf interface for running xdiff_outf diffs Brian Downing
2008-08-14  5:36           ` [PATCHv3 " Brian Downing
2008-08-14  5:36             ` [PATCHv3 2/2] Use strbuf for struct xdiff_emit_state's remainder Brian Downing
2008-08-14  6:18             ` [PATCHv3 1/2] Make xdi_diff_outf interface for running xdiff_outf diffs Junio C Hamano
2008-08-14  6:34               ` Brian Downing
2008-08-21  3:37               ` Brian Downing
2008-08-21  5:24                 ` Junio C Hamano [this message]
2008-08-21  6:29                   ` Brian Downing

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=7vzln7j5yx.fsf@gitster.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=bdowning@lavos.net \
    --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).