On Thu, 3 Feb 2011, Nilay Vaish wrote:

I implemented this approach. But it did not improve the performance. So I tried to explore what could be the cause. The function PerfectSwitch::wakeup() contains three loops.

loop on number of virtual networks
 loop on number of incoming links
   loop till all messages for this (link, network) have been routed

I am working with an 8 processor mesh network and run ruby_random_test.py for 400,000 loads. About 11-12% of the time is taken by this function, which is the highest amongst all the functions. I moved the third loop to another function. I found that the wakeup function is itself called about 76,000,000 times, number of messages processed is about 81,000,000. Out of these about 71,000,000 have destination count = 1. Surprisingly the inner loop, that I had separated out as a function, was called 3,600,000,000 times. That is about 45 times per invocation of the wakeup function, when each invocation of the wakeup function processes just about one message.

When is the wakeup function called? Is it called in a periodic fashion? Or when a message needs to routed? Is it possible that instead of looking at all the virtual networks and links, we look at only those that have messages that need routing?


I found that wakeup is scheduled only when a message needs to be routed. This is done using the consumer pointer. So, we need to some how inform the switch when ever wake up event happens, following <link, network>s need to be looked at. But this would mean a change in the Consumer class and in the RubyEvent class. Should we add a new parameter to the scheduling function, which would be some information that the wakeup function receives?

--
Nilay
_______________________________________________
m5-dev mailing list
m5-dev@m5sim.org
http://m5sim.org/mailman/listinfo/m5-dev

Reply via email to