The Linux Kernel Preparing To Remove The Last Of Its MMX Optimized Code

For what will likely be merged to the Linux 7.5 kernel, the mainline kernel is preparing to drop its last optimization its been carrying for far outdated MMX processors. This affects the likes of Intel Pentium MMX and Pentium II processors running modern software with up-to-date kernels when Linux 7.5 is released in 2027. The Intel engineered MMX instruction set from the late 1990s found since the Intel Pentium MMX series or AMD K6 is seeing the last of its optimized Linux kernel code being removed. Eric Biggers of Google has a patch ready to remove the obsolete MMX optimized code from the kernel's software RAID xor code. Anyone still using the likes of a Pentium MMX or Pentium II that can't benefit from newer ISA capabilities (SSE or better) and using Linux software RAID will be falling back to the scalar code path. This MMX-optimized RAID code was the last of the Linux kernel code carrying MMX-specific optimizations after some MMX-optimized memory management code was removed back in 2021. The patch in Andrew Morton's "MM" Git tree explains: "This series retires 32-bit MMX optimizations for RAID. Affected CPUs, such as the Pentium MMX and Pentium II, will just fall back to the existing well-tested scalar code instead. This was the only remaining MMX optimized code in the kernel. MMX optimizations for the much more commonly called functions memcpy(), copy_page(), and clear_page() were already removed years ago by commit c6dbd3e5e69c ("x86/mmx_32: Remove X86_USE_3DNOW"). There are zero MMX optimizations for anything else, like crypto or CRC, which left the RAID code as an outlier. Patch 3 also cleans up the CPU feature checks in the RAID6 code. This patch (of 3): The MMX optimized XOR code is used only on 25-year old 32-bit CPUs that lack SSE support -- and only on systems that actually have a RAID array. Those CPUs already have well-tested scalar C fallbacks." With it in the MM branch, look for this last MMX optimization to likely be removed with Linux 7.5.

Original Source

Read the full article at Phoronix →

KhanList aggregates and links to publicly available news content. We do not host full articles from third-party sources. Always verify important information with original sources.