Re: Why do the CFS chase fairness?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi .....

I am reaching my virtual limit here, so beg me pardon :)

On Mon, Sep 19, 2011 at 23:26, Parmenides
> Hmm..., does that mean timeslice weighting introduce unfainess? If we
> think fairness relies on each task not fetching more timeslice than
> other tasks, the eaiest way to achieve fairness is to give every task
> the same timeslice.

At the extreme theoritical side, yes, ....but again that is if all are
CPU bound.... the complication comes since in reality most processes
are mixture of CPU and I/O bound...or sometimes I/O bound only.

> Can I understand like this: each task advance its progress tinier than
> traditional timeslice, which makes C has more chances to be selected
> to preempt A or B owing to its higher priority? Higer priority makes
> C's virtual time smaller than A and B.
>

in non preemptive kernel i.e cooperative scheduling, your above
suggested idea is the right way to achieve fairness in such situation.
However, since user space (and now kernel space too) implements
preemptive, adjusting time slice is not really necessary to make C
kicks back into run queue.

What the scheduler needs perhaps at this point is good priority
recalculation is C could run ASAP. If not, even though C is in run
queue, it still can beat the other processes in the competition of CPU
time.


-- 
regards,

Mulyadi Santosa
Freelance Linux trainer and consultant

blog: the-hydra.blogspot.com
training: mulyaditraining.blogspot.com

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@xxxxxxxxxxxxxxxxx
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux