diff --git a/runners/bench_runner.c b/runners/bench_runner.c index 50bc8be9..4f2b23a9 100644 --- a/runners/bench_runner.c +++ b/runners/bench_runner.c @@ -428,7 +428,7 @@ size_t bench_id_count = 1; size_t bench_step_start = 0; size_t bench_step_stop = -1; size_t bench_step_step = 1; -bool bench_all = false; +bool bench_force = false; const char *bench_disk_path = NULL; const char *bench_trace_path = NULL; @@ -842,7 +842,7 @@ void perm_count( state->total += 1; - if (!case_->run || !(bench_all || !case_->if_ || case_->if_())) { + if (!case_->run || !(bench_force || !case_->if_ || case_->if_())) { return; } @@ -1335,7 +1335,7 @@ void perm_run( bench_step += 1; // filter? - if (!case_->run || !(bench_all || !case_->if_ || case_->if_())) { + if (!case_->run || !(bench_force || !case_->if_ || case_->if_())) { printf("skipped "); perm_printid(suite, case_); printf("\n"); @@ -1432,18 +1432,18 @@ enum opt_flags { OPT_DEFINE = 'D', OPT_DEFINE_DEPTH = 6, OPT_STEP = 's', - OPT_ALL = 'a', + OPT_FORCE = 7, OPT_DISK = 'd', OPT_TRACE = 't', - OPT_TRACE_BACKTRACE = 7, - OPT_TRACE_PERIOD = 8, - OPT_TRACE_FREQ = 9, - OPT_READ_SLEEP = 10, - OPT_PROG_SLEEP = 11, - OPT_ERASE_SLEEP = 12, + OPT_TRACE_BACKTRACE = 8, + OPT_TRACE_PERIOD = 9, + OPT_TRACE_FREQ = 10, + OPT_READ_SLEEP = 11, + OPT_PROG_SLEEP = 12, + OPT_ERASE_SLEEP = 13, }; -const char *short_opts = "hYlLD:s:ad:t:"; +const char *short_opts = "hYlLD:s:d:t:"; const struct option long_opts[] = { {"help", no_argument, NULL, OPT_HELP}, @@ -1460,7 +1460,7 @@ const struct option long_opts[] = { {"define", required_argument, NULL, OPT_DEFINE}, {"define-depth", required_argument, NULL, OPT_DEFINE_DEPTH}, {"step", required_argument, NULL, OPT_STEP}, - {"all", no_argument, NULL, OPT_ALL}, + {"force", no_argument, NULL, OPT_FORCE}, {"disk", required_argument, NULL, OPT_DISK}, {"trace", required_argument, NULL, OPT_TRACE}, {"trace-backtrace", no_argument, NULL, OPT_TRACE_BACKTRACE}, @@ -1808,8 +1808,8 @@ int main(int argc, char **argv) { fprintf(stderr, "error: invalid step: %s\n", optarg); exit(-1); - case OPT_ALL:; - bench_all = true; + case OPT_FORCE:; + bench_force = true; break; case OPT_DISK:; diff --git a/runners/test_runner.c b/runners/test_runner.c index ae2d4d52..ae7b3a7f 100644 --- a/runners/test_runner.c +++ b/runners/test_runner.c @@ -439,7 +439,7 @@ size_t test_id_count = 1; size_t test_step_start = 0; size_t test_step_stop = -1; size_t test_step_step = 1; -bool test_all = false; +bool test_force = false; const char *test_disk_path = NULL; const char *test_trace_path = NULL; @@ -812,7 +812,7 @@ void perm_count( // set pls to 1 if running under powerloss so it useful for if predicates TEST_PLS = (powerloss->run != run_powerloss_none); - if (!case_->run || !(test_all || !case_->if_ || case_->if_())) { + if (!case_->run || !(test_force || !case_->if_ || case_->if_())) { return; } @@ -1811,7 +1811,7 @@ void perm_run( // set pls to 1 if running under powerloss so it useful for if predicates TEST_PLS = (powerloss->run != run_powerloss_none); // filter? - if (!case_->run || !(test_all || !case_->if_ || case_->if_())) { + if (!case_->run || !(test_force || !case_->if_ || case_->if_())) { printf("skipped "); perm_printid(suite, case_, NULL, 0); printf("\n"); @@ -1869,18 +1869,18 @@ enum opt_flags { OPT_DEFINE_DEPTH = 7, OPT_POWERLOSS = 'P', OPT_STEP = 's', - OPT_ALL = 'a', + OPT_FORCE = 8, OPT_DISK = 'd', OPT_TRACE = 't', - OPT_TRACE_BACKTRACE = 8, - OPT_TRACE_PERIOD = 9, - OPT_TRACE_FREQ = 10, - OPT_READ_SLEEP = 11, - OPT_PROG_SLEEP = 12, - OPT_ERASE_SLEEP = 13, + OPT_TRACE_BACKTRACE = 9, + OPT_TRACE_PERIOD = 10, + OPT_TRACE_FREQ = 11, + OPT_READ_SLEEP = 12, + OPT_PROG_SLEEP = 13, + OPT_ERASE_SLEEP = 14, }; -const char *short_opts = "hYlLD:P:s:ad:t:"; +const char *short_opts = "hYlLD:P:s:d:t:"; const struct option long_opts[] = { {"help", no_argument, NULL, OPT_HELP}, @@ -1899,7 +1899,7 @@ const struct option long_opts[] = { {"define-depth", required_argument, NULL, OPT_DEFINE_DEPTH}, {"powerloss", required_argument, NULL, OPT_POWERLOSS}, {"step", required_argument, NULL, OPT_STEP}, - {"all", no_argument, NULL, OPT_ALL}, + {"force", no_argument, NULL, OPT_FORCE}, {"disk", required_argument, NULL, OPT_DISK}, {"trace", required_argument, NULL, OPT_TRACE}, {"trace-backtrace", no_argument, NULL, OPT_TRACE_BACKTRACE}, @@ -2414,8 +2414,8 @@ int main(int argc, char **argv) { fprintf(stderr, "error: invalid step: %s\n", optarg); exit(-1); - case OPT_ALL:; - test_all = true; + case OPT_FORCE:; + test_force = true; break; case OPT_DISK:; diff --git a/scripts/bench.py b/scripts/bench.py index 19fbe47e..7fc3aac2 100755 --- a/scripts/bench.py +++ b/scripts/bench.py @@ -717,8 +717,8 @@ def find_runner(runner, id=None, main=True, **args): # other context if args.get('define_depth'): cmd.append('--define-depth=%s' % args['define_depth']) - if args.get('all'): - cmd.append('-a') + if args.get('force'): + cmd.append('--force') # only one thread should write to disk/trace, otherwise the output # ends up clobbered and useless @@ -1616,7 +1616,7 @@ if __name__ == "__main__": '--define-depth', help="How deep to evaluate recursive defines before erroring.") bench_parser.add_argument( - '-a', '--all', + '--force', action='store_true', help="Ignore bench filters.") bench_parser.add_argument( diff --git a/scripts/test.py b/scripts/test.py index 3848e3e6..51a9801b 100755 --- a/scripts/test.py +++ b/scripts/test.py @@ -737,8 +737,8 @@ def find_runner(runner, id=None, main=True, **args): cmd.append('--define-depth=%s' % args['define_depth']) if args.get('powerloss'): cmd.append('-P%s' % args['powerloss']) - if args.get('all'): - cmd.append('-a') + if args.get('force'): + cmd.append('--force') # only one thread should write to disk/trace, otherwise the output # ends up clobbered and useless @@ -1639,7 +1639,7 @@ if __name__ == "__main__": '-P', '--powerloss', help="Comma-separated list of power-loss scenarios to test.") test_parser.add_argument( - '-a', '--all', + '--force', action='store_true', help="Ignore test filters.") test_parser.add_argument(