From mboxrd@z Thu Jan 1 00:00:00 1970 From: ryx@gwmail.gwu.edu (Yuxin Ren) Date: Wed, 27 Apr 2016 21:34:16 -0400 Subject: [lttng-dev] Question about lock in synchronize_rcu implementation of URCU Message-ID: Hi, I am learning the URCU code. Why do we need rcu_gp_lock in synchronize_rcu? https://github.com/urcu/userspace-rcu/blob/master/urcu.c#L401 In the comment, it says this lock ensures mutual exclusion between threads calling synchronize_rcu(). But only the first thread added to waiter queue can proceed to detect grace period. How can multiple threads currently perform the grace thread? Thanks a lot! Yuxin