X-Git-Url: http://git.lttng.org/?a=blobdiff_plain;f=tests%2Ftest_urcu_qsbr_timing.c;h=b50c95f3f82bdfd3010499291246d084c371c0b0;hb=6ff854acfa013195bdb71dddc654ec76a4c296c9;hp=792554867735702c007736c2713125ffa8060686;hpb=8cbc3cdca7f1320e3c2412654091fe94931ce62b;p=userspace-rcu.git diff --git a/tests/test_urcu_qsbr_timing.c b/tests/test_urcu_qsbr_timing.c index 7925548..b50c95f 100644 --- a/tests/test_urcu_qsbr_timing.c +++ b/tests/test_urcu_qsbr_timing.c @@ -108,7 +108,8 @@ void *thr_reader(void *arg) cycles_t time1, time2; printf("thread_begin %s, thread id : %lx, tid %lu\n", - "reader", pthread_self(), (unsigned long)gettid()); + "reader", (unsigned long) pthread_self(), + (unsigned long) gettid()); sleep(2); rcu_register_thread(); @@ -133,7 +134,8 @@ void *thr_reader(void *arg) sleep(2); printf("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); } @@ -145,7 +147,8 @@ void *thr_writer(void *arg) cycles_t time1, time2; printf("thread_begin %s, thread id : %lx, tid %lu\n", - "writer", pthread_self(), (unsigned long)gettid()); + "writer", (unsigned long) pthread_self(), + (unsigned long) gettid()); sleep(2); for (i = 0; i < OUTER_WRITE_LOOP; i++) { @@ -173,7 +176,8 @@ void *thr_writer(void *arg) } printf("thread_end %s, thread id : %lx, tid %lu\n", - "writer", pthread_self(), (unsigned long)gettid()); + "writer", (unsigned long) pthread_self(), + (unsigned long) gettid()); return ((void*)2); } @@ -199,7 +203,8 @@ int main(int argc, char **argv) tid_writer = malloc(sizeof(*tid_writer) * num_write); printf("thread %-6s, thread id : %lx, tid %lu\n", - "main", pthread_self(), (unsigned long)gettid()); + "main", (unsigned long) pthread_self(), + (unsigned long) gettid()); for (i = 0; i < NR_READ; i++) { err = pthread_create(&tid_reader[i], NULL, thr_reader,