summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGary S. Robertson <gary.robertson@linaro.org>2014-03-25 18:05:32 -0500
committerClark Williams <clark.williams@gmail.com>2014-03-26 22:37:50 -0500
commit751b683a9d38e740139c88f5ee06d5b526fceb29 (patch)
treef02df53dcf8d39027978c9f94f9f0e026f5ccf05
parent04db73f6c74ab5957c4f1cdd8d6e3f961acd5588 (diff)
downloadrt-tests-work.tar.gz
Don't offer --numa option when unavailablework
Signed-off-by: Gary S. Robertson <gary.robertson@linaro.org> Signed-off-by: Clark Williams <williams@redhat.com>
-rw-r--r--src/cyclictest/cyclictest.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/cyclictest/cyclictest.c b/src/cyclictest/cyclictest.c
index c3fa60f..23706c7 100644
--- a/src/cyclictest/cyclictest.c
+++ b/src/cyclictest/cyclictest.c
@@ -1034,8 +1034,10 @@ static void display_help(int error)
"-T TRACE --tracer=TRACER set tracing function\n"
" configured tracers: %s\n"
"-u --unbuffered force unbuffered output for live processing\n"
+#ifdef NUMA
"-U --numa Standard NUMA testing (similar to SMP option)\n"
" thread data structures allocated from local node\n"
+#endif
"-v --verbose output values on stdout for statistics\n"
" format: n:c:v n=tasknum c=count v=value in us\n"
"-w --wakeup task wakeup tracing (used with -b)\n"
@@ -1113,10 +1115,10 @@ static void parse_cpumask(const char *option, const int max_cpus)
if (!affinity_mask)
display_help(1);
- if (verbose) {
+// if (verbose) {
printf("%s: Using %u cpus.\n", __func__,
rt_numa_bitmask_count(affinity_mask));
- }
+// }
}
@@ -1241,9 +1243,11 @@ static void process_options (int argc, char *argv[], int max_cpus)
if (smp || numa)
break;
if (optarg != NULL) {
+ printf("optarg != NULL!\n");
parse_cpumask(optarg, max_cpus);
setaffinity = AFFINITY_SPECIFIED;
} else if (optind<argc && atoi(argv[optind])) {
+ printf("optind < argc\n");
parse_cpumask(argv[optind], max_cpus);
setaffinity = AFFINITY_SPECIFIED;
} else {
@@ -1983,7 +1987,7 @@ int main(int argc, char **argv)
case AFFINITY_UNSPECIFIED: par->cpu = -1; break;
case AFFINITY_SPECIFIED:
par->cpu = cpu_for_thread(i, max_cpus);
- if (verbose)
+ //if (verbose)
printf("Thread %d using cpu %d.\n", i,
par->cpu);
break;