X-Git-Url: http://git.liburcu.org/?a=blobdiff_plain;f=tests%2Ftest_mutex.c;h=99e255364fe02d256372b96bbd0fcdffe0a7bb8f;hb=2d72fae24ceebe2efa486b5bad421f39917ec0a6;hp=ba184a47e241ee2fd0cedb6eca326d805bcd3fac;hpb=bd252a04bbbb163aa4d8864b1e1e5a3a4d9d0892;p=userspace-rcu.git diff --git a/tests/test_mutex.c b/tests/test_mutex.c index ba184a4..99e2553 100644 --- a/tests/test_mutex.c +++ b/tests/test_mutex.c @@ -195,7 +195,8 @@ void *thr_reader(void *data) unsigned long tidx = (unsigned long)data; printf_verbose("thread_begin %s, thread id : %lx, tid %lu\n", - "reader", pthread_self(), (unsigned long)gettid()); + "reader", (unsigned long) pthread_self(), + (unsigned long) gettid()); set_affinity(); @@ -216,7 +217,8 @@ void *thr_reader(void *data) tot_nr_reads[tidx] = URCU_TLS(nr_reads); printf_verbose("thread_end %s, thread id : %lx, tid %lu\n", - "reader", pthread_self(), (unsigned long)gettid()); + "reader", (unsigned long) pthread_self(), + (unsigned long) gettid()); return ((void*)1); } @@ -226,7 +228,8 @@ void *thr_writer(void *data) unsigned long wtidx = (unsigned long)data; printf_verbose("thread_begin %s, thread id : %lx, tid %lu\n", - "writer", pthread_self(), (unsigned long)gettid()); + "writer", (unsigned long) pthread_self(), + (unsigned long) gettid()); set_affinity(); @@ -250,7 +253,8 @@ void *thr_writer(void *data) } printf_verbose("thread_end %s, thread id : %lx, tid %lu\n", - "writer", pthread_self(), (unsigned long)gettid()); + "writer", (unsigned long) pthread_self(), + (unsigned long) gettid()); tot_nr_writes[wtidx] = URCU_TLS(nr_writes); return ((void*)2); } @@ -356,7 +360,8 @@ int main(int argc, char **argv) printf_verbose("Writer delay : %lu loops.\n", wdelay); printf_verbose("Reader duration : %lu loops.\n", rduration); printf_verbose("thread %-6s, thread id : %lx, tid %lu\n", - "main", pthread_self(), (unsigned long)gettid()); + "main", (unsigned long) pthread_self(), + (unsigned long) gettid()); tid_reader = malloc(sizeof(*tid_reader) * nr_readers); tid_writer = malloc(sizeof(*tid_writer) * nr_writers);