Re: kqueue microbenchmark results

From: Jonathan Lemon (jlemon@flugsvamp.com)
Date: Wed Oct 25 2000 - 01:02:46 EST


On Tue, Oct 24, 2000 at 09:45:14PM -0700, Dan Kegel wrote:
> If you haven't already, you might peek at the discussion on
> linux-kernel. Linus seems to be on the verge of adding
> something like kqueue() to Linux, but appears opposed to
> supporting level-triggering; he likes the simplicity of
> edge triggering (from the kernel's point of view!). See
> http://boudicca.tux.org/hypermail/linux-kernel/2000week44/index.html#9

Yes, someone pointed me to those today. I would suggest reading
some of the relevant literature before embarking on a design. My
paper discusses some of the issues, and Mogul/Banga make some good
points too.

While an 'edge-trigger' design is indeed simpler, I feel that it
ends up making the job of the application harder. A simple example
to illustrate the point: what if the application does not choose
to read all the data from an incoming packet? The app now has to
implement its own state mechanism to remember that there may be pending
data in the buffer, since it will not get another event notification
unless another packet arrives.

kqueue() provides the ability for the user to choose which model suits
their needs better, in keeping with the unix philosophy of tools, not
policies.

--
Jonathan
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Tue Oct 31 2000 - 21:00:15 EST