From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S965322AbcIWIo6 (ORCPT ); Fri, 23 Sep 2016 04:44:58 -0400 Received: from bombadil.infradead.org ([198.137.202.9]:59604 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S964961AbcIWIoy (ORCPT ); Fri, 23 Sep 2016 04:44:54 -0400 Date: Fri, 23 Sep 2016 10:44:42 +0200 From: Peter Zijlstra To: "Paul E. McKenney" Cc: Mikulas Patocka , hpa@zytor.com, josh@joshtriplett.org, rostedt@goodmis.org, mathieu.desnoyers@efficios.com, jiangshanlai@gmail.com, torvalds@linux-foundation.org, mingo@kernel.org, tglx@linutronix.de, linux-kernel@vger.kernel.org, oleg@redhat.com, linux-tip-commits@vger.kernel.org Subject: Re: [tip:sched/core] sched/core: Avoid _cond_resched() for PREEMPT=y Message-ID: <20160923084442.GC5008@twins.programming.kicks-ass.net> References: <20160922184228.GA5012@twins.programming.kicks-ass.net> <20160922202817.GT14933@linux.vnet.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20160922202817.GT14933@linux.vnet.ibm.com> User-Agent: Mutt/1.5.23.1 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Sep 22, 2016 at 01:28:17PM -0700, Paul E. McKenney wrote: > On Thu, Sep 22, 2016 at 08:42:28PM +0200, Peter Zijlstra wrote: > > On Thu, Sep 22, 2016 at 02:25:01PM -0400, Mikulas Patocka wrote: > > > I've found a document that says that cond_resched() is needed on > > > preemptible kernels to mark RCU quiescent states: > > > > > > https://lwn.net/Articles/603252/ > > > > > > Paul, is cond_resched() still needed on current RCU implementation? Or not? > > > > No, we ripped that out. See 4a81e8328d37 ("rcu: Reduce overhead of > > cond_resched() checks for RCU") > > I would instead say that we changed the algorithm to reduce the overhead > in the common case, but yes, this commit did change things quite a bit. Sure, but critical point (for this discussion) is that cond_resched() no longer implies anything RCU, it really only is a voluntary reschedule point.