test_urcu_lfq: remove rcu_defer_register_thread() from test_urcu_lfq
authorLai Jiangshan <laijs@cn.fujitsu.com>
Sat, 13 Oct 2012 16:48:54 +0000 (12:48 -0400)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Sat, 13 Oct 2012 16:48:54 +0000 (12:48 -0400)
test_urcu_lfq has already switch to call_rcu(),
rcu_defer_register_thread() is unneeded.

Signed-off-by: Lai Jiangshan <laijs@cn.fujitsu.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
tests/test_urcu_lfq.c

index 1bbaf3cfd504a2abd0ead6e724f2b514c079dff5..ec5d822d1b1dde350af55b99fd8dd009bed5c293 100644 (file)
@@ -67,7 +67,6 @@ static inline pid_t gettid(void)
 #endif
 #include <urcu.h>
 #include <urcu/cds.h>
-#include <urcu-defer.h>
 
 static volatile int test_go, test_stop;
 
@@ -222,18 +221,12 @@ void free_node_cb(struct rcu_head *head)
 void *thr_dequeuer(void *_count)
 {
        unsigned long long *count = _count;
-       int ret;
 
        printf_verbose("thread_begin %s, thread id : %lx, tid %lu\n",
                        "dequeuer", pthread_self(), (unsigned long)gettid());
 
        set_affinity();
 
-       ret = rcu_defer_register_thread();
-       if (ret) {
-               printf("Error in rcu_defer_register_thread\n");
-               exit(-1);
-       }
        rcu_register_thread();
 
        while (!test_go)
@@ -264,7 +257,6 @@ void *thr_dequeuer(void *_count)
        }
 
        rcu_unregister_thread();
-       rcu_defer_unregister_thread();
        printf_verbose("dequeuer thread_end, thread id : %lx, tid %lu, "
                       "dequeues %llu, successful_dequeues %llu\n",
                       pthread_self(), (unsigned long)gettid(),
This page took 0.026416 seconds and 4 git commands to generate.