Zack's Kernel News
Zack's Kernel News

Chronicler Zack Brown reports on kernel efficiency improvements and tracking compiler plugin problems.
Kernel Efficiency Improvements
Sometimes the Linux folks will struggle to eke out a few microseconds of speed-up in some part of the kernel or other. These efficiency improvements may not seem to matter to the average user, but they do add up. They can mean the difference between hours and days to larger organizations constantly doing massive computations. At the same time, the question of where a given improvement should be made – in the kernel itself, in the C compiler, or elsewhere in the toolchain – may also mean the difference between a tight clean solution and a complex and easily breakable one.
Recently, Mateusz Guzik noticed that "The kernel is chock full of inlined rep movsq and rep stosq, including in hot paths and these are known to be detrimental to performance below certain sizes." He added, "When issuing hello-world compiles in a loop this is over 1% of total CPU time as reported by perf. With the kernel recompiled to instead do a copy with regular stores this drops to 0.13%." Mateusz also added that these were only his personal results, and he'd be interested to see if similar slowdowns were seen on other CPUs.
He posted a tentative patch to fix the issue, but said he wanted to hear from other people before making it a real submission. However, Linus Torvalds replied, "Please make this a gcc bug-report instead – I really don't want to have random compiler-specific tuning options in the kernel. Because that whole memcpy-strategy thing is something that gets tuned by a lot of other compiler options (ie -march and different versions)."
[...]
Buy this article as PDF
(incl. VAT)
Buy Linux Magazine
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Support Our Work
Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.

News
-
Go-Based Botnet Attacking IoT Devices
Using an SSH credential brute-force attack, the Go-based PumaBot is exploiting IoT devices everywhere.
-
Plasma 6.5 Promises Better Memory Optimization
With the stable Plasma 6.4 on the horizon, KDE has a few new tricks up its sleeve for Plasma 6.5.
-
KaOS 2025.05 Officially Qt5 Free
If you're a fan of independent Linux distributions, the team behind KaOS is proud to announce the latest iteration that includes kernel 6.14 and KDE's Plasma 6.3.5.
-
Linux Kernel 6.15 Now Available
The latest Linux kernel is now available with several new features/improvements and the usual bug fixes.
-
Microsoft Makes Surprising WSL Announcement
In a move that might surprise some users, Microsoft has made Windows Subsystem for Linux open source.
-
Red Hat Releases RHEL 10 Early
Red Hat quietly rolled out the official release of RHEL 10.0 a bit early.
-
openSUSE Joins End of 10
openSUSE has decided to not only join the End of 10 movement but it also will no longer support the Deepin Desktop Environment.
-
New Version of Flatpak Released
Flatpak 1.16.1 is now available as the latest, stable version with various improvements.
-
IBM Announces Powerhouse Linux Server
IBM has unleashed a seriously powerful Linux server with the LinuxONE Emperor 5.
-
Plasma Ends LTS Releases
The KDE Plasma development team is doing away with the LTS releases for a good reason.