X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~mdw/git/mLib/blobdiff_plain/c7da785d89746cbcdc25bdea0fd66156d4c61cb9..e63124bc579bfd97cfe2f620ddd84df9f20477d8:/test/tvec-main.c diff --git a/test/tvec-main.c b/test/tvec-main.c index aa36180..25698a8 100644 --- a/test/tvec-main.c +++ b/test/tvec-main.c @@ -56,8 +56,6 @@ static const struct outform { { 0, 0 } }; -static struct bench_state benchstate; - const struct tvec_info tvec_adhocinfo = { 0, 1, 1, sizeof(struct tvec_reg) }; @@ -101,7 +99,6 @@ Options:\n\ \n\ -f, --format=FORMAT produce output in FORMAT.\n\ -o, --output=OUTPUT write output to OUTPUT file.\n\ - -t, --target=SECS aim to run benchmarks for SECS.\n\ ", fp); } @@ -111,10 +108,8 @@ void tvec_parseargs(int argc, char *argv[], struct tvec_state *tv_out, FILE *ofp = 0; const struct outform *of = 0; struct tvec_output *o; - struct bench_timer *tm; - const char *p; char *q; + const char *p; int opt; - double t; unsigned f = 0; #define f_bogus 1u @@ -125,15 +120,12 @@ void tvec_parseargs(int argc, char *argv[], struct tvec_state *tv_out, { "format", OPTF_ARGREQ, 0, 'f' }, { "output", OPTF_ARGREQ, 0, 'o' }, - { "target", OPTF_ARGREQ, 0, 't' }, { 0, 0, 0, 0 } }; - tvec_benchstate = &benchstate; - tm = bench_createtimer(); bench_init(&benchstate, tm); ego(argv[0]); for (;;) { - opt = mdwopt(argc, argv, "hvu" "f:o:t:", options, 0, 0, 0); + opt = mdwopt(argc, argv, "hvu" "f:o:", options, 0, 0, 0); if (opt < 0) break; switch (opt) { case 'h': help(stdout); exit(0); @@ -148,12 +140,6 @@ void tvec_parseargs(int argc, char *argv[], struct tvec_state *tv_out, die(2, "failed to open `%s' for writing: %s", optarg, strerror(errno)); break; - case 't': - errno = 0; t = strtod(optarg, &q); - while (ISSPACE(*q)) q++; - if (errno || *q || t < 0) die(2, "invalid time `%s'", optarg); - benchstate.target_s = t; - break; default: f |= f_bogus;