[Click] More on high latency...

Marko Zec zec at icir.org
Mon Mar 28 15:51:21 EST 2005


On Monday 28 March 2005 22:03, Nicholas Weaver wrote:
> The high latency is definatly occuring within pcap:
>
> Printing the time just after pcap_dispatch calls
> FromDevice_get_packet shows that this is the source of the injected
> latency.
>
> I'm going to try compiling and linking to a different version of pcap
> and see if it makes a difference.


Hi Nick,

following your first report on this issue a week ago, I did some 
digging...  My initial finding was that the problem might actually be 
with the kqueue + bpf not playing nicely together in the FreeBSD 
kernel, so this might have nothing to do with neither Click nor 
libpcap.

What I observed in the kernel was that on each received packet the bpf 
code correctly tried to wake up the listening process using a kqueue 
macro, but the kqueue code for an unknown reason coalesced two such 
events before actually doing the wakeup call.  Having no clue how the 
kqueue kernel infrastructure is supposed to work internally I stopped 
at that point, and then went into a suspend mode for a week after 
becoming a happy father last weekend...  Will look more into this one 
of these days.

Cheers,

Marko


More information about the click mailing list