Ampere Preparing The ARM64 Linux Kernel To Support Higher CPU Core Counts

Written by Michael Larabel in Arm on 29 November 2023 at 04:00 AM EST. 4 Comments
ARM
Ampere Computing has sent out its latest patch attempt at increasing the number of Arm CPU cores supported by the mainline Linux kernel. As it stands at the moment the 64-bit ARM mainline Linux kernel build supports 256 cores, which can be exceeded with Ampere's new AmpereOne processors in a multi-socket configuration.

Ampere Computing is facing the problem of their customers not being able to use Linux distribution supplied kernels because the number of processors isn't supported. The ARM64 Linux kernel has a 256 core limit while with AmpereOne CPUs allowing up to 192 physical cores per socket, that 256 limit is passed in a dual socket configuration.

With the proposed patches, when CPUMASK_OFFSTACK is enabled, the limit is to be raised to 8,192 or otherwise 512 CPU cores. Keeping a low limit is being done simply to save memory: each supported CPU core adds around 8KB to the kernel image size. The CPUMASK_OFFSTACK kernel option allows for the kernel to allocate and free bitmaps for CPU masks from slab memory rather than keeping it on the stack, in order to allow dynamically sizing the allocation based on the number of CPU cores present at boot.

AmpereOne slide


AmpereOne hardware currently appears in short supply and still no word on any review hardware at Phoronix, but this change for the mainline Linux kernel is certainly warranted and arguably should have already happen for the mainline kernel to better prepare for forthcoming high-end Arm servers. Back in 2021 was a patch to change the ARM64 kernel CPU core limit to 512, but at the time that was shot down by ARM Linux maintainers as being a default change for unreleased hardware. In turn this latest patchwork won't be mainlined until at least Linux 6.8 in early 2024 which is now arguably rather later for ARM Linux server distributions -- especially for the time it takes to work such a kernel into the major Linux distributions -- that want to cater to AmpereOne servers while trying to stick to normally coherent mainline kernel defaults. It was six months ago now that AmpereComputing announced AmpereOne with up to 192 cores.

With the existing mainline kernel, the Linux x86_64 build supports up to 8,192 cores with CPUMASK_OFFSTACK or 512 cores otherwise.
Related News
About The Author
Michael Larabel

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter, LinkedIn, or contacted via MichaelLarabel.com.

Popular News This Week