Cleanup: missing sign compare fixes
authorMichael Jeanson <mjeanson@efficios.com>
Wed, 19 Dec 2018 16:44:57 +0000 (11:44 -0500)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Wed, 19 Dec 2018 16:53:34 +0000 (11:53 -0500)
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
tests/benchmark/test_perthreadlock.c
tests/benchmark/test_urcu_gc.c
tests/benchmark/test_urcu_qsbr_gc.c

index 512b1fc8ff1dc1f6697c28911ce382cec3c1ebe3..f02e00b43e8db6144911dd4512a3f49875c9ac41 100644 (file)
@@ -220,7 +220,7 @@ void *thr_writer(void *data)
        cmm_smp_mb();
 
        for (;;) {
-               for (tidx = 0; tidx < nr_readers; tidx++) {
+               for (tidx = 0; tidx < (long)nr_readers; tidx++) {
                        urcu_mutex_lock(&per_thread_lock[tidx].lock);
                }
                test_array.a = 0;
index 1e50e4c5f4a369bed7f775cab7417cb872d743ea..34cf141f7a60cea458456958d4cdf095b9d15c51 100644 (file)
@@ -55,7 +55,7 @@ static unsigned long wdelay;
 
 static struct test_array *test_rcu_pointer;
 
-static unsigned int reclaim_batch = 1;
+static long reclaim_batch = 1;
 
 struct reclaim_queue {
        void **queue;   /* Beginning of queue */
@@ -449,7 +449,7 @@ int main(int argc, char **argv)
        printf("SUMMARY %-25s testdur %4lu nr_readers %3u rdur %6lu wdur %6lu "
                "nr_writers %3u "
                "wdelay %6lu nr_reads %12llu nr_writes %12llu nr_ops %12llu "
-               "batch %u\n",
+               "batch %ld\n",
                argv[0], duration, nr_readers, rduration, wduration,
                nr_writers, wdelay, tot_reads, tot_writes,
                tot_reads + tot_writes, reclaim_batch);
index 11f0359fac1be97158b4bc8a40775d7a08c5f172..26bc3523bb77f43937c719fea07eb88fe8f43bf4 100644 (file)
@@ -57,7 +57,7 @@ static unsigned long duration;
 
 /* read-side C.S. duration, in loops */
 static unsigned long rduration;
-static unsigned int reclaim_batch = 1;
+static long reclaim_batch = 1;
 
 struct reclaim_queue {
        void **queue;   /* Beginning of queue */
@@ -450,7 +450,7 @@ int main(int argc, char **argv)
        printf("SUMMARY %-25s testdur %4lu nr_readers %3u rdur %6lu wdur %6lu "
                "nr_writers %3u "
                "wdelay %6lu nr_reads %12llu nr_writes %12llu nr_ops %12llu "
-               "batch %u\n",
+               "batch %ld\n",
                argv[0], duration, nr_readers, rduration, wduration,
                nr_writers, wdelay, tot_reads, tot_writes,
                tot_reads + tot_writes, reclaim_batch);
This page took 0.026176 seconds and 4 git commands to generate.