Skip to content
Tagged articles

cpu.shares

4 articles · Page 1 of 1
OPPO Kernel Craftsman
OPPO Kernel Craftsman
May 23, 2025 · Fundamentals

Why Android Threads Stall: Inside Linux CFS, RT, Fair Scheduling and cgroup Limits

This article explains why many Android threads appear idle despite free CPU cycles, by dissecting Linux's five scheduler classes, the distinction between RT and fair scheduling, the role of virtual runtime and weight, and how cgroup cpu.shares can reshape resource distribution, supported by concrete systrace experiments.

Android performanceCFSLinux scheduler
0 likes · 17 min read
Why Android Threads Stall: Inside Linux CFS, RT, Fair Scheduling and cgroup Limits
Liangxu Linux
Liangxu Linux
Jul 16, 2024 · Cloud Native

Master Docker CPU Limits: --cpus, --cpuset-cpus, and --cpu-shares Explained

This guide demonstrates how to restrict Docker container CPU usage using the modern --cpus flag, the legacy --cpu-period/--cpu-quota pair, fixed CPU assignment with --cpuset-cpus, and CPU weighting via --cpu-shares, complete with commands, observations, and practical examples.

containercpu-limitscpu.shares
0 likes · 9 min read
Master Docker CPU Limits: --cpus, --cpuset-cpus, and --cpu-shares Explained
OPPO Kernel Craftsman
OPPO Kernel Craftsman
Jan 6, 2023 · Fundamentals

CFS Group Scheduling: Purpose, Configuration, and Kernel Implementation Details

The article explains why Linux’s Completely Fair Scheduler introduced group scheduling, how Android configures task groups via cpu.shares and Process.java, and details the kernel structures (task_group, sched_entity, cfs_rq) and algorithms for weight calculation, load measurement, propagation, and hierarchical load balancing.

CFS schedulingLinux kernelLoad Balancing
0 likes · 28 min read
CFS Group Scheduling: Purpose, Configuration, and Kernel Implementation Details