[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: File modification detection?

From: Ben Collins-Sussman <sussman_at_collab.net>
Date: 2004-04-22 21:32:23 CEST

On Thu, 2004-04-22 at 14:28, Mike Mason wrote:

> If Subversion is storing MD5s for the text bases anyhow, shouldn't the
> comparison use the MD5 instead of being byte-for-byte?

Hm, but that would force us to always read the *entire* text-base file.
At the moment, we bail out as soon as we see a difference between the
working and text-base files.

My first thought was: the current algorithm is faster than
checksumming, because we can bail early. Most changes aren't at the
very end of a file.

But then Karl pointed out that while "on average" our current algorithm
bails after reading half the text-base, this is cancelled out by the
fact that it's reading two files instead of one. So maybe the
byte-for-byte and checksum strategies come out even? :-)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu Apr 22 21:34:47 2004

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.