Re: [tip:sched/core] sched: Track the runnable average on a per-task entity basis

From: Benjamin Segall
Date: Thu Oct 25 2012 - 12:58:20 EST


li guang <lig.fnst@xxxxxxxxxxxxxx> writes:

> å 2012-10-24äç 02:43 -0700ïtip-bot for Paul Turneråéï
>> + do {
>> + if (runnable)
>> + sa->runnable_avg_sum += delta_w;
>> + sa->runnable_avg_period += delta_w;
>> +
>> + /*
>> + * Remainder of delta initiates a new period, roll over
>> + * the previous.
>> + */
>> + sa->runnable_avg_sum =
>> + decay_load(sa->runnable_avg_sum, 1);
>
> Is this u0+u1*y+u2*y^2+u3*y^3 ...,
> seems no, this is u0+u1*y+u2*y+u3*y+u4*y ...
>
It is cumulative, so it is u0+y*(u1+y*(u2+..., which is u0+u1*y+u2*y^2+...
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/