changegroup: restore default node ordering (issue6001)

Authored by lothiraldan on Oct 30 2018, 12:28 PM.



Changeset db5501d9 changed the default node ordering from "storage" to

While the new API is more explicit and cleaner, the "linearize" order is
problematic on certain repositories like netbeans where it makes bundling
slower the more nodes we bundle.

Pushing and pulling 100 changesets was ~20% slower and pushing and pulling
1000 changesets was ~600% slower.

A very quick analysis of profile traces showed that the pull operation was
taking more time creating the delta.

Putting back the old default order seems to be the safe option. With more time
during the next cycle, we can understand better the impact of sorting with the
DAG order by default, the source of the regression and how to mitigate it.

/!\ We are still waiting for the full performance impact but with this patch,
bundling and pulling locally (not on the performance workstation) 1000
changesets on the netbeans repository is as fast as before the regression.

Diff Detail

rHG Mercurial
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.
lothiraldan created this revision.Oct 30 2018, 12:28 PM
indygreg accepted this revision.Oct 31 2018, 3:06 PM
indygreg added a subscriber: indygreg.

db5501d93bcf6ada3426a45e901094fd877e370f changed a test. I'm surprised this patch doesn't include that revert as well. I'll verify the test as part of landing and amend as necessary.

This revision is now accepted and ready to land.Oct 31 2018, 3:06 PM
This revision was automatically updated to reflect the committed changes.

With the fix, we are back to pre-regression performance on the test suite.

Can we update the last paragraph of the changeset description to replace it with the previous phrase?

There is two tests that are actually slower between d9b3cc3d (the parent of the regression) and the fix, which are:

+         206±2ms         310±40ms     1.51  basic_commands.PushPullTimeSuite.time_push('mozilla-central-2018-08-01', 'local', 'same', 'default')
+         175±1ms         226±30ms     1.30  basic_commands.PushPullTimeSuite.time_push('mozilla-central-2018-08-01', 'local', 'same', None)

There are push operations between the same repository, no-op push. As they are no-op push, I think there is no bundle generation so the fix shouldn't impact the performance. We may have another slowdown.