Curious where this (rather large, yet still seemingly arbitrary) limit comes from.
Curious where this (rather large, yet still seemingly arbitrary) limit comes from.
It is Good Enough for now, while keeping various pre-allocated, statically created structures with-in reasonable size limits:
> Global and allocated arrays sized by MAXCPU result in excessive bloat on systems with lower core counts. In addition, some code used u_char (8 bits) to hold a CPU index, which is not valid if MAXCPU is greater than 256.
> A number of recent commits addressed these sorts of issues, including at least: […]
* https://cgit.freebsd.org/src/commit/?id=9051987e40c5
See:
> The SMP system now supports up to 1024 cores on amd64 and arm64. Many kernel CPU sets are now dynamically allocated to avoid consuming excessive memory. The kernel cpuset ABI has been updated to support the higher limit. 76887e84be97[1] d1639e43c589[2] 9051987e40c5[3] e0c6e8910898[4] (Sponsored by The FreeBSD Foundation)
* https://www.freebsd.org/releases/14.0R/relnotes/#kernel-gene...
[1] https://ark.intel.com/content/www/us/en/ark/products/231747/...
[2] https://www.supermicro.com/en/products/system/mp/6u/sys-681e...
That supermicro system is 8-way; it's 4 dual-socket motherboards but they're one system, hooked together by backplane boards. You can price supermicro's complete-system-only stuff (all of it now, alas) out on thinkmate or similar sites, but a minimal config (and you'd never buy that for a minimal config) hits around $60k.
The relevant parts of the ABI have been future proofed to allow raising the kernel CPU core count limit without breaking the syscall interface for systems with less cores than the existing limit.