From 81941b92219a6251ab903de48a1ead181c89d1f3 Mon Sep 17 00:00:00 2001 From: ncteisen Date: Wed, 14 Jun 2017 11:55:56 -0700 Subject: Propagate counters flag change --- tools/profiling/microbenchmarks/bm_diff/bm_build.py | 9 +++------ tools/profiling/microbenchmarks/bm_diff/bm_diff.py | 9 +++------ tools/profiling/microbenchmarks/bm_diff/bm_run.py | 9 +++------ 3 files changed, 9 insertions(+), 18 deletions(-) (limited to 'tools/profiling') diff --git a/tools/profiling/microbenchmarks/bm_diff/bm_build.py b/tools/profiling/microbenchmarks/bm_diff/bm_build.py index c172de2af7..ce62c09d72 100755 --- a/tools/profiling/microbenchmarks/bm_diff/bm_build.py +++ b/tools/profiling/microbenchmarks/bm_diff/bm_build.py @@ -46,12 +46,9 @@ def _args(): type=str, help='Unique name of this build. To be used as a handle to pass to the other bm* scripts' ) - argp.add_argument( - '-c', - '--counters', - type=bool, - default=True, - help='Whether or not to run and diff a counters build') + argp.add_argument('--counters', dest='counters', action='store_true') + argp.add_argument('--no-counters', dest='counters', action='store_false') + argp.set_defaults(counters=True) args = argp.parse_args() assert args.name return args diff --git a/tools/profiling/microbenchmarks/bm_diff/bm_diff.py b/tools/profiling/microbenchmarks/bm_diff/bm_diff.py index 6bb53e9676..73abf90ff5 100755 --- a/tools/profiling/microbenchmarks/bm_diff/bm_diff.py +++ b/tools/profiling/microbenchmarks/bm_diff/bm_diff.py @@ -67,12 +67,9 @@ def _args(): default=20, help='Number of times to loops the benchmarks. Must match what was passed to bm_run.py' ) - argp.add_argument( - '-c', - '--counters', - type=bool, - default=True, - help='Whether or not to run and diff a counters build') + argp.add_argument('--counters', dest='counters', action='store_true') + argp.add_argument('--no-counters', dest='counters', action='store_false') + argp.set_defaults(counters=True) argp.add_argument('-n', '--new', type=str, help='New benchmark name') argp.add_argument('-o', '--old', type=str, help='Old benchmark name') argp.add_argument( diff --git a/tools/profiling/microbenchmarks/bm_diff/bm_run.py b/tools/profiling/microbenchmarks/bm_diff/bm_run.py index 1b5cae0211..72b3d3cf10 100755 --- a/tools/profiling/microbenchmarks/bm_diff/bm_run.py +++ b/tools/profiling/microbenchmarks/bm_diff/bm_run.py @@ -67,12 +67,9 @@ def _args(): default=20, help='Number of times to loops the benchmarks. More loops cuts down on noise' ) - argp.add_argument( - '-c', - '--counters', - type=bool, - default=True, - help='Whether or not to run and diff a counters build') + argp.add_argument('--counters', dest='counters', action='store_true') + argp.add_argument('--no-counters', dest='counters', action='store_false') + argp.set_defaults(counters=True) args = argp.parse_args() assert args.name if args.loops < 3: -- cgit v1.2.3