Mirror of the lttng-dev mailing list
 help / color / mirror / Atom feed
From: ryx@gwmail.gwu.edu (Yuxin Ren)
Subject: [lttng-dev] Question about lock in synchronize_rcu implementation of URCU
Date: Wed, 27 Apr 2016 21:34:16 -0400	[thread overview]
Message-ID: <CAAKbDrfmcqEE7_6p_J0DPVO85yDGJ0GCbi5k9Lm19g4VaLgOWw@mail.gmail.com> (raw)

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


             reply	other threads:[~2016-04-28  1:34 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-28  1:34 Yuxin Ren [this message]
2016-04-28  2:08 ` Paul E. McKenney
2016-04-28  2:18   ` Yuxin Ren
2016-04-28  4:23     ` Paul E. McKenney
2016-04-28 12:44       ` Boqun Feng
2016-04-28 13:47         ` Yuxin Ren
2016-04-28 13:55           ` Paul E. McKenney
2016-04-28 14:38           ` Mathieu Desnoyers
2016-04-28 14:57             ` Paul E. McKenney
2016-04-28 16:08           ` Mathieu Desnoyers
2016-04-28 13:53         ` Paul E. McKenney

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAAKbDrfmcqEE7_6p_J0DPVO85yDGJ0GCbi5k9Lm19g4VaLgOWw@mail.gmail.com \
    --to=ryx@gwmail.gwu.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox