Right, but if you're CPU-bound, then it doesn't matter how long the time-slice
is. It doesn't matter if your time-slices are 1Hz or 1kHz, except that you
waste less time in switching with a 1Hz rate. If you arn't really CPU-bound -
you're interacting with the outside world with syscalls - then the timeslice
isn't the issue, its the rate you call syscalls. And of course, you run long
timeslice processes with a low priority, so an interactive processes will
always get CPU immediately if it needs to.
In general, long timeslices are better than short ones, simply because there's
less overhead. Latency isn't an issue, because that depends on how you use
syscalls. A number of schedulers will adjust timeslice quanta depending on the
nature of the load - long slices (multiple seconds) for CPU bound, and shorter
for IO-bound or interactive tasks.
>> > Why is that a problem? Here is an example:
>> > You earn 1000$ a month. Your boss decides to pay you not monthly but
>> > weekly,
>> > and you begin to complain that you earn only 250$.
>>
>> Not accurate.
>
> I think so.
Not quite. Its the same as being paied $1000/month or $250/wk, but it always
costs $10 to deposit your payment.
J
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/