[brisbane-core MERGE] CHKInventory.iter_non_root_entries()

Ian Clatworthy ian.clatworthy at internode.on.net
Fri Mar 6 13:15:53 GMT 2009


So fast-import now kind of works for CHK repo formats, give or
take 'deleteall' directives (as used by e.g. darcs-fast-export).
Unfortunately though, it's rather slow at the moment - about
5-7 times slower (for gc-chk255) than importing into a pack repo.
And pack importing is *not* fast - it's about 10 times slower
than git-fast-import or hg-fast-import from what I'm told. :-(
Time for some profiling ...

It seems that operations that walk directories in CHKInventories
are slow, e.g. directories() and iter_changes(). As it turns out
though, I don't *need* the path returned by iter_changes() in
fast-import - just the inventories entries while loading texts.

The attached patch adds a new method to CHKInventory called
iter_non_root_entries(). Using it instead of iter_entries() cuts
the fast-import time for gc-chk255 by half. Hooray.

Ian C.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: iter-non-root-entries.diff
Type: text/x-diff
Size: 1343 bytes
Desc: not available
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20090306/c3a0940c/attachment.bin 


More information about the bazaar mailing list