On Wed, Jun 24, 2015 at 05:01:51PM +0200, Peter Zijlstra wrote: > On Wed, Jun 24, 2015 at 07:50:42AM -0700, Paul E. McKenney wrote: > > On Wed, Jun 24, 2015 at 09:35:03AM +0200, Peter Zijlstra wrote: > > > > I still don't see a problem here though; the stop_one_cpu() invocation > > > for the CPU that's suffering its preemption latency will take longer, > > > but so what? > > > > > > How does polling and dropping back to sync_rcu() generate better > > > behaviour than simply waiting for the completion? > > > > Because if there is too much delay, synchronize_rcu() is no slower > > than is synchronize_rcu_expedited(), plus synchronize_rcu() is much > > more efficient. > > Still confused.. How is polling and then blocking more efficient than > just blocking in the first place? I'm seeing the polling as a waste of > cpu time.
As I said, the current code is quite old and will get a facelift. > The thing is, if we're stalled on a stop_one_cpu() call, the sync_rcu() > is equally stalled. The sync_rcu() cannot wait more efficient than we're > already waiting either. Ah, but synchronize_rcu() doesn't force waiting on more than one extra grace period. With strictly queued mutex, you can end up waiting on several. Thanx, Paul -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/