This is an archive of the discontinued Mercurial Phabricator instance.

phases: sparsify phaseroots and phasesets
ClosedPublic

Authored by joerg.sonnenberger on Jul 7 2020, 6:38 PM.

Details

Summary

As final step of dealing with the holes in the phase numbers, make
phaseroots and phasesets both dictionaries indexed by the phase number.
Further adjust the interface of the C module by pushing the node to
revision mapping down as it is cheaper on the C side to deal with
revision numbers.

Overall, the patch series improves a no-change "hg up" for my NetBSD test
repository from 4.7s to 1.3s.

Diff Detail

Repository
rHG Mercurial
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

durin42 accepted this revision.Jul 15 2020, 11:28 AM
durin42 added a subscriber: durin42.
durin42 added inline comments.
mercurial/cext/revlog.c
880–889

Possible improvement: _dict_new_presized could probably be used here since it looks like you know the possible dict size.

This revision is now accepted and ready to land.Jul 15 2020, 11:28 AM
This revision was automatically updated to reflect the committed changes.