##// END OF EJS Templates
perf: add a new `perfmergecopies` command...
marmoute -
r42576:f5f0a949 default
parent child Browse files
Show More
@@ -1004,6 +1004,24 b' def perfmergecalculate(ui, repo, **opts)'
1004 timer(d)
1004 timer(d)
1005 fm.end()
1005 fm.end()
1006
1006
1007 @command(b'perfmergecopies',
1008 [
1009 (b'r', b'rev', b'.', b'rev to merge against'),
1010 (b'', b'from', b'', b'rev to merge from'),
1011 (b'', b'base', b'', b'the revision to use as base'),
1012 ] + formatteropts)
1013 def perfmergecopies(ui, repo, **opts):
1014 """measure runtime of `copies.mergecopies`"""
1015 opts = _byteskwargs(opts)
1016 timer, fm = gettimer(ui, opts)
1017 wctx, rctx, ancestor = _getmergerevs(repo, opts)
1018 def d():
1019 # acceptremote is True because we don't want prompts in the middle of
1020 # our benchmark
1021 copies.mergecopies(repo, wctx, rctx, ancestor)
1022 timer(d)
1023 fm.end()
1024
1007 @command(b'perfpathcopies', [], b"REV REV")
1025 @command(b'perfpathcopies', [], b"REV REV")
1008 def perfpathcopies(ui, repo, rev1, rev2, **opts):
1026 def perfpathcopies(ui, repo, rev1, rev2, **opts):
1009 """benchmark the copy tracing logic"""
1027 """benchmark the copy tracing logic"""
@@ -141,6 +141,8 b' perfstatus'
141 usable
141 usable
142 perfmergecalculate
142 perfmergecalculate
143 (no help text available)
143 (no help text available)
144 perfmergecopies
145 measure runtime of 'copies.mergecopies'
144 perfmoonwalk benchmark walking the changelog backwards
146 perfmoonwalk benchmark walking the changelog backwards
145 perfnodelookup
147 perfnodelookup
146 (no help text available)
148 (no help text available)
General Comments 0
You need to be logged in to leave comments. Login now