Merge lp:~jameinel/bzr/2.1.0b4-convert-kg-heads into lp:bzr
Proposed by
John A Meinel
Status: | Merged | ||||
---|---|---|---|---|---|
Approved by: | Robert Collins | ||||
Approved revision: | no longer in the source branch. | ||||
Merged at revision: | not available | ||||
Proposed branch: | lp:~jameinel/bzr/2.1.0b4-convert-kg-heads | ||||
Merge into: | lp:bzr | ||||
Diff against target: |
229 lines (+69/-16) 5 files modified
NEWS (+4/-0) bzrlib/fetch.py (+16/-5) bzrlib/graph.py (+13/-0) bzrlib/repository.py (+18/-11) bzrlib/tests/test_graph.py (+18/-0) |
||||
To merge this branch: | bzr merge lp:~jameinel/bzr/2.1.0b4-convert-kg-heads | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Robert Collins (community) | Approve | ||
Review via email: mp+15394@code.launchpad.net |
To post a comment you must log in.
See this graph: launchpadlibrar ian.net/ 36247556/ conversion_ times.png
http://
For the net effect of this patch. In converting mysql from 1.9 => 2a it cuts the time for the conversion approx 2:1.
The basic observation was that we spend *way* too much time graph walking during the conversion. Part of that was because we didn't pass *any* graph object down, so we didn't have any benefit of caching, etc. So for all heads() requests we paid the full api layering (translating back and forth from strings <=> tuples for all entries in the history, etc.)
Anyway, we have a very fast heads implementation, so lets use it. I put in the check:
if ... len(revision_ids) > 100:
in there, so that we don't *always* load the full history for small conversion updates. However, for anything more than that, we probably get a net win out of loading the whole ancestry and using the faster heads implementation.
I wish there was a way I could put the image inline, like I used to be able to do with Thunderbird sending requests via Bundle Buggy. (At least, people using email clients would see the image right away...)