backward diffs in knits?

Aaron Bentley aaron.bentley at utoronto.ca
Tue Apr 10 13:00:58 BST 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Robert Collins wrote:

> That is, rather than patching forward, have a knit be able to patch
> backwards to get content. This works by having the largest text the
> first, and subsequent ones generally remove content rather than adding -
> making the deltas smaller and also happily reducing the read time for
> the most recent text. git packfiles do this with great effect AIUI.

Why would this make deltas smaller?

If you have

Text A
123

and Text B
123456

Then storing A and B requires storing "123" and "456" exactly once, in
either case.  If using forward deltas, "456" is an insert associated
with B, and "123" is part of the A snapshot.  If using backward deltas,
"123" and "456" are both part of the B snapshot.

Aaron
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.3 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGG3x60F+nu1YWqI0RAjQsAJ9ALnezR04U5ujzdaPL7OXt+LRH0gCfbzId
xpnNJJLpTHn0QRm2D06dYxQ=
=SYdQ
-----END PGP SIGNATURE-----



More information about the bazaar mailing list