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

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

Import Morpheo

File size: 2.3 KB
Line 
1/*
2 * $Id$
3 *
4 * [ Description ]
5 *
6 */
7
8#include "Behavioural/Stage_1_Ifetch/Predictor/Meta_Predictor/Two_Level_Branch_Predictor/Two_Level_Branch_Predictor_Glue/include/Parameters.h"
9#include <sstream>
10using namespace std;
11
12namespace morpheo                    {
13namespace behavioural {
14namespace stage_1_ifetch {
15namespace predictor {
16namespace meta_predictor {
17namespace two_level_branch_predictor {
18namespace two_level_branch_predictor_glue {
19
20
21  string Parameters::print (uint32_t depth)
22  {
23    log_printf(FUNC,Two_Level_Branch_Predictor_Glue,"print","Begin");
24
25    string tab = string(depth,'\t');
26    ostringstream msg;
27    msg << tab << "<two_level_branch_predictor_glue>" << endl
28        << tab << "\t<have_bht               value=\"" << _have_bht               << "\" />" << endl
29        << tab << "\t<bht_size_history       value=\"" << _bht_size_history       << "\" />" << endl
30        << tab << "\t<bht_size_address       value=\"" << _bht_size_address       << "\" />" << endl
31        << tab << "\t<have_pht               value=\"" << _have_pht               << "\" />" << endl
32        << tab << "\t<pht_size_address       value=\"" << _pht_size_address       << "\" />" << endl
33        << tab << "\t<pht_size_address_share value=\"" << _pht_size_address_share << "\" /> <!-- Need " << _pht_size_address_shift << " bits to shift -->" << endl
34        << tab << "\t<size_address           value=\"" << _size_address           << "\" />" << endl
35        << tab << "\t<nb_prediction          value=\"" << _nb_prediction          << "\" />" << endl
36        << tab << "\t<nb_branch_complete     value=\"" << _nb_branch_complete     << "\" />" << endl
37        << tab << "</two_level_branch_predictor_glue>" << endl;
38
39    log_printf(FUNC,Two_Level_Branch_Predictor_Glue,"print","End");
40   
41    return msg.str();
42  };
43
44  ostream& operator<< (ostream& output_stream ,
45                       morpheo::behavioural::stage_1_ifetch::predictor::meta_predictor::two_level_branch_predictor::two_level_branch_predictor_glue::Parameters & x)
46  {
47    output_stream << x.print(0);
48   
49    return output_stream;
50  };
51
52}; // end namespace two_level_branch_predictor_glue
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             
Note: See TracBrowser for help on using the repository browser.