##// END OF EJS Templates
phase: improve retractboundary perf...
Durham Goode -
r26909:e3611881 default
parent child Browse files
Show More
@@ -308,9 +308,19 b' class phasecache(object):'
308 raise error.Abort(_('cannot change null revision phase'))
308 raise error.Abort(_('cannot change null revision phase'))
309 currentroots = currentroots.copy()
309 currentroots = currentroots.copy()
310 currentroots.update(newroots)
310 currentroots.update(newroots)
311 ctxs = repo.set('roots(%ln::)', currentroots)
311
312 currentroots.intersection_update(ctx.node() for ctx in ctxs)
312 # Only compute new roots for revs above the roots that are being
313 self._updateroots(targetphase, currentroots, tr)
313 # retracted.
314 minnewroot = min(repo[n].rev() for n in newroots)
315 aboveroots = [n for n in currentroots
316 if repo[n].rev() >= minnewroot]
317 updatedroots = repo.set('roots(%ln::)', aboveroots)
318
319 finalroots = set(n for n in currentroots if repo[n].rev() <
320 minnewroot)
321 finalroots.update(ctx.node() for ctx in updatedroots)
322
323 self._updateroots(targetphase, finalroots, tr)
314 repo.invalidatevolatilesets()
324 repo.invalidatevolatilesets()
315
325
316 def filterunknown(self, repo):
326 def filterunknown(self, repo):
General Comments 0
You need to be logged in to leave comments. Login now