]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
From: Stewart Forster <slf@connect.com.au>
authorwessels <>
Wed, 31 Dec 1997 12:01:46 +0000 (12:01 +0000)
committerwessels <>
Wed, 31 Dec 1997 12:01:46 +0000 (12:01 +0000)
In comm.c, for VERY low load if you're using async I/O it will go
VERY slow because it will only timeout of the poll every second if
there's no traffic to squid.  The fix is to reduce the timeout.
This will now poll for asyncio 20 times a second, rather than once.
This will give a certain 40K/sec transfer rate on a Solaris box.

src/comm.cc

index bf07cd2fb9c1e115e1962206701a3230886c3883..cb7dddc81b3c917d601864d2922b54b134fe8d35 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: comm.cc,v 1.214 1997/12/30 02:47:40 wessels Exp $
+ * $Id: comm.cc,v 1.215 1997/12/31 05:01:46 wessels Exp $
  *
  * DEBUG: section 5     Socket Functions
  * AUTHOR: Harvest Derived
@@ -882,7 +882,7 @@ comm_poll(time_t sec)
            debug(5, 2) ("comm_poll: Still waiting on %d FDs\n", nfds);
        if (nfds == 0)
            return COMM_SHUTDOWN;
-       poll_time = sec > 0 ? 1000 : 0;
+       poll_time = sec > 0 ? 50 : 0;
 #if USE_ASYNC_IO
        aioCheckCallbacks();
 #endif