[reSIProcate] transport selector and loopback interfaces
Kennard White
kennard_white at logitech.com
Wed Dec 8 23:50:37 CST 2010
Hi,
I've been profiling resiprocate with the epoll changes to identify and fix
bottlenecks. The latest issue I've found is a bit of a corner case, but it
is the one that I'm profiling against so it matters a lot to me for the
moment. Specifically, I'm using resip/stack/test/testStack with:
- loopback interface
- explicitly routed with a Via header (route by Source, not by Dest).
- Many (10000) transports (different ports).
Within TransportSelector::findTransportBySource(), this hits the O(N)
traversal thru all transports.
I'd like to re-order the search order to first search for exact match of of
interface, and then only if that doesn't match to do the search thru all
transports looking for loopbacks. Aside from solving my performance issue
(because the exact search is STL indexed), this seems more correct: should
first look for the exact transport requested, then expand the search.
The findTransportBySource code splits into the with-port and without-port
cases. I'd make the same re-order change to both cases.
Anyone see any issues with this change? I believe Byron added the existing
loopback handling.
Thanks,
Kennard
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://list.resiprocate.org/pipermail/resiprocate-devel/attachments/20101208/f9967233/attachment.htm>
More information about the resiprocate-devel
mailing list