Introducing architecture variants
What x86‑64‑v3 Brings and Why
- x86‑64‑v3 essentially targets AVX2‑class CPUs, plus a bundle of other extensions, though notably not AES‑NI/CLMUL despite those being common on such hardware.
- Motivation is to ship prebuilt binaries that can exploit modern instructions without dropping support for older CPUs, similar to emerging patterns on ARM and RISC‑V.
Performance Gains and Their Distribution
- Ubuntu’s own rebuild shows ~1% average speedup for “most packages,” with some numerically heavy workloads gaining significantly more (claims up to 1.5–2× in edge cases).
- Several commenters stress that aggregated numbers hide skew: a small number of hot libraries or apps may get large wins while the median app sees effectively nothing.
When 1% Matters (and When It Doesn’t)
- Strong view: hyperscalers or anyone running large fleets will gladly take 1%, as it can translate into fewer servers and substantial cost/energy savings.
- Counter‑view: for typical desktop users, CPU is rarely the bottleneck, so 1% is effectively unobservable.
- Others emphasize compounding small optimizations over years and across millions of devices.
Relation to Existing Optimization Techniques
- Many performance‑critical libraries (BLAS/LAPACK, crypto, compression, codecs, llama.cpp) already use runtime CPU feature detection, multiversioning, or fat binaries; for them, distro‑level v3 gives smaller marginal gains, or mainly reduces dispatch overhead.
- Some argue that widespread v3 builds will incentivize compiler and app authors to better use newer instructions.
- Gentoo/source‑compilation nostalgia appears: micro‑arch tuning gives modest gains now; the big wins often come from algorithmic choices, threading, or better BLAS/MKL/OpenCV builds.
Tooling, ABI, and Compatibility Questions
- Discussion about how dpkg/apt implement “architecture variants” and relation to Debian’s ArchitectureVariants design; clear point that different ABIs (e.g., armel vs armhf) are out of scope.
- Concern about moving a v3‑optimized disk to an older CPU: currently it just fails with illegal instructions; Ubuntu plans a cleaner recovery path.
- glibc hwcaps are seen as too limited (shared libs only) and space‑wasteful compared to full variant repos.
Concerns, Skepticism, and Edge Issues
- Worries about extra complexity, more heisenbugs, and non‑deterministic numeric behavior across variants.
- Some think using micro‑arch variants system‑wide is overkill; targeted variant packages or meta‑packages might be simpler.
- Others welcome Ubuntu joining Fedora/RHEL/Arch‑style optimization and see this as a partial replacement for things like Intel’s Clear Linux.