Re: An attempt at optimising the poll code

From: Henrik Nordstrom <hno@dont-contact.us>
Date: Fri, 04 Aug 2000 20:29:24 +0200

Henrik Nordstrom wrote:
>
> I think evenly dividing the filedescriptor sets won't do you much good.

I'll widthdraw that statement. Multiplexing the filedescriptors will
give you some gains in memory usage by keeping the data flowing more
evenly.

However, one tricky issue is to select a proper timeout for the poll()
operation. We do want to sleep on poll() to leave CPU for other
operations, but at the same time you do not want to sleep to long since
you don't know if there is data ready in any of the other
filedescriptors.

Tricky thing this.. but I am more and more convinced that a priority
based algorithm is the way to go. The higher the priority, the shorter
the timeout. And lower priorities should include the higher priority
filedescriptors in their polls.

--
Henrik Nordstrom
Squid hacker
Received on Fri Aug 04 2000 - 12:29:36 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:12:34 MST