This is an archive of the discontinued Mercurial Phabricator instance.

perftweaks: unbreak the branchcache code
ClosedPublic

Authored by simpkins on Nov 23 2017, 12:56 AM.
Tags
None
Subscribers
None

Details

Reviewers
quark
durham
Group Reviewers
Restricted Project
Commits
rFBHGX0bfd5874c806: perftweaks: unbreak the branchcache code
Summary

D1451 changed _branchmapupdate() so that it no longer updates self.filteredhash
when changing self.tiprev. This causes branchcache.validfor() to report that
the cache is no longer valid, causing an assertion failure at the end of
updatecache().

Test Plan

Running hg commands no longer crash.

Diff Detail

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

Event Timeline

simpkins created this revision.Nov 23 2017, 12:56 AM
Herald added a reviewer: Restricted Project. · View Herald TranscriptNov 23 2017, 12:56 AM
quark accepted this revision.Nov 23 2017, 1:18 AM

Sorry for this. Is this the cause of pushrebase failure?

I didn't notice this since the validfor code path was probably skipped by D1450.

This revision is now accepted and ready to land.Nov 23 2017, 1:18 AM

No, I don't think this is related to the pushrebase failure. However, it causes pretty much any hg command in my repository to fail after running "hg pull" or "hg rebase" (maybe any command that creates a new tip?)

This revision was automatically updated to reflect the committed changes.