source: trunk/IPs/systemC/processor/Morpheo/Behavioural/Generic/Priority/src/Priority_transition_load_balancing_balance.cpp @ 88

Last change on this file since 88 was 88, checked in by rosiere, 15 years ago

Almost complete design
with Test and test platform

  • Property svn:keywords set to Id
File size: 788 bytes
Line 
1/*
2 * $Id: Priority_transition_load_balancing_balance.cpp 88 2008-12-10 18:31:39Z rosiere $
3 *
4 * [ Description ]
5 *
6 */
7
8#include "Behavioural/Generic/Priority/include/Priority.h"
9
10namespace morpheo                    {
11namespace behavioural {
12namespace generic {
13namespace priority {
14 
15#undef  FUNCTION
16#define FUNCTION "Priority::transition_load_balancing_balance"
17  void Priority::transition_load_balancing_balance (void)
18  {
19    log_begin(Priority,FUNCTION);
20
21    for (uint32_t j=0; j<_max_nb_elt; j++)
22      for (uint32_t i=0; i<_nb_grp_select; i++)
23        {
24          uint32_t x=(reg_GRP_PRIORITY+i)%_nb_grp;
25         
26          // Test valid elt
27          if (j < _nb_elt[x])
28            _select.push_back(select_t(x,j));
29        }
30   
31    log_end(Priority,FUNCTION);
32  };
33
34}; // end namespace priority
35}; // end namespace generic
36}; // end namespace behavioural
37}; // end namespace morpheo             
Note: See TracBrowser for help on using the repository browser.