Received: by 2002:a05:7412:1e0b:b0:fc:a2b0:25d7 with SMTP id kr11csp669322rdb; Thu, 15 Feb 2024 11:28:54 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCVNJC9fVeeGHR2yme4KCGwGTbnP7IJWbj/Og83yqLI8qzCxJ383tsL+H4sQwCezlKqRrEBf5adiMT8MVMk969PUM3qGIbXxxnQk5Dz3EA== X-Google-Smtp-Source: AGHT+IHo4XDxJ2tEZFcPuQysR0Ncb7RxcufA+zT4//hF4JWlntkZfleKiipq93poH5Afo+vPz09K X-Received: by 2002:a05:6359:411f:b0:176:5364:4c11 with SMTP id kh31-20020a056359411f00b0017653644c11mr2791940rwc.18.1708025334448; Thu, 15 Feb 2024 11:28:54 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708025334; cv=pass; d=google.com; s=arc-20160816; b=PGZjNnTmiKGCc2vsKusgnqsgYyP4YI21ASHFxxwkNpKdS2pD7huWTwZUgkOyKhVa4W hvin3OprkaGDLpj7I/cqSYY9mxNRo1FnlznDTZdYdQ3x0BVKkC/1Ckzm3NL/y5M94sWn stqrsM3M4BXB0+J+fUZ24ujwWzrMw4WMs0S9lu8cVPoUPF5bsSAbIysXMyqHYsh6PTwz QqTnXLwm30IP2Zl5x0117kE+n/4TlYm7nUH1JmAf42rPkU1wfvxm/Yj611eUf665J/pW nIxMdPQV41e1kuZiSFWbR5MN3kxShpOkuy0ZTwW/DuHYIabRDWaaucIgFAL6SauzksvP vSOw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:reply-to:message-id :subject:cc:to:from:date:dkim-signature; bh=KG4UM0vZlZ1gmkJl9lb9/T8j5Qf0RxT1uzGaI0PKfas=; fh=2yzE0UqQvLDn164zJepdvpr2KfEwPQCyCN2MGlkRLRg=; b=IWKLCqZwbono5MOLB89sjXcaNxgNDchutqiOjbKF+wsGwM7Cdo4Iwfn4sQ2enjRfCv 3wrqUjIFKnxhDGFuabnS/heVbwIfdWCNi2C/7SIavjPkOSNcpg+ZmsYepJ5ttNAfovec TR4cYXmQwcaXHLVGhOcmeLkCEi8fQB6LeBYq1CUb3WxwG8VGWwUMpLPrsscTHTPk0DzO FuJ+pJfRkkPeWrenps2vTx+A2acUkYh54LKVhnhqVjEzmRTm6OzoHl2APs/gXfRjLEgK EvcnPi/YGRCGxsw4FhpRf4+hOcqg/ZTkd3sayuWtel0/o1iTwV4JGtsQwCtvbIQ9nwiG ugUQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=aYLvNPLv; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-67580-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-67580-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id x124-20020a636382000000b005dc816e3080si1615232pgb.12.2024.02.15.11.28.54 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 15 Feb 2024 11:28:54 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-67580-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=aYLvNPLv; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-67580-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-67580-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 272B0289CF8 for ; Thu, 15 Feb 2024 19:28:54 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 5CC0813A27D; Thu, 15 Feb 2024 19:28:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="aYLvNPLv" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 85BF513A269 for ; Thu, 15 Feb 2024 19:28:35 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708025315; cv=none; b=aDmcJ0UEqUe0OVUsWSLg4RwzA7jO/5R00qPI3Jm602hM6G3gezBRfLn9S5C78Ma+i1Dt+pbaVC2FOv1TsDya6Kk4NiegokoPXtU6YInyvZhNKiRJGOqk/uxLEOhDFiel64n/1k00a4UDtmvlhL8NzKXt86Ao7RPtwCYBqhk4Zlc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708025315; c=relaxed/simple; bh=0kM+zjcqTLYhv7yd9HTfbFlqiT7ZOFsFU4xJukY2mcw=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=RtTXqy2ZhEtnAi/BX3pWcd5kY1w+c/7EA4r4miRNW5Ds1U1yW2KB385sCnzV8O2BVanf3jh+cWT5UtD0bOBP/BUe/mZAN6S8EVAXzhrSzxcFc6DDwx3sKQW4zf8U7H2IrE6KUkHLVhwmU33hGCZuDPMV9VtwTeG1LXScvDm3CMc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=aYLvNPLv; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4D2AAC433F1; Thu, 15 Feb 2024 19:28:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1708025315; bh=0kM+zjcqTLYhv7yd9HTfbFlqiT7ZOFsFU4xJukY2mcw=; h=Date:From:To:Cc:Subject:Reply-To:References:In-Reply-To:From; b=aYLvNPLvrqx4jBIpmHk6IB6sl2Rxpa2Zq1u4/cAXTBsX9dGQNqnEK/qSRKeohJX5R G/ldsZGmAXz4wzris2194+88sRlrvFLBh6DLfdVG0NmHPDtqR9XRb+ERyxLUAMPE00 irYRjetRTvGb2RC8FJws1pa0rdAJM7o3UGctTXGETkMNXr/nPtEYElmELtCBpM7aeH raO0YBzwvswnN4mzUzj/dJFKMTzMFewhbl5iGkd8K3SX517qK+HzU7l3PJKN5YYC0P du/inx/GJoPjvGtqy2sbE6ckuQFVnWZsdXcc9gEM0NUq5Aj2ASqouBGXc8pfW2TjPg HlV9tjCzCLr4g== Received: by paulmck-ThinkPad-P17-Gen-1.home (Postfix, from userid 1000) id DD794CE0D0D; Thu, 15 Feb 2024 11:28:34 -0800 (PST) Date: Thu, 15 Feb 2024 11:28:34 -0800 From: "Paul E. McKenney" To: Ankur Arora Cc: linux-kernel@vger.kernel.org, tglx@linutronix.de, peterz@infradead.org, torvalds@linux-foundation.org, akpm@linux-foundation.org, luto@kernel.org, bp@alien8.de, dave.hansen@linux.intel.com, hpa@zytor.com, mingo@redhat.com, juri.lelli@redhat.com, vincent.guittot@linaro.org, willy@infradead.org, mgorman@suse.de, jpoimboe@kernel.org, mark.rutland@arm.com, jgross@suse.com, andrew.cooper3@citrix.com, bristot@kernel.org, mathieu.desnoyers@efficios.com, glaubitz@physik.fu-berlin.de, anton.ivanov@cambridgegreys.com, mattst88@gmail.com, krypton@ulrich-teichert.org, rostedt@goodmis.org, David.Laight@aculab.com, richard@nod.at, jon.grimm@amd.com, bharata@amd.com, boris.ostrovsky@oracle.com, konrad.wilk@oracle.com Subject: Re: [PATCH 00/30] PREEMPT_AUTO: support lazy rescheduling Message-ID: <0d4a4eec-ce91-48da-91b6-1708a97edaeb@paulmck-laptop> Reply-To: paulmck@kernel.org References: <20240213055554.1802415-1-ankur.a.arora@oracle.com> <87le7mpjpr.fsf@oracle.com> <4e070ae0-29dc-41ee-aee6-0d3670304825@paulmck-laptop> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4e070ae0-29dc-41ee-aee6-0d3670304825@paulmck-laptop> On Wed, Feb 14, 2024 at 07:45:18PM -0800, Paul E. McKenney wrote: > On Wed, Feb 14, 2024 at 06:03:28PM -0800, Ankur Arora wrote: > > > > Paul E. McKenney writes: > > > > > On Mon, Feb 12, 2024 at 09:55:24PM -0800, Ankur Arora wrote: > > >> Hi, > > >> > > >> This series adds a new scheduling model PREEMPT_AUTO, which like > > >> PREEMPT_DYNAMIC allows dynamic switching between a none/voluntary/full > > >> preemption model. However, unlike PREEMPT_DYNAMIC, it doesn't depend > > >> on explicit preemption points for the voluntary models. > > >> > > >> The series is based on Thomas' original proposal which he outlined > > >> in [1], [2] and in his PoC [3]. > > >> > > >> An earlier RFC version is at [4]. > > > > > > This uncovered a couple of latent bugs in RCU due to its having been > > > a good long time since anyone built a !SMP preemptible kernel with > > > non-preemptible RCU. I have a couple of fixes queued on -rcu [1], most > > > likely for the merge window after next, but let me know if you need > > > them sooner. > > > > Thanks. As you can probably tell, I skipped out on !SMP in my testing. > > But, the attached diff should tide me over until the fixes are in. > > That was indeed my guess. ;-) > > > > I am also seeing OOM conditions during rcutorture testing of callback > > > flooding, but I am still looking into this. > > > > That's on the PREEMPT_AUTO && PREEMPT_VOLUNTARY configuration? > > On two of the PREEMPT_AUTO && PREEMPT_NONE configurations, but only on > two of them thus far. I am running a longer test to see if this might > be just luck. If not, I look to see what rcutorture scenarios TREE10 > and TRACE01 have in common. And still TRACE01 and TREE10 are hitting OOMs, still not seeing what sets them apart. I also hit a grace-period hang in TREE04, which does CONFIG_PREEMPT_VOLUNTARY=y along with CONFIG_PREEMPT_AUTO=y. Something to dig into more. I am also getting these from builds that enable KASAN: vmlinux.o: warning: objtool: mwait_idle+0x13: call to tif_resched.constprop.0() leaves .noinstr.text section vmlinux.o: warning: objtool: acpi_processor_ffh_cstate_enter+0x36: call to tif_resched.constprop.0() leaves .noinstr.text section vmlinux.o: warning: objtool: cpu_idle_poll.isra.0+0x18: call to tif_resched.constprop.0() leaves .noinstr.text section vmlinux.o: warning: objtool: acpi_safe_halt+0x0: call to tif_resched.constprop.0() leaves .noinstr.text section vmlinux.o: warning: objtool: poll_idle+0x33: call to tif_resched.constprop.0() leaves .noinstr.text section vmlinux.o: warning: objtool: default_enter_idle+0x18: call to tif_resched.constprop.0() leaves .noinstr.text section Does tif_resched() need to be marked noinstr or some such? Tracing got harder to disable, but I beleive that is unrelated to lazy preemption. ;-) Thanx, Paul