[rfc] [patch] speeding up bzr log with a tree delta iterator

John Arbash Meinel john at arbash-meinel.com
Wed Jan 18 00:28:31 GMT 2006


Denys Duchier wrote:
> After an IRC conversation with lifeless, I implemented a tree delta iterator
> with which similar speed improvements for bzr log can be obtained as with my
> inventory caching patch.
> 
> This patch is available as revno=1521 of my bzr.fix.log branch at:
> 
>              http://delta.univ-orleans.fr/~duchier/bzr/bzr.fix.log
> 

This seems useful.

I'm curious why we stopped using 'deltas_for_log_forward' and
'deltas_for_log_reverse.' Those did exactly what you are doing with your
iterator (kept track of the previous entry, and computed the appropriate
delta).

If we do want this functionality, should it be part of the full Branch
spec, rather than just BzrBranch? This doesn't have to be inside the
Branch class. So it might make more sense to put the functionality into
delta.py

Also, I would like to see some minor test cases before it was merged.

I would probably also prefer it if we weren't iterating by revno. But
rather by revision_id.
Though I guess you can't really iterate forward without a
revision-history. (Though you could iterate backwards to create the
history, and then iterate forwards across it).

There is also something possible with Aaron's idea of LazyRevision, but
I'm probably talking something else by now...

Maybe we should yield 'lo_tree_rev_id, hi_tree_rev_id' or something like
that as well. That way you don't have to iterate over the revision
history separately and make sure you stay in sync.

I like the concept of the delta iterator. I'm not sure about the specifics.

John
=:->
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 256 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060117/64d37081/attachment.pgp 


More information about the bazaar mailing list