From patchwork Fri Feb 8 21:13:27 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [5,of,5] merge: don't pre-check for locally unknown files From: Siddharth Agarwal X-Patchwork-Id: 838 Message-Id: <787156b90b65abd9bb3a.1360358007@sid0x220> To: mercurial-devel@selenic.com Date: Fri, 08 Feb 2013 21:13:27 +0000 # HG changeset patch # User Siddharth Agarwal # Date 1360339767 0 # Node ID 787156b90b65abd9bb3adab5077b159021da83e8 # Parent 34715ca02ce42fa3452b7b0d87cb0acfedb18a16 merge: don't pre-check for locally unknown files Now that unknown files are checked in manifestmerge, this is no longer necessary. On a repository with over 150,000 files, this speeds up an update by 0.6-0.8 seconds, which is up to 25%. diff --git a/mercurial/merge.py b/mercurial/merge.py --- a/mercurial/merge.py +++ b/mercurial/merge.py @@ -472,8 +472,6 @@ def calculateupdates(repo, tctx, mctx, a _checkcollision(mctx, None) else: _checkcollision(mctx, (tctx, ancestor)) - if not force: - _checkunknown(repo, tctx, mctx) if tctx.rev() is None: actions += _forgetremoved(tctx, mctx, branchmerge) actions += manifestmerge(repo, tctx, mctx,