[Xorp-cvs] XORP cvs commit: xorp/libxorp
Andrea Bittau
abittau at icir.org
Tue Sep 23 12:55:48 PDT 2008
CVSROOT: /usr/local/www/data/cvs
Module name: xorp
Changes by: abittau at chum.icir.org 2008-09-23 19:55:48 UTC
XORP CVS repository
Modified files:
libxorp eventloop.cc selector.cc selector.hh
Log message:
Force commit to correct CVS log message. Message /tmp/log.r457 should read:
get rid of superfluous select calls [+4%]. Before we'd call select 3x for each
send / receive. Now only once. Furthermore, I call time() after select, only
if select has a timeout greater than 0. It is common to call select with a
timeout with 0 so this often spares us a call to time(). To send / receive, we
now do the following syscalls:
1) time. Start of event loop.
2) select.
3) read / write
4) time, only if select had a timeout. This call is not performed when there is
data queued, and when there's a high throughput of XRLs, which is good
because that's exactly when we need spare cycles to do work.
Before it was:
1) time.
2) time.
3) time.
4) select.
5) select.
6) select.
7) time.
8) read / write.
9) time.
The overall syscall reduction got us 11%. From 10961 xrls/s, to 12202 xrls/s.
Revision Changes Path
1.36 +1 -1; commitid: 1c5a48d949c241a7; xorp/libxorp/eventloop.cc
1.47 +1 -1; commitid: 1c5a48d949c241a7; xorp/libxorp/selector.cc
1.31 +1 -1; commitid: 1c5a48d949c241a7; xorp/libxorp/selector.hh
More information about the Xorp-cvs
mailing list