From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (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 BF8C9372057 for ; Tue, 23 Jun 2026 10:15:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=170.10.129.124 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1782209718; cv=none; b=TWKZlG8/lTUYeZ+KL+0T7jn4Xnv7Ac7JpPgOsDaMeV90pMgcTYBagUMutECtumK/UoSwQgoFYptR+r98fEfMd5IO78iLsoT6FVsfZyI+vQQlyaocUVB+VjdDscwz5GkcFjVm9lUuvxQY5oImgnhe5JxuiTqplduwWgv9cZWEhZ8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1782209718; c=relaxed/simple; bh=JhNZfEv7I9RQRMdqT1oCgbFcCZ4KIhLmoBgIJJYst1Y=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=EvkY/DV2RPm1lIl0JptrlGmqXlY85nOhaRvlJ9Mz6jxncUBYPJ3+C35MlCmtP0PcYOSbYsIvU1e3RZSMLLzPvAFo1kKoo3nVRXTs5BD2XJsNirzUq9cRy4lKpYJiJK3T2mJV3kre8e0Hyr+aQo7+954HEknkLLtl3ao8NkNL8DE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com; spf=pass smtp.mailfrom=redhat.com; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b=c9KomqRT; dkim=pass (2048-bit key) header.d=redhat.com header.i=@redhat.com header.b=m4L6lrjb; arc=none smtp.client-ip=170.10.129.124 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="c9KomqRT"; dkim=pass (2048-bit key) header.d=redhat.com header.i=@redhat.com header.b="m4L6lrjb" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1782209715; h=from:from: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=s5lySzCS3c3hJQ/Zsh36ztJ14IpR9Of7jKjOv+WA4eg=; b=c9KomqRTdsj0K+j4PVb/fUTriLHhr/9BoXMNl2WYQspmxYvrnnL0gEKgPdhjOP/FxllFW1 tCdlwPjM330dNGHSkrDSPHjX4okbthbORLqA7jmWbAH1ipxuxbfBFQuw7avRRvP6BNWarC eDc4iu1vLVy9P9LORCGrnmwbFD0Q3HU= Received: from mail-wr1-f72.google.com (mail-wr1-f72.google.com [209.85.221.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-201-GBmryPnTNu652e6krUjHWQ-1; Tue, 23 Jun 2026 06:15:14 -0400 X-MC-Unique: GBmryPnTNu652e6krUjHWQ-1 X-Mimecast-MFC-AGG-ID: GBmryPnTNu652e6krUjHWQ_1782209713 Received: by mail-wr1-f72.google.com with SMTP id ffacd0b85a97d-45ef4931de5so558580f8f.1 for ; Tue, 23 Jun 2026 03:15:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=google; t=1782209713; x=1782814513; darn=vger.kernel.org; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:from:to :cc:subject:date:message-id:reply-to; bh=s5lySzCS3c3hJQ/Zsh36ztJ14IpR9Of7jKjOv+WA4eg=; b=m4L6lrjbP8XAoWiKk6Rrjp8Qvmsf+vkkc9j6Ul2IGow4hX1ZlTjlVafEB/FdQSc3jk 5KgwNQAcPbpNM81LFw7LT9Oy/oixoFROxmCI5U/rD5+XmdDhu3C1FxlGfbkQ1XBNNndM PtmsqESoeN3WXsiX7gIY9Ve2pgyqDevoL2vcUgWGmCHSwO4hCTfmx7CJswkt/BSg3t1y Z+NDisT4PczEkJ6W8NenoxbaMomnXgPcEwRhPxhvpXEvLIBODibJJX+Z2kg8l3L1jbVS 5Su2sQruTiGbVgXim1WzfVhxAdOvFpA0c4I1R7uTyIVtH4cMLAo+Xc2GiTUqq9zkVDgf DgVQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1782209713; x=1782814513; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=s5lySzCS3c3hJQ/Zsh36ztJ14IpR9Of7jKjOv+WA4eg=; b=CPe4fiXxp/HtiW7ym8m0/vbXvJGuDGCtsETAAlwHVVzM17SlRyhYv381Oqg1CMv3WG BqxA35RZ/Jxd21lHe+tYTEyhKs25IOupdlf7HQBfo8iurpnNK3QECm4ek6NpbfekxvUV xDAww4QWW8TdfVXXTsVfMMRBSdUkWEMBDGrTadBVTRO+9zbeNYTASzYcXuVQOYlBeNmz 4qxPXP9f1mtOhiciAyeqLUKqptek2oM0q76R/79bNTX1HJImIXrQwNaT2LyBfuiD6dbK TkCgqNfx43eLLQrvzFcDAvdfURXb6zqcHFB4jLzhQ2iL5h5zA9uiObE7/O+YlaEvyBzG lYmg== X-Forwarded-Encrypted: i=1; AFNElJ/0p6cBxMZ8iTvbzhr2MB5pJJRiGNe84Us9zuEtapOWIykdWe/4rb8dZsp8TZJWR4HQFfR6ASL99xGnVJg=@vger.kernel.org X-Gm-Message-State: AOJu0Yx2k91JZ32rl22D77oOa+1QwUePNlzhDw9WDemHpMATzs+sZ5Gc 7UDS810OxhvVK3Pk5m5ru0pSDHkT51DLpiEwFMlM1MmtUWawmZgKSe7WdgX4UMsWxAOb+WGWBq2 zwVs8mz7OeNLA9mUmz/d7KIrvikZRfJp8EPAhZAIl6ou1poGV/RciWsNiT33kIjiTDg== X-Gm-Gg: AfdE7clcSHIMyh+M2zjmSZgUPQQZ7cRsfJyCyo3JvEUs1dxLLKKnrk6HLpk+QL9Q+3f 9xqTgjL89VKFb+3IV6NI6xF90nJTi6XR1FbAPnVvUayWhz9romd/FBAGWD8Qc+NJCFEB/MxnwmV et4aSayH0J2pmQFr0gwEW5NygWb/ZNXlrLNQw8zk8Ym5ZqyahedpmcU18KdSwh/mqIU5g75nn41 bj+RXeYrx18fXE9BMT2uqi/CwmeeTWfzVU7PAMlMz6XmAB4q2ulHFphkdVCTtFsNeLEE47a4FSm EWt3V6EU1t7uXdE9SMeepDKwWC+IYqidcdtljOmlr+LZeXL6/aHmx9rbQl9VGnNqZmBid64KYxO b2CutC/5GhI3CNoJeNH/Kdrozb0qbWKtFFjt3ooQHTA== X-Received: by 2002:a05:600c:4e8f:b0:48a:53cb:8604 with SMTP id 5b1f17b1804b1-4925a0c4ec8mr42644385e9.14.1782209712920; Tue, 23 Jun 2026 03:15:12 -0700 (PDT) X-Received: by 2002:a05:600c:4e8f:b0:48a:53cb:8604 with SMTP id 5b1f17b1804b1-4925a0c4ec8mr42643925e9.14.1782209712466; Tue, 23 Jun 2026 03:15:12 -0700 (PDT) Received: from jlelli-thinkpadt14gen4.remote.csb ([151.29.133.86]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-49240eef2basm385461965e9.2.2026.06.23.03.15.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 23 Jun 2026 03:15:10 -0700 (PDT) Date: Tue, 23 Jun 2026 12:15:08 +0200 From: Juri Lelli To: Yuri Andriaccio Cc: Ingo Molnar , Peter Zijlstra , Vincent Guittot , Dietmar Eggemann , Steven Rostedt , Ben Segall , Mel Gorman , Valentin Schneider , Tejun Heo , Johannes Weiner , Michal =?iso-8859-1?Q?Koutn=FD?= , cgroups@vger.kernel.org, linux-kernel@vger.kernel.org, Luca Abeni , Yuri Andriaccio Subject: Re: [RFC PATCH v6 00/25] Hierarchical Constant Bandwidth Server Message-ID: References: <20260608121546.69910-1-yurand2000@gmail.com> 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=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20260608121546.69910-1-yurand2000@gmail.com> Hi Yuri, On 08/06/26 14:15, Yuri Andriaccio wrote: > Hello, > > This is the v6 for Hierarchical Constant Bandwidth Server, aiming at replacing > the current RT_GROUP_SCHED mechanism with something more robust and > theoretically sound. The patchset has been presented at OSPM25 and OSPM26 > (https://retis.sssup.it/ospm-summit/), and a summary of its inner workings can > be found at https://lwn.net/Articles/1021332/ . You can find the previous > versions of this patchset at the bottom of the page, in particular version 1 > which talks in more detail what this patchset is all about and how it is > implemented. > > This v6 version works on the comments by the reviewers and introduces the > following meaningful changes: > - Update to kernel version 7.1. > - Refactorings and general cleanups. > - Removal of substantial duplicated code. > - Express more locking constraints in code. > - New cpu.rt.max interface. > - Refactoring of migration code to reduce code duplication. > The new migration code now reuses the existing push/pull and similar functions > and specializes where needed, substantially reducing the footprint of group > migration code from previous versions. I've been working on a simple demo and benchmark suite for HCBS to explore real-world like use cases and characterize the feature's behavior. Different angle wrt your unit test suite (I believe). The demo is available at: https://github.com/jlelli/hcbs-demo The demo models three scenarios — Industrial PLC Convergence, Robotics Compute Platform, and Precision Motion Control — each with multiple cooperating SCHED_FIFO tasks at different priorities sharing a cgroup, which is the key differentiator vs. plain SCHED_DEADLINE. An aggressor subsystem overloads the system while HCBS contains it to its budget. A side-by-side compare mode runs baseline and HCBS simultaneously on separate cpuset partitions, with a live terminal dashboard showing the contrast in real time. Key findings from testing on an Intel Xeon Gold 6433N (4 isolated CPUs via cpuset partition): - At 10ms task periods, HCBS provides perfect temporal isolation: zero victim deadline misses across all scenarios, while aggressors are correctly throttled to their budget. - At 1ms task periods, the dl-server period is the critical tuning parameter, less the bandwidth. A 10ms dl-server with 60% bandwidth caused ~10% miss rates because the worst-case throttle gap (4ms) spanned multiple 1ms deadlines. Switching to a 2ms dl-server period at just 30% bandwidth eliminated all misses. - A simple Rule of thumb might be to set the dl-server period to at most 2x the shortest task period in the cgroup (e.g., 2ms dl-server for 1ms tasks, 10ms for 10ms tasks). Would you (and Luca?) agree or would you suggest something different? - dl-server overhead itself appears negligible: a parameter sweep confirmed zero misses for a single task at all bandwidth/period combinations tested. - The current v6 has been quite stable throughout my testing — no warnings, no crashes, and the bandwidth isolation works as expected across all the scenarios and workload combinations I've tried. The demo supports three workload backends: - rt-app (default): synthetic periodic tasks with configurable periods - RT-Bench TACLeBench (--rtbench): real algorithms (susan, dijkstra, FFT, mpeg2, etc.) matching each scenario's computation profile - stress-ng (--stress): mixed CPU/IO/cache/memory aggressors for realistic interference patterns Recorded demos (asciinema): Industrial: https://asciinema.org/a/5e4BMdWxS7hmm4hI Robotics: https://asciinema.org/a/Msj48XnJGgcCev7M Precision: https://asciinema.org/a/56WC3bu7yrcQe9nz Thanks for the great work on this patchset. Happy to hear if this demo is of any interest, discuss any of the findings and/or understand if/how this can be further expanded. Best, Juri