source: trunk/IPs/systemC/processor/Morpheo/Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor/src/Statistics_print.cpp @ 2

Last change on this file since 2 was 2, checked in by kane, 17 years ago

Import Morpheo

File size: 1.4 KB
Line 
1#ifdef STATISTICS
2/*
3 * $Id$
4 *
5 * [ Description ]
6 *
7 */
8
9#include "Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor/include/Statistics.h"
10
11#include <sstream>
12using namespace std;
13
14namespace morpheo {
15namespace behavioural {
16namespace stage_1_ifetch {
17namespace predictor {
18namespace meta_predictor {
19namespace two_level_branch_predictor {
20
21  string Statistics::print (uint32_t depth,
22                            string   component_stat
23                            )
24  {
25    log_printf(FUNC,Two_Level_Branch_Predictor,"print","Begin");
26
27    string        tab = string(depth,'\t');
28    ostringstream msg;
29
30    msg << tab << "<two_level_branch_predictor name=\"" << _name << "\" >" << endl
31        << print_body(depth+1)
32        << component_stat
33        << tab << "</two_level_branch_predictor>" << endl;
34   
35    log_printf(FUNC,Two_Level_Branch_Predictor,"print","End");
36
37    return msg.str();
38  };
39
40  string Statistics::print (uint32_t depth)
41  {
42    return print(depth,"");
43  };
44
45  ostream& operator<< (ostream& output_stream ,
46                       morpheo::behavioural::stage_1_ifetch::predictor::meta_predictor::two_level_branch_predictor::Statistics & x)
47  {
48    output_stream << x.print(0);
49
50    return output_stream;
51  };
52
53}; // end namespace two_level_branch_predictor
54}; // end namespace meta_predictor
55}; // end namespace predictor
56}; // end namespace stage_1_ifetch
57
58}; // end namespace behavioural
59}; // end namespace morpheo             
60#endif
Note: See TracBrowser for help on using the repository browser.