diff options
author | Sai Charan Gurrappadi <sgurrappadi@nvidia.com> | 2012-08-24 18:42:36 -0700 |
---|---|---|
committer | Rohan Somvanshi <rsomvanshi@nvidia.com> | 2012-09-14 05:07:01 -0700 |
commit | 8bd999a85354485af3cbee872816a9921d8bfffc (patch) | |
tree | e95466ab7c12da34ff07a49de4bc329ac4e14516 /fs | |
parent | ac5deab16d75d962ed78cc427266ad87f8672fbb (diff) |
cpuquiet: Update averaging of nr_runnables
Doing a Exponential moving average per nr_running++/-- does not
guarantee a fixed sample rate which induces errors if there are lots of
threads being enqueued/dequeued from the rq (Linpack mt). Instead of
keeping track of the avg, the scheduler now keeps track of the integral
of nr_running and allows the readers to perform filtering on top.
Implemented a proper exponential moving average for the runnables
governor and a straight 100ms average for the balanced governor. Tweaked
the thresholds for the runnables governor to minimize latency. Also,
decreased sample_rate for the runnables governor to the absolute minimum
of 10msecs.
Updated to K3.4
Change-Id: Ia25bf8baf2a1a015ba188b2c06e551e89b16c5f8
Signed-off-by: Sai Charan Gurrappadi <sgurrappadi@nvidia.com>
Signed-off-by: Peter De Schrijver <pdeschrijver@nvidia.com>
Reviewed-on: http://git-master/r/131147
Reviewed-by: Juha Tukkinen <jtukkinen@nvidia.com>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/proc/loadavg.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/fs/proc/loadavg.c b/fs/proc/loadavg.c index 8d95888b22cd..1afa4dd4cae2 100644 --- a/fs/proc/loadavg.c +++ b/fs/proc/loadavg.c @@ -13,17 +13,15 @@ static int loadavg_proc_show(struct seq_file *m, void *v) { unsigned long avnrun[3]; - unsigned long time_avnrun = avg_nr_running(); get_avenrun(avnrun, FIXED_1/200, 0); - seq_printf(m, "%lu.%02lu %lu.%02lu %lu.%02lu %ld/%d %d %lu.%02lu\n", + seq_printf(m, "%lu.%02lu %lu.%02lu %lu.%02lu %ld/%d %d\n", LOAD_INT(avnrun[0]), LOAD_FRAC(avnrun[0]), LOAD_INT(avnrun[1]), LOAD_FRAC(avnrun[1]), LOAD_INT(avnrun[2]), LOAD_FRAC(avnrun[2]), nr_running(), nr_threads, - task_active_pid_ns(current)->last_pid, - LOAD_INT(time_avnrun), LOAD_FRAC(time_avnrun)); + task_active_pid_ns(current)->last_pid); return 0; } |