Re: A different metric for scheduler optimisation

From: Jamie Lokier (lkd@tantalophile.demon.co.uk)
Date: Sun Jan 30 2000 - 11:33:51 EST


Davide Libenzi wrote:
> Anyway consider the faster switching app that I know ( this can be an FTP
> server for example ):
>
> char buffer[N];
> for(;;)
> {
> read(infd, buffer, N);
> write(outfd, buffer, N);
> }
>
> for N = 1 this app "can switch very fast" and touch very few bytes, and this
> seems to confirm my hypothesise.

Well, well... this one only switches when it blocks waiting for data or
waiting for the output queue to flush.

And when it does that, it _isn't_ on the run queue!

In other words, run several of these in parallel and you will still get
a very low run queue length.

The cache thing is simply an argument for using mmap/write instead...

enjoy,
-- Jamie

-
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/



This archive was generated by hypermail 2b29 : Mon Jan 31 2000 - 21:00:25 EST