From owner-freebsd-net Wed Mar 14 8:22:45 2001 Delivered-To: freebsd-net@freebsd.org Received: from info.iet.unipi.it (info.iet.unipi.it [131.114.9.184]) by hub.freebsd.org (Postfix) with ESMTP id C968A37B71D for ; Wed, 14 Mar 2001 08:22:39 -0800 (PST) (envelope-from luigi@info.iet.unipi.it) Received: (from luigi@localhost) by info.iet.unipi.it (8.9.3/8.9.3) id RAA19510; Wed, 14 Mar 2001 17:22:52 +0100 (CET) (envelope-from luigi) From: Luigi Rizzo Message-Id: <200103141622.RAA19510@info.iet.unipi.it> Subject: Re: Changing UDP select() behavior In-Reply-To: <3AAF970B.7A19438A@isi.edu> from Lars Eggert at "Mar 14, 2001 08:06:35 am" To: Lars Eggert Date: Wed, 14 Mar 2001 17:22:52 +0100 (CET) Cc: net@FreeBSD.ORG X-Mailer: ELM [version 2.4ME+ PL61 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org > As for efficiency, I agree that the per-packet send overhead will be > larger. I'm not sure it'll be large enough to become a problem, though. yes it is probably constant work to find the first sleeping socket on the queue and issue a wakeup. > > All in all I think this approach would only help a bit if > > if you were allowed to queue in the socket buffer > > (on which you can think of having some control, because you either > > opened the fd yourself or you inherited it from some parent), > > in addition to the device queue. > > Could you explain this a little more? I think I know where you're going > with this, but I'm not sure :-) i think i meant you want to buffer your overflowing packets in the socket buffer, and use them as an extension of the ipq. Basically once the interface queue is full, you create a list of socket buffers waiting for a transmit, then when a slot in the ifqueue becomes empty you fill it up with the next pkt from next the socket buffer without having to wakeup the process associated with it unless you pass the lowwater mark. But again, it is quite a bit of work to put all this code together, and you end up with something that other systems do not have so when you want to write portable code you still have to handle the old behaviour as well in userland. cheers luigi To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message