strip: incrementally update the branchheads cache after a strip stable
authorJoshua Redstone <joshua.redstone@fb.com>
Fri, 18 May 2012 12:45:47 -0700
branchstable
changeset 1112 3007e5d9eb4e
parent 1110 d5b3404b82ce
child 1113 1e477be3b6c8
child 1115 eef22f846b0e
strip: incrementally update the branchheads cache after a strip This function augments strip to incrementally update the branchheads cache rather than recompute it from scratch. This speeds up the performance of strip and rebase on repos with long history. The performance optimization only happens if the revisions stripped are all on the same branch and the parents of the stripped revisions are also on that same branch. This adds a few test cases, particularly one that reproduces the extra heads that mpm observed. [ original upstream message ]
tests/test-keyword.t
--- a/tests/test-keyword.t	Mon Nov 07 13:46:41 2011 -0600
+++ b/tests/test-keyword.t	Fri May 18 12:45:47 2012 -0700
@@ -505,7 +505,6 @@
   $ hg -q commit -d '1 14' -m 'prepare amend'
 
   $ hg --debug commit --amend -d '1 15' -m 'amend without changes' | grep keywords
-  invalidating branch cache (tip differs)
   overwriting a expanding keywords
   $ hg -q id
   a71343332ea9