[lttng-dev] 'call_rcu' unstable?

zs 84500316 at qq.com
Tue Dec 11 09:20:13 EST 2012


Hi list,

I found a big problem in my product, that use urcu 0.7.5. My program cost too mutch CPU in the funtion 'update_counter_and_wait:uruc.c:247', and I use gdb to see to *wait_loops*, it says -167777734. The CPU usage grows up from 1% to 100% in one day!


Here is the sample code to show how I use urcu library:

#include <urcu.h>

thread ()
{
rcu_register_thread();

for (;;) {
rcu_read_lock();
xxx
rcu_read_unlock();
}
}

main()
{
rcu_init();
  pthread_create(, , , , thread);

rcu_register_thread();
for (;;)
{
 if (xxx)
   call_rcu();
}

}


More information about the lttng-dev mailing list