Linux 7.0 introduces a decade-in-the-making time slice extension feature, along with significant performance and scalability improvements for modern high-core systems.
The Linux 7.0 kernel has landed with some of the most significant scheduler improvements in recent years, headlined by a time slice extension feature that developers have been working on for nearly a decade. Linus Torvalds merged these scheduler changes today, bringing new capabilities and optimizations that address the needs of modern high-core-count systems.

Time Slice Extension Finally Ships
The most notable addition is the time slice extension support implemented via Restartable Sequences (RSEQ). This feature has been in development for approximately ten years, with multiple attempts at implementation before reaching its current form.
The merged code allows user-space processes to request temporary, opportunistic extensions of their CPU time slice without being preempted. This addresses a specific scenario where a thread enters a critical section and needs to avoid contention on a resource when rescheduled outside that critical section.
This capability is particularly valuable for workloads that require brief periods of uninterrupted execution to maintain data consistency or avoid expensive lock contention. By allowing threads to extend their time slice when entering critical sections, the scheduler can help reduce the overhead associated with frequent context switches and lock acquisition failures.
Preemption Mode Consolidation
Linux 7.0 also brings a significant change to preemption modes across multiple architectures. The kernel now limits affected architectures to either full or lazy preemption modes, eliminating the none and voluntary options.
The architectures impacted by this change include x86/x86_64, s390, RISC-V, POWER, LoongArch, and ARM64. This consolidation simplifies the preemption model and potentially reduces complexity in the scheduler's decision-making process.
Full preemption provides the lowest latency for real-time workloads by allowing interrupts to preempt nearly any code path, while lazy preemption offers a balance between responsiveness and overhead by deferring some preemption decisions. By removing the other options, the kernel can optimize these remaining modes more effectively.
Performance and Scalability Improvements
Beyond the headline features, Linux 7.0 includes numerous scheduler performance and scalability improvements designed to handle today's increasingly high core count systems.
These improvements focus on several key areas:
- Enhanced scalability across various workloads, ensuring the scheduler can efficiently distribute work across dozens or even hundreds of cores
- Speed-ups to the fair scheduler's SMP NOHZ (Non-Uniform Memory Access, tickless idle) balancing code
- Various other optimizations that improve overall scheduler efficiency
The NOHZ balancing improvements are particularly noteworthy, as they help the scheduler make better decisions about which CPU cores should handle idle tasks, reducing cross-node memory access and improving cache locality.
What This Means for Users
These scheduler changes in Linux 7.0 represent a significant step forward for system performance, particularly for workloads that are sensitive to scheduling decisions. The time slice extension feature could benefit database operations, high-frequency trading systems, and other applications where maintaining execution context across critical sections is valuable.
The consolidation of preemption modes should lead to more predictable scheduling behavior across supported architectures, while the general performance improvements will benefit all users running the kernel on modern multi-core systems.
As Michael Larabel notes, once the merge window settles, comprehensive Linux 7.0 kernel performance benchmarking will begin, with particular attention paid to identifying any regressions that might have been introduced by these substantial changes.
For system administrators and developers working with high-performance computing environments, these scheduler improvements offer tangible benefits that could translate to better application performance and more efficient resource utilization.
The decade-long journey to implement time slice extension demonstrates the kernel development community's commitment to solving complex scheduling challenges, even when solutions require years of refinement and iteration.

Comments
Please log in or register to join the discussion