#ifdef SYSTEMC
/*
 * $Id: Front_end_Glue_genMealy_nb_inst.cpp 108 2009-02-12 11:55:06Z rosiere $
 *
 * [ Description ]
 * 
 */

#include "Behavioural/Core/Multi_Front_end/Front_end/Front_end_Glue/include/Front_end_Glue.h"

namespace morpheo                    {
namespace behavioural {
namespace core {
namespace multi_front_end {
namespace front_end {
namespace front_end_glue {

#undef  FUNCTION
#define FUNCTION "Front_end_Glue::genMealy_nb_inst"
  void Front_end_Glue::genMealy_nb_inst (void)
  {
    log_begin(Front_end_Glue,FUNCTION);

    for (uint32_t i=0; i<_param->_nb_context; ++i)
      {
        Tcounter_t nb_inst = PORT_READ(in_NB_INST_DECOD_UNIT_DECOD_ALL [i]);

        PORT_WRITE(out_NB_INST_DECOD_ALL               [i], nb_inst);
        PORT_WRITE(out_NB_INST_CONTEXT_STATE_DECOD_ALL [i], nb_inst);
      }

    log_end(Front_end_Glue,FUNCTION);
  };

}; // end namespace front_end_glue
}; // end namespace front_end
}; // end namespace multi_front_end
}; // end namespace core

}; // end namespace behavioural
}; // end namespace morpheo              
#endif
