[Click] Thread scheduling

Eric Liu ewl2113 at columbia.edu
Thu Feb 4 15:32:29 EST 2010


I am having a problem with StaticThreadSched not creating multiple threads.
When using StaticThreadSched on four elements, they all end up being bound
to the same thread.  However, using BalancedThreadSched they always get
separate threads, but there is no way to control which element is on which
thread.  I am not sure if I am misunderstanding the way StaticThreadSched
functions.  Here is the Click configuration:

fire1 :: FastUDPSource(150000, 3000000, 64,
   00:1b:21:42:c3:cc, 192.168.4.1, 12345,
   00:1b:21:42:c3:44, 192.168.5.3, 44444)
-> ctr1 :: Counter
-> td1 :: ToDevice(eth4);
fire2 :: FastUDPSource(150000, 3000000, 64,
           00:1b:21:42:c3:c8, 192.168.2.1, 12345,
           00:1b:21:42:c3:40, 192.168.3.3, 44444)
-> ctr2 :: Counter
-> td2 :: ToDevice(eth2);

pd1 :: PollDevice(eth4) -> ToHost;
pd2 :: PollDevice(eth2) -> ToHost;

StaticThreadSched(td2 0, td1 1, pd2 1, pd1 0);
//BalancedThreadSched();
ThreadMonitor(1000, 1);

Thanks for any input and assistance you can provide.

-Eric


More information about the click mailing list