From: Mathieu Desnoyers Date: Wed, 16 Sep 2009 16:44:27 +0000 (-0400) Subject: Move mb() outside of the synchronize C.S. X-Git-Tag: v0.1~82 X-Git-Url: https://git.liburcu.org/?p=urcu.git;a=commitdiff_plain;h=4e27f05811113a4444d142811d38e77bcbabbf04 Move mb() outside of the synchronize C.S. Will be useful for future Q.S. merging. Does not change the RCU g.p. guarantee. Signed-off-by: Mathieu Desnoyers --- diff --git a/urcu-qsbr.c b/urcu-qsbr.c index e077eac..b387536 100644 --- a/urcu-qsbr.c +++ b/urcu-qsbr.c @@ -156,12 +156,12 @@ void synchronize_rcu(void) if (was_online) _rcu_thread_offline(); - internal_urcu_lock(); force_mb_all_threads(); + internal_urcu_lock(); STORE_SHARED(urcu_gp_ctr, urcu_gp_ctr + 2); wait_for_quiescent_state(); - force_mb_all_threads(); internal_urcu_unlock(); + force_mb_all_threads(); if (was_online) _rcu_thread_online();