Hrtimer_init(&cfs_b->slack_timer, CLOCK_MONOTONIC, HRTIMER_MODE_REL) Ĭfs_b->slack_timer.function = sched_cfs_slack_timer Raw_spin_unlock_irqrestore(&cfs_b->lock, -4920,6 +4926,7 void init_cfs_bandwidth(struct cfs_bandwidth *cfs_b) Raw_spin_lock_irqsave(&cfs_b->lock, flags) * confirm we're still not at a refresh boundary */ + cfs_b->slack_started = -4782,6 +4787,7 static void do_sched_cfs_slack_timer(struct cfs_bandwidth *cfs_b) + /* don't push forwards an existing deferred unthrottle */ If (runtime_refresh_within(cfs_b, min_left)) +++ -4729,6 +4729,11 static void start_cfs_slack_bandwidth(struct cfs_bandwidth *cfs_b) Switch this around.Ĭhange-Id: Ife536bb54af633863de486ba6ec0d20e55ada8c9ĭiff -git a/kernel/sched/fair.c b/kernel/sched/fair.c Without any sleeps, instead of waiting for 5ms from the first sleep, which canĭelay the unthrottle more than we want. To be done outside of the rq lock we hold. Throttled cfs_rqs to coalesce with other cfs_rqs going to sleep, as this has has When a cfs_rq sleeps and returns its quota, we delay for 5ms before waking any Subject: sched/fair: don't push cfs_bandwith slack timers forward More than the cost of extra locking to acquire runtime. Min_cfs_rq_runtime (currently not runtime tunable) if you see that cost You might try this patch instead, possibly along with lowering Unthrottle part of this where it could be continuously pushed into theįuture. I'm setting up to try your test now, but there was a bug with the So most of the bandwidth is supposed to be returned, leaving only 1ms. > results in applications not being able to utilize the quota for which > slices, and then not fully using that slice within the period. > This has been root caused to threads being allocated per cpu bandwidth > bound applications, such as those running in kubernetes or mesos when This use case is typical of user-interactive non-cpu > periods throttled while simultaneously not consuming the allocated > running under cpu.cfs_quota_us constraints can hit a high percentage of > It has been observed, that highly-threaded, non-cpu-bound applications Jonathan Corbet Re: sched/fair: Fix low cpu usage with high throttling by removing expiration of cpu-local slicesĭate: Wed, 12:50:22 -0700 Re: sched/fair: Fix low cpu usage with high throttling by removing expiration of cpu-local slices - bsegall archive mirror help / color / mirror / Atom feed From: Dave Chiluk
0 Comments
Leave a Reply. |