Most Costly Steps in a Kernel Context Switch

The highest direct costs of a kernel context switch involve saving and restoring CPU registers and memory maps. Indirectly, Translation Lookaside Buffer (TLB) flushes, which can cause hundreds of CPU cycles of waste per miss, and cache pollution contribute significantly to the performance drain.

Sources

Open the full topic