Commit b185beb9 authored by Pierre-Yves David's avatar Pierre-Yves David 🐙
Browse files

topic: reorder revset for faster evaluation

When running the revset on unfiltered repository, the mutable set can get huge.
So removing the obsolete changeset first provide a large speedup. This resolve
the performance regression we were seeing since the 6.7.0 release.
parent 033e00be9ce4
......@@ -34,5 +34,5 @@
if topic is not None and branch is not None:
raise error.ProgrammingError('both branch and topic specified (not defined yet)')
elif topic is not None:
trevs = repo.revs("topic(%s) - obsolete()", topic)
trevs = repo.revs("not obsolete() and topic(%s) - obsolete()", topic)
elif branch is not None:
......@@ -38,5 +38,5 @@
elif branch is not None:
trevs = repo.revs("branch(%s) - public() - obsolete() - topic()", branch)
trevs = repo.revs("not public() and branch(%s) - obsolete() - topic()", branch)
raise error.ProgrammingError('neither branch and topic specified (not defined yet)')
self._revs = trevs
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment