LWN: Comments on "The end of tasklets" https://lwn.net/Articles/960041/ This is a special feed containing comments posted to the individual LWN article titled "The end of tasklets". en-us Tue, 28 Oct 2025 14:54:05 +0000 Tue, 28 Oct 2025 14:54:05 +0000 https://www.rssboard.org/rss-specification lwn@lwn.net Upside-down halves https://lwn.net/Articles/961735/ https://lwn.net/Articles/961735/ ssmith32 <div class="FormattedComment"> The top is the highest level?<br> Like taking an elevator to the top.<br> </div> Sun, 11 Feb 2024 06:32:19 +0000 The end of tasklets https://lwn.net/Articles/961157/ https://lwn.net/Articles/961157/ Wol <div class="FormattedComment"> <span class="QuotedText">&gt; which triggered investigation into alternatives to CFS, and then inspired Zijlstra to implement EEVDF in a way that matched or beat CFS while also providing latency-nice.</span><br> <p> And this is why Torvalds is such a good manager (and steward). He's not attached to his version, and he actively encourages these short-lived forks precisely to find the best way to do things. Which he then shamelessly appropriates :-)<br> <p> Cheers,<br> Wol<br> </div> Wed, 07 Feb 2024 11:04:49 +0000 The end of tasklets https://lwn.net/Articles/961150/ https://lwn.net/Articles/961150/ farnz <p>To some extent, the old thing of multiple competing forks of Linux provided the competition; if you have a choice between Torvalds, Cox, Kolivas and other kernels, where the Torvalds fork is the blessed version, and the Cox, Kolivas and other forks make different compromises to Torvalds. And then, the fact that for some workloads, Cox or Kolivas is "better" than Torvalds (but not for others) provides the impetus to work out whether there's a way to do better than all the forks include Torvalds' fork. <p>To a limited degree, we've seen this with EEVDF; there were the latency-nice patches floating around (and efforts made to get latency-nice to fit in with the design of the CFS scheduler), which triggered investigation into alternatives to CFS, and then inspired Zijlstra to implement EEVDF in a way that matched or beat CFS while also providing latency-nice. Wed, 07 Feb 2024 10:54:28 +0000 Upside-down halves https://lwn.net/Articles/961123/ https://lwn.net/Articles/961123/ amarao <div class="FormattedComment"> It's very easy to understand where up and down is. Up is the same as the left-most, or the same as the front. Everyone can look on the byte and day where it begins and where it ends.<br> <p> ... (Missing xkcd about using intuitive 4d navigation abstractions here)<br> </div> Tue, 06 Feb 2024 21:51:10 +0000 Upside-down halves https://lwn.net/Articles/961122/ https://lwn.net/Articles/961122/ intelfx <div class="FormattedComment"> That seems correct, but I was rather making a different point. I learned these words in different contexts, and so it simply doesn't "click" in my brain that top/bottom is "almost like higher/lower". These words are "in different parts of my brain", that's why I never experienced the confusion described in the sibling thread.<br> </div> Tue, 06 Feb 2024 21:41:25 +0000 Upside-down halves https://lwn.net/Articles/961114/ https://lwn.net/Articles/961114/ willy <div class="FormattedComment"> Hm, I thought in Linux the "top half" was the part that submitted work, and the "bottom half" was the deferred interrupt processing. I've been around Linux over 25 years, and I've never seen anyone call the interrupt handler the "top half". I've seen plenty of code call it the "DPC" (Windows terminology, I believe)<br> </div> Tue, 06 Feb 2024 18:10:09 +0000 The end of tasklets https://lwn.net/Articles/961112/ https://lwn.net/Articles/961112/ willy <div class="FormattedComment"> Oh, muffin. It was 4x100Mbit. If you used a more natural 1Gbit card, Linux came out on top.<br> <p> But this is, was and always has been the game. I was part of it when I worked for Intel on Linux in the mid-2000s. Team A would work on Benchmark B and produce a result that beat Linux. So we'd take a look at what bottlenecks Benchmark B had on Linux, eliminate one, rerun the benchmark. Repeat until we beat Team A. Send patches upstream. Team A would typically come back to us a month or two later with an improved result and we'd repeat until either we or Team A lost interest.<br> <p> Competition is healthy, and as long as Benchmark B represents a real customer workload (and you're actually eliminating bottlenecks, not putting in special hacks for Benchmark B), this is a win for everybody. The downside of Linux basically making every other kernel irrelevant is that we've lost that impetus.<br> <p> See also LLVM vs GCC, Firefox vs Chrome, etc, etc.<br> </div> Tue, 06 Feb 2024 18:07:10 +0000 Upside-down halves https://lwn.net/Articles/961113/ https://lwn.net/Articles/961113/ antiphase <div class="FormattedComment"> top is synonymous with highest or uppermost, as in they are superlative-like; similarly (but reversed) for bottom/lowest/lowermost.<br> <p> higher/lower are comparative and don't indicate an absolute position, although you can argue that top and bottom are relative to one another as well.<br> <p> Ah, English.<br> </div> Tue, 06 Feb 2024 18:03:26 +0000 The end of tasklets https://lwn.net/Articles/961089/ https://lwn.net/Articles/961089/ Wol <div class="FormattedComment"> <span class="QuotedText">&gt; Back in 1999, there was a Microsoft sponsored web benchmark from Mindcraft that showed that Windows NT and IIS were faster than Linux and Apache. This was fixed by DavidM by tuning and fixing the networking stack.</span><br> <p> MS had noticed that the linux stack bottle-necked on a single CPU, even on a multi-CPU machine. So they improved their stack to use all four CPUs on some monster machine, and successfully flooded 4 Gigabit network cards.<br> <p> They rapidly learnt not to try that sort of stunt. I can't remember how quick the community responded but, as with any perceived bugs in linux, there were fixes for the bottleneck within a day or so, and a proper solution went live within about a week. MS was left trailing in the dust ...<br> <p> Cheers,<br> Wol<br> </div> Tue, 06 Feb 2024 15:40:15 +0000 Upside-down halves https://lwn.net/Articles/961084/ https://lwn.net/Articles/961084/ intelfx <div class="FormattedComment"> In fact, I believe this is actually the original intention behind this naming. (Also, see my reply to @mathstuf regarding higher/lower level.)<br> </div> Tue, 06 Feb 2024 15:24:38 +0000 Upside-down halves https://lwn.net/Articles/961085/ https://lwn.net/Articles/961085/ intelfx <div class="FormattedComment"> Hm, that's curious. I wonder if this is due to me not being a native speaker — for me, top/bottom and higher/lower (level) are completely disparate pairs of words, with little to no semantic overlap.<br> </div> Tue, 06 Feb 2024 15:24:17 +0000 Upside-down halves https://lwn.net/Articles/961055/ https://lwn.net/Articles/961055/ bertschingert <div class="FormattedComment"> That actually does make sense, and I hadn't thought about it that way before. But my brain landed on and stuck with the "closer to the hardware = lower level" approach. After all, in OS diagrams, the hardware is usually at the bottom of the diagram, not the top.<br> </div> Tue, 06 Feb 2024 14:12:59 +0000 The end of tasklets https://lwn.net/Articles/961053/ https://lwn.net/Articles/961053/ syang <div class="FormattedComment"> I guess we're, uh... deferring their execution from the kernel.<br> </div> Tue, 06 Feb 2024 13:24:02 +0000 Upside-down halves https://lwn.net/Articles/961045/ https://lwn.net/Articles/961045/ mathstuf <div class="FormattedComment"> Another way to think about it is that interrupts are "closer to the hardware" which is "lower level". Once you come back "up" from there, you can do that deferred work.<br> <p> Not saying that this is right, but I've never found mnemonics like these easier to remember than the raw fact itself. For example, the I vs O in the power symbol is actually better remembered as 1 for "on" and 0 for "off" but I kept getting it mixed up with | is an open wire ("off") and a O is a closed circuit ("on").<br> </div> Tue, 06 Feb 2024 10:05:01 +0000 Upside-down halves https://lwn.net/Articles/961038/ https://lwn.net/Articles/961038/ intelfx <div class="FormattedComment"> <span class="QuotedText">&gt; I always thought the Linux usage of top/bottom half was confusing and counterintuitive</span><br> <p> How so, though? If you imagine the work that needs to be done in response to an interrupt as a function written in an imperative language, with control flow from top to down, then the "top half" is the part that is executed first — in the actual interrupt handler — and the bottom half is executed second (using some sort of a deferred execution mechanism).<br> </div> Tue, 06 Feb 2024 08:36:43 +0000 The end of tasklets https://lwn.net/Articles/961035/ https://lwn.net/Articles/961035/ epa <div class="FormattedComment"> So you mean the work keeps getting deferred?<br> </div> Tue, 06 Feb 2024 07:36:46 +0000 The end of tasklets https://lwn.net/Articles/961034/ https://lwn.net/Articles/961034/ alison <div class="FormattedComment"> The threaded sysfs attributes take NET_RX handling mostly away from softirqs. The rcu_nocbs kernel cmdline parameter takes RCU handling out of softirqs. In the last year, as previously noted by LWN, Frederic Weisbecker tried and failed (again) to pull out timer softirqs. If tasklets (and presumably also HI) softirqs could come out, that would leave ksoftirqd truly diminished. Getting rid of softirqs altogether is still a dream, but not as implausible as it once seemed.<br> </div> Tue, 06 Feb 2024 05:38:05 +0000 The end of tasklets https://lwn.net/Articles/961033/ https://lwn.net/Articles/961033/ iabervon <div class="FormattedComment"> It looks like they're not changing how it runs, just how you write the code and how it's tracked in memory. If anything, context switches have gotten more expensive relative to everything else since 1999, but that doesn't mean that the method for avoiding them can't benefit from more recent API design lessons.<br> <p> Also, it's now possible to have other user space tasks that are more important and urgent than your web server performance, so it's worth being technically able to preempt it if necessary even if you normally wouldn't.<br> </div> Tue, 06 Feb 2024 04:59:51 +0000 The end of tasklets https://lwn.net/Articles/961031/ https://lwn.net/Articles/961031/ shemminger <div class="FormattedComment"> The rational for tasklets (and softirq) goes all the way back to the networking overhaul that took place in 2.4 development. Back in 1999, there was a Microsoft sponsored web benchmark from Mindcraft that showed that Windows NT and IIS were faster than Linux and Apache. This was fixed by DavidM by tuning and fixing the networking stack.<br> <p> It was before my involvement in Linux, so don't know the exact details but heard that was the motivation to add softirq so that network SYN packets would get processed without expensive context switch to application.<br> <p> CPU vs network speeds have changed in 25 years, so tradeoffs made then maybe different.<br> </div> Tue, 06 Feb 2024 03:38:01 +0000 The end of tasklets https://lwn.net/Articles/961030/ https://lwn.net/Articles/961030/ chexo4 <div class="FormattedComment"> Wait, so how exactly would that have worked?<br> </div> Tue, 06 Feb 2024 02:33:06 +0000 Upside-down halves https://lwn.net/Articles/961027/ https://lwn.net/Articles/961027/ bertschingert <div class="FormattedComment"> I always thought the Linux usage of top/bottom half was confusing and counterintuitive. It's nice to know I'm maybe not the only one who thought the other way around makes more sense.<br> </div> Tue, 06 Feb 2024 00:14:39 +0000 Upside-down halves https://lwn.net/Articles/961006/ https://lwn.net/Articles/961006/ klossner Linus inverted the bottle. In classic BSD Unix and its successors, the bottom half is the interrupt handler and the top half is the thread to which work is deferred. I have to look up the terms to avoid confusion. See e.g. <a href="http://www.bitsavers.org/pdf/isi/bsd/490147A_4.3_PS2_Programmers_Supplimentary_Documents_Vol2_198707.pdf">UNIX Programmer's Supplementary Documents Volume 2 (PS2) 4.3 Berkeley Software Distribution</a> Mon, 05 Feb 2024 22:04:56 +0000 The end of tasklets https://lwn.net/Articles/961008/ https://lwn.net/Articles/961008/ rgb <div class="FormattedComment"> Why did that idea not get anywhere?<br> </div> Mon, 05 Feb 2024 20:33:23 +0000 The end of tasklets https://lwn.net/Articles/960998/ https://lwn.net/Articles/960998/ willy <div class="FormattedComment"> You missed timers! IIRC one of the proposals for killing tasklets was to make them a timer that expired immediately.<br> </div> Mon, 05 Feb 2024 17:58:35 +0000 The end of tasklets https://lwn.net/Articles/960997/ https://lwn.net/Articles/960997/ kees <div class="FormattedComment"> Actually way earlier than that...<br> <a href="https://lwn.net/Articles/239633/">https://lwn.net/Articles/239633/</a><br> </div> Mon, 05 Feb 2024 17:56:42 +0000 The end of tasklets https://lwn.net/Articles/960973/ https://lwn.net/Articles/960973/ kees <div class="FormattedComment"> We've been trying to get rid of tasklets for more than 5 years...<br> <a href="https://github.com/KSPP/linux/issues/94">https://github.com/KSPP/linux/issues/94</a><br> I hope it gets completed this time! :)<br> </div> Mon, 05 Feb 2024 15:43:29 +0000