# HG changeset patch # User Pierre-Yves David <pierre-yves.david@octobus.net> # Date 1680476294 -7200 # Mon Apr 03 00:58:14 2023 +0200 # Node ID 9e8ba7bbcbb4bce219ae9423d86e9c8e9e4fd870 # Parent 3674705944b61138ffe657ed11eb02b078486078 benchmark: add a benchmark for `hg files` This one is mostly composed of the underlying issue that crippled cat. So lets measure it too. diff --git a/suites/hg/benchmarks/cat.pbd b/suites/hg/benchmarks/files.pbd copy from suites/hg/benchmarks/cat.pbd copy to suites/hg/benchmarks/files.pbd --- a/suites/hg/benchmarks/cat.pbd +++ b/suites/hg/benchmarks/files.pbd @@ -1,13 +1,15 @@ [meta] format="0" -name="cat" +name="files" method="simple-command" [run] copy-data-env = true [simple-command] -command='hg cat $REV "$FILES" $TEMPLATE > /dev/null' +command=""" +hg files $REV $FILES $TEMPLATE --config ui.interactive=no --config ui.paginate=no +""" cwd="DATA-VARS:mercurial.main-repo-path" prepare-run = """ # XXX We could only do this once before the benchmark instead of doing this for @@ -22,8 +24,11 @@ shuf ../all_sorted.pattern --random-source=../all_sorted.pattern > ../all_suffled.pattern; """ +[simple-command.variants.dimensions.rev.working-copy] +default=true +environment.REV="" + [simple-command.variants.dimensions.rev.tip] -default=true environment.REV="--rev tip" [simple-command.variants.dimensions.output.plain] @@ -33,9 +38,10 @@ [simple-command.variants.dimensions.output.json] environment.TEMPLATE="--template json" +[simple-command.variants.dimensions.files.plain] +default=true [simple-command.variants.dimensions.files.all-root] -default=true environment.FILES="." [simple-command.variants.dimensions.files.all-glob]