source: trunk/IPs/systemC/processor/Morpheo/Behavioural/Core/Multi_Front_end/Front_end/Prediction_unit/Prediction_unit_Glue/src/Parameters_print.cpp @ 81

Last change on this file since 81 was 81, checked in by rosiere, 16 years ago
  • Finish Environment (and test)
  • Continue predictor_unit
  • Add external tools
  • svn keyword "Id" set
File size: 2.5 KB
Line 
1/*
2 * $Id$
3 *
4 * [ Description ]
5 *
6 */
7
8#include "Behavioural/Core/Multi_Front_end/Front_end/Prediction_unit/Prediction_unit_Glue/include/Parameters.h"
9#include "Behavioural/include/XML.h"
10
11namespace morpheo                    {
12namespace behavioural {
13namespace core {
14namespace multi_front_end {
15namespace front_end {
16namespace prediction_unit {
17namespace prediction_unit_glue {
18
19
20#undef  FUNCTION
21#define FUNCTION "Prediction_unit_Glue::print"
22  std::string Parameters::print (uint32_t depth)
23  {
24    log_printf(FUNC,Prediction_unit_Glue,FUNCTION,"Begin");
25
26    XML xml ("prediction_unit_glue");
27
28    xml.balise_open("prediction_unit_glue");
29    xml.singleton_begin("nb_context     "); xml.attribut("value",toString(_nb_context     )); xml.singleton_end();
30    xml.singleton_begin("size_address   "); xml.attribut("value",toString(_size_address   )); xml.singleton_end();
31    xml.singleton_begin("nb_inst_predict"); xml.attribut("value",toString(_nb_inst_predict)); xml.singleton_end();
32    xml.singleton_begin("nb_inst_decod  "); xml.attribut("value",toString(_nb_inst_decod  )); xml.singleton_end();
33    xml.singleton_begin("nb_inst_update "); xml.attribut("value",toString(_nb_inst_update )); xml.singleton_end();
34    for (uint32_t i=0;i<_nb_context; i++)
35      {
36        xml. balise_open_begin("component");
37        xml.  attribut("type","context");
38        xml.  attribut("id"  ,toString(i));
39        xml. balise_open_end();
40        xml.  singleton_begin("nb_instruction "); xml.attribut("value",toString(_nb_instruction [i])); xml.singleton_end();
41        xml.  singleton_begin("size_depth     "); xml.attribut("value",toString(_size_depth     [i])); xml.singleton_end();
42        xml. balise_close();
43      }
44    xml.balise_close();
45
46    log_printf(FUNC,Prediction_unit_Glue,FUNCTION,"End");
47   
48    return xml.get_body(depth);
49  };
50
51#undef  FUNCTION
52#define FUNCTION "Prediction_unit_Glue::operator<<"
53  std::ostream& operator<< (std::ostream& output_stream ,
54                            morpheo::behavioural::core::multi_front_end::front_end::prediction_unit::prediction_unit_glue::Parameters & x)
55  {
56    log_printf(FUNC,Prediction_unit_Glue,FUNCTION,"Begin");
57
58    output_stream << x.print(0);
59   
60    log_printf(FUNC,Prediction_unit_Glue,FUNCTION,"End");
61
62    return output_stream;
63  };
64
65}; // end namespace prediction_unit_glue
66}; // end namespace prediction_unit
67}; // end namespace front_end
68}; // end namespace multi_front_end
69}; // end namespace core
70
71}; // end namespace behavioural
72}; // end namespace morpheo             
Note: See TracBrowser for help on using the repository browser.