[Click] Question around RouterThread

Beyers Cronje bcronje at gmail.com
Tue May 17 17:14:07 EDT 2011


Hi,

I've been toying with multithreading in click, specifically in userlevel
click. My understanding is that all click threads participate in running
timers and os (selected etc). I'm thinking about testing something where a
user can specify that certain threads should not participate in any timers
or selected processing and only process task(s) allocated to it. As a simple
example consider the following userlevel config:

fd::FromDevice(eth0) -> Classifier(*some pattern*) -> Queue ->
td::ToDump(/dev/null);
StaticThreadSched(fd 0, td 1);


If FromDevice or whatever source element processes a constant high packet
rate, and ToDump only a fraction of packets as filtered by Classifier it
would make sense to have fd dedicate to processing RX packets and have the
td thread handle all other non-task related processes. Throw in a
ControlSocket and maybe a couple more dumps I'm pretty sure it will affect
fd performance.

So my question, do you guys feel this will make any difference? Is my
understanding on how RouterThread handles timers etc wrong? I'm really
curious to hear your thoughts on this.

Beyers


More information about the click mailing list