Towards High-Performance eBPF-based OS Scheduling for Serverless Functions
Abstract
The Linux default scheduler's fairness-oriented design frequently preempts short-running serverless functions, degrading Function-as-a-Service (FaaS) performance and increasing user costs. Existing solutions to remedy this problem propose custom OS scheduling policies based on custom kernels, external frameworks, or user-space polling. To address these limitations, we explore sched_ext, a recent Linux kernel feature providing an extensible scheduler framework via the Extended Berkeley Packet Filter (eBPF). We evaluate 11 prebuilt sched_ext schedulers under production-like FaaS workloads and show that 9 out of 11 policies outperform the default Linux scheduler (EEVDF) in both performance and user costs, reducing turnaround time by up to 61.1% and user costs by up to 51.3%. In this work, we demonstrate the significant impact of OS scheduling on FaaS environments and identify successful mechanisms to guide the design of future specialized schedulers.