From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id E4BF8C02193 for ; Tue, 4 Feb 2025 16:10:51 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 60B356B0082; Tue, 4 Feb 2025 11:10:51 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 5BBD26B0083; Tue, 4 Feb 2025 11:10:51 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4842C6B0088; Tue, 4 Feb 2025 11:10:51 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id 2CF526B0082 for ; Tue, 4 Feb 2025 11:10:51 -0500 (EST) Received: from smtpin14.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id D8618808BA for ; Tue, 4 Feb 2025 16:10:50 +0000 (UTC) X-FDA: 83082750660.14.5A14FEC Received: from nyc.source.kernel.org (nyc.source.kernel.org [147.75.193.91]) by imf06.hostedemail.com (Postfix) with ESMTP id E6D6B180014 for ; Tue, 4 Feb 2025 16:10:48 +0000 (UTC) Authentication-Results: imf06.hostedemail.com; dkim=none; spf=pass (imf06.hostedemail.com: domain of "SRS0=0UFz=U3=goodmis.org=rostedt@kernel.org" designates 147.75.193.91 as permitted sender) smtp.mailfrom="SRS0=0UFz=U3=goodmis.org=rostedt@kernel.org"; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1738685449; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=t62YOfkTJRujFHywoULdeQOLDFbRkBMFeKTLueH9TkQ=; b=mTW/f5TW9FGGh8oSb1H6Jnh/FPRWy2bSUFFIj2tB3i5Sm3y7XdraDqJOKiNCcbmYg8yG1+ B/ULJPj4ZNdcn2pyli6b7u2sZjHyQJ8dI7ifDfeHj4BnIkPDI8kGiAsUwNSIuEwKCLUc+z ixW06QT0e8bThsbbLrTLfmT4zU9sZi0= ARC-Authentication-Results: i=1; imf06.hostedemail.com; dkim=none; spf=pass (imf06.hostedemail.com: domain of "SRS0=0UFz=U3=goodmis.org=rostedt@kernel.org" designates 147.75.193.91 as permitted sender) smtp.mailfrom="SRS0=0UFz=U3=goodmis.org=rostedt@kernel.org"; dmarc=none ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1738685449; a=rsa-sha256; cv=none; b=UIM8LH7eUp+X8+E7QTSjHTzwZuGi0dpvgZouYQAKfaf3hNOMHMCm4o0bxgC5flutIyXmrS q8VPug5nQsy063lew3wtJa715ihS9ihhTEyFcJTD9yxDAU3d2vKOv/nUaH30VWQJCmtnZf YxNSA129fR3DpLxPWwqM/nvlLG52N2c= Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by nyc.source.kernel.org (Postfix) with ESMTP id D6A88A429AC; Tue, 4 Feb 2025 16:09:01 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id A608FC4CEDF; Tue, 4 Feb 2025 16:10:43 +0000 (UTC) Date: Tue, 4 Feb 2025 11:11:19 -0500 From: Steven Rostedt To: Peter Zijlstra Cc: linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org, Thomas Gleixner , Ankur Arora , Linus Torvalds , linux-mm@kvack.org, x86@kernel.org, akpm@linux-foundation.org, luto@kernel.org, bp@alien8.de, dave.hansen@linux.intel.com, hpa@zytor.com, juri.lelli@redhat.com, vincent.guittot@linaro.org, willy@infradead.org, mgorman@suse.de, jon.grimm@amd.com, bharata@amd.com, raghavendra.kt@amd.com, boris.ostrovsky@oracle.com, konrad.wilk@oracle.com, jgross@suse.com, andrew.cooper3@citrix.com, Joel Fernandes , Vineeth Pillai , Suleiman Souhlal , Ingo Molnar , Mathieu Desnoyers , Clark Williams , bigeasy@linutronix.de, daniel.wagner@suse.com, joseph.salisbury@oracle.com, broonie@gmail.com Subject: Re: [RFC][PATCH 1/2] sched: Extended scheduler time slice Message-ID: <20250204111119.10ee37c8@gandalf.local.home> In-Reply-To: <20250204153053.GX7145@noisy.programming.kicks-ass.net> References: <20250131225837.972218232@goodmis.org> <20250131225942.365475324@goodmis.org> <20250201115906.GB8256@noisy.programming.kicks-ass.net> <20250201181129.GA34937@noisy.programming.kicks-ass.net> <20250201180617.491ce087@batman.local.home> <20250203084306.GC505@noisy.programming.kicks-ass.net> <20250203114537.6a30c7c0@gandalf.local.home> <20250204091613.GQ7145@noisy.programming.kicks-ass.net> <20250204075100.3fcbfda8@gandalf.local.home> <20250204153053.GX7145@noisy.programming.kicks-ass.net> X-Mailer: Claws Mail 3.20.0git84 (GTK+ 2.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Server: rspam02 X-Rspamd-Queue-Id: E6D6B180014 X-Stat-Signature: cnpi79ad1ea8omkbptfwp1c1bgmny9f8 X-Rspam-User: X-HE-Tag: 1738685448-930506 X-HE-Meta: U2FsdGVkX1/b7nvQoXLrZko0sP6xw43PeKFc5t4OLnDlq9Dmi5z/Xe1kpp4WmzpGl2Z3pGfkFeyaNX2MSyIhHZUpmqrwhhmYtu/qlydtuppA4y9XIBk7ArYhqyUR3S+NSLf4UZUkfQUmnF5kyPVHPZgE6Jtw0P6wFGimNtq7N6cp8uhbaclTUeBbKim306uVso6P2vN5rWpOetKxtVGJXOB56g44m0r0KaDOMzIRggrTwEpKTll9Qf5spZYUmtWMZouZtyE47EZ8mJI/EejpPcwqSa25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== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: On Tue, 4 Feb 2025 16:30:53 +0100 Peter Zijlstra wrote: > If you go back and reread that initial thread, you'll find the 50us is > below the scheduling latency that random test box already had. > > I'm sure more modern systems will have a lower number, and slower > systems will have a larger number, but we got to pick a number :/ > > I'm fine with making it 20us. Or whatever. Its just a stupid number. > > But yes. If we're going to be doing this, there is absolutely no reason > not to allow DEADLINE/FIFO threads the same. Misbehaving FIFO is already > a problem, and we can make DL-CBS enforcement punch through it if we > have to. > > And less retries on the RSEQ for FIFO can equally improve performance. > > There is no difference between a 'malicious/broken' userspace consuming > the entire window in userspace (50us, 20us whatever it will be) and > doing a system call which we know will cause similar delays because it > does in-kernel locking. This is where we will disagree for the reasons I explained in my second email. This feature affects other tasks. And no, making it 20us doesn't make it better. Because from what I get from you, if we implement this, it will be available for all preemption methods (including PREEMPT_RT), where we do have less than 50us latency, and and even a 20us will break those applications. This was supposed to be only a hint to the kernel, not a complete feature that is hard coded and will override how other tasks behave. As system calls themselves can make how things are scheduled depending on the preemption method, I didn't want to add something that will change how things are scheduled that ignores the preemption method that was chosen. -- Steve