[cairo] [PATCH 02/12] Improve the documentation of the flags
Andrea Canciani
ranma42 at gmail.com
Sat Nov 12 13:19:54 PST 2011
Some utilities were providing incorrect or incomplete usage
information.
---
perf/cairo-analyse-trace.c | 11 +++++------
perf/cairo-perf-micro.c | 10 +++++-----
perf/cairo-perf-trace.c | 13 +++++++------
test/cairo-test-runner.c | 9 ++++-----
test/cairo-test-trace.c | 7 +++----
5 files changed, 24 insertions(+), 26 deletions(-)
diff --git a/perf/cairo-analyse-trace.c b/perf/cairo-analyse-trace.c
index 6cd77f6..5e0ad70 100644
--- a/perf/cairo-analyse-trace.c
+++ b/perf/cairo-analyse-trace.c
@@ -256,18 +256,17 @@ static void
usage (const char *argv0)
{
fprintf (stderr,
-"Usage: %s [-l] [-r] [-v] [-i iterations] [test-names ... | traces ...]\n"
-" %s -l\n"
+"Usage: %s [-l] [-i iterations] [-x exclude-file] [test-names ... | traces ...]\n"
"\n"
-"Run the cairo performance test suite over the given tests (all by default)\n"
+"Run the cairo trace analysis suite over the given tests (all by default)\n"
"The command-line arguments are interpreted as follows:\n"
"\n"
-" -v verbose\n"
-" -x exclude; specify a file to read a list of traces to exclude\n"
+" -i iterations; specify the number of iterations per test case\n"
" -l list only; just list selected test case names without executing\n"
+" -x exclude; specify a file to read a list of traces to exclude\n"
"\n"
"If test names are given they are used as sub-string matches so a command\n"
-"such as \"cairo-perf-trace firefox\" can be used to run all firefox traces.\n"
+"such as \"%s firefox\" can be used to run all firefox traces.\n"
"Alternatively, you can specify a list of filenames to execute.\n",
argv0, argv0);
}
diff --git a/perf/cairo-perf-micro.c b/perf/cairo-perf-micro.c
index 63aad71..572593b 100644
--- a/perf/cairo-perf-micro.c
+++ b/perf/cairo-perf-micro.c
@@ -315,19 +315,19 @@ static void
usage (const char *argv0)
{
fprintf (stderr,
-"Usage: %s [-l] [-r] [-v] [-i iterations] [test-names ...]\n"
-" %s -l\n"
+"Usage: %s [-flrv] [-i iterations] [test-names ...]\n"
"\n"
"Run the cairo performance test suite over the given tests (all by default)\n"
"The command-line arguments are interpreted as follows:\n"
"\n"
-" -r raw; display each time measurement instead of summary statistics\n"
-" -v verbose; in raw mode also show the summaries\n"
+" -f fast; faster, less accurate\n"
" -i iterations; specify the number of iterations per test case\n"
" -l list only; just list selected test case names without executing\n"
+" -r raw; display each time measurement instead of summary statistics\n"
+" -v verbose; in raw mode also show the summaries\n"
"\n"
"If test names are given they are used as sub-string matches so a command\n"
-"such as \"cairo-perf text\" can be used to run all text test cases.\n",
+"such as \"%s text\" can be used to run all text test cases.\n",
argv0, argv0);
}
diff --git a/perf/cairo-perf-trace.c b/perf/cairo-perf-trace.c
index 3e5ba95..7259f2f 100644
--- a/perf/cairo-perf-trace.c
+++ b/perf/cairo-perf-trace.c
@@ -354,21 +354,22 @@ static void
usage (const char *argv0)
{
fprintf (stderr,
-"Usage: %s [-l] [-r] [-v] [-i iterations] [test-names ... | traces ...]\n"
-" %s -l\n"
+"Usage: %s [-clrsv] [-i iterations] [-t tile-size] [-x exclude-file] [test-names ... | traces ...]\n"
"\n"
"Run the cairo performance test suite over the given tests (all by default)\n"
"The command-line arguments are interpreted as follows:\n"
"\n"
+" -c use surface cache; keep a cache of surfaces to be reused\n"
+" -i iterations; specify the number of iterations per test case\n"
+" -l list only; just list selected test case names without executing\n"
" -r raw; display each time measurement instead of summary statistics\n"
" -s sync; only sum the elapsed time of the indiviual operations\n"
+" -t tile size; draw to tiled surfaces\n"
" -v verbose; in raw mode also show the summaries\n"
-" -i iterations; specify the number of iterations per test case\n"
-" -x exclude; specify a file to read a list of traces to exclude\n"
-" -l list only; just list selected test case names without executing\n"
+" -x exclude; specify a file to read a list of traces to exclude\n"
"\n"
"If test names are given they are used as sub-string matches so a command\n"
-"such as \"cairo-perf-trace firefox\" can be used to run all firefox traces.\n"
+"such as \"%s firefox\" can be used to run all firefox traces.\n"
"Alternatively, you can specify a list of filenames to execute.\n",
argv0, argv0);
}
diff --git a/test/cairo-test-runner.c b/test/cairo-test-runner.c
index c0a7e95..6a1fc98 100644
--- a/test/cairo-test-runner.c
+++ b/test/cairo-test-runner.c
@@ -341,7 +341,6 @@ usage (const char *argv0)
{
fprintf (stderr,
"Usage: %s [-afkxsl] [test-names|keywords ...]\n"
- " %s -l\n"
"\n"
"Run the cairo conformance test suite over the given tests (all by default)\n"
"The command-line arguments are interpreted as follows:\n"
@@ -350,15 +349,15 @@ usage (const char *argv0)
" skips similar surface and device offset testing.\n"
" -f foreground; do not fork\n"
" -k match tests by keyword\n"
+ " -l list only; just list selected test case names without executing\n"
" -s include slow, long running tests\n"
" -x exit on first failure\n"
- " -l list only; just list selected test case names without executing\n"
"\n"
"If test names are given they are used as matches either to a specific\n"
"test case or to a keyword, so a command such as\n"
- "\"cairo-test-suite -k text\" can be used to run all text test cases, and\n"
- "\"cairo-test-suite text-transform\" to run the individual case.\n",
- argv0, argv0);
+ "\"%s -k text\" can be used to run all text test cases, and\n"
+ "\"%s text-transform\" to run the individual case.\n",
+ argv0, argv0, argv0);
}
static void
diff --git a/test/cairo-test-trace.c b/test/cairo-test-trace.c
index 89ef651..fdc8a62 100644
--- a/test/cairo-test-trace.c
+++ b/test/cairo-test-trace.c
@@ -1527,17 +1527,16 @@ static void
usage (const char *argv0)
{
fprintf (stderr,
-"Usage: %s [-x exclude-file] [test-names ... | traces ...]\n"
-" %s -l\n"
+"Usage: %s [-l] [-x exclude-file] [test-names ... | traces ...]\n"
"\n"
"Run the cairo test suite over the given traces (all by default).\n"
"The command-line arguments are interpreted as follows:\n"
"\n"
-" -x exclude; specify a file to read a list of traces to exclude\n"
" -l list only; just list selected test case names without executing\n"
+" -x exclude; specify a file to read a list of traces to exclude\n"
"\n"
"If test names are given they are used as sub-string matches so a command\n"
-"such as \"cairo-test-trace firefox\" can be used to run all firefox traces.\n"
+"such as \"%s firefox\" can be used to run all firefox traces.\n"
"Alternatively, you can specify a list of filenames to execute.\n",
argv0, argv0);
}
--
1.7.5.4
More information about the cairo
mailing list