--MimeMultipartBoundary
Content-Type: text/plain; charset=us-ascii
> How did you measure it?? On linux 2.0.33, average times for system
> calls run as..
>
> recvfrom 0.000049
> read 0.000090
> select 0.001902
>
> as measured by profiling a running busy squid.
Righto. I was using poll() which was about 30% faster against doing
a read. I didn't check recvfrom since this test was good enough for me.
read 0.0000094
poll 0.0000059
I did this by doing read / polls to a TCP network socket opened
for listening (ie. like squid does) and set for non_blocking I/O. I ran
it through a loop 1M times and timed it. That just measures raw overhead
of each call. I was polling a single socket which is similar to what
we'll be targeting.
Wow! Solaris is quite a bit faster (300x) than Linux for those polls, and
even 10 times faster for reads.
Tell you what I'll do. I'll work in a #ifdef to allow bypassing
of the poll/select call and go straight to the event handler bit, that way
if your OS is faster for doing that, then cool.
Stew.
-- Stewart Forster (Snr. Development Engineer) connect.com.au pty ltd, Level 9, 114 Albert Rd, Sth Melbourne, VIC 3205, Aust. Email: slf@connect.com.au Phone: +61 3 9251-3684 Fax: +61 3 9251-3666 --MimeMultipartBoundary--Received on Tue Jul 29 2003 - 13:15:50 MDT
This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:11:48 MST