News: 0001506952

  ARM Give a man a fire and he's warm for a day, but set fire to him and he's warm for the rest of his life (Terry Pratchett, Jingo)

Lazy Preemption Merged Along With Other Scheduler Improvements For Linux 6.13

([Linux Kernel] 3 Hours Ago Lazy Preemption)


All of the scheduler feature changes were merged today for the Linux 6.13 kernel, including the introduction of the lazy preemption model.

As noted a few weeks back [1]lazy preemption "PREEMPT_LAZY" was tracking for introduction in the Linux 6.13 cycle. Lazy preemption is described in the scheduler pull request as:

Add the "Lazy preemption" model (CONFIG_PREEMPT_LAZY=y), which optimizes fair-class preemption by delaying preemption requests to the tick boundary, while working as full preemption for RR/FIFO/DEADLINE classes.

Or the Kconfig description for CONFIG_PREEMPT_LAZY that sums it up a bit more elegantly:

This option provides a scheduler driven preemption model that is fundamentally similar to full preemption, but is less eager to preempt SCHED_NORMAL tasks in an attempt to reduce lock holder preemption and recover some of the performance gains seen from using Voluntary preemption.

This lazy preemption option is currently working on x86_64 and RISC-V systems.

The Linux 6.13 scheduler code also now ensures idle tasks are only initialized once, a fair scheduler optimization, optimizing the generic idle loop by dropping an unnecessary memory barrier, [2]improving cache locality for Restartable Sequences (RSEQ), and [3]prep changes for Proxy Execution .

The lazy preemption code plus other scheduler changes make for a pretty exciting pull for Linux 6.13. The full list of scheduler patches for those interested via the [4]Linux kernel mailing list .



[1] https://www.phoronix.com/news/Linux-6.13-Lazy-Preemption

[2] https://www.phoronix.com/news/RSEQ-Cache-Local-Speedup

[3] https://www.phoronix.com/news/Linux-6.13-Prep-For-Proxy-Exec

[4] https://lore.kernel.org/lkml/Zzt_or2E2KEypfbi@gmail.com/



mrg666

skeevy420

Mitch

mrg666

sophisticles

By the middle 1880's, practically all the roads except those in
the South, were of the present standard gauge. The southern roads were
still five feet between rails.
It was decided to change the gauge of all southern roads to standard,
in one day. This remarkable piece of work was carried out on a Sunday in May
of 1886. For weeks beforehand, shops had been busy pressing wheels in on the
axles to the new and narrower gauge, to have a supply of rolling stock which
could run on the new track as soon as it was ready. Finally, on the day set,
great numbers of gangs of track layers went to work at dawn. Everywhere one
rail was loosened, moved in three and one-half inches, and spiked down in its
new position. By dark, trains from anywhere in the United States could operate
over the tracks in the South, and a free interchange of freight cars everywhere
was possible.
-- Robert Henry, "Trains", 1957