1 | #ifdef STATISTICS |
---|
2 | /* |
---|
3 | * $Id: Update_Prediction_Table_statistics_allocation.cpp 88 2008-12-10 18:31:39Z rosiere $ |
---|
4 | * |
---|
5 | * [ Description ] |
---|
6 | * |
---|
7 | */ |
---|
8 | |
---|
9 | #include "Behavioural/Core/Multi_Front_end/Front_end/Prediction_unit/Update_Prediction_Table/include/Update_Prediction_Table.h" |
---|
10 | |
---|
11 | namespace morpheo { |
---|
12 | namespace behavioural { |
---|
13 | namespace core { |
---|
14 | namespace multi_front_end { |
---|
15 | namespace front_end { |
---|
16 | namespace prediction_unit { |
---|
17 | namespace update_prediction_table { |
---|
18 | |
---|
19 | |
---|
20 | #undef FUNCTION |
---|
21 | #define FUNCTION "Update_Prediction_Table::statistics_allocation" |
---|
22 | void Update_Prediction_Table::statistics_allocation (morpheo::behavioural::Parameters_Statistics * param_statistics) |
---|
23 | { |
---|
24 | log_printf(FUNC,Update_Prediction_Table,FUNCTION,"Begin"); |
---|
25 | |
---|
26 | _stat = new Stat (static_cast<std::string>(_name), |
---|
27 | "Update_Prediction_Table", |
---|
28 | param_statistics); |
---|
29 | |
---|
30 | // _stat_nb_branch_hit = new counter_t * [_param->_nb_context]; |
---|
31 | // _stat_nb_branch_miss = new counter_t * [_param->_nb_context]; |
---|
32 | // _stat_nb_branch_unused = new counter_t * [_param->_nb_context]; |
---|
33 | // _stat_queue_nb_cycle_empty = new counter_t * [_param->_nb_context]; |
---|
34 | // _stat_queue_nb_cycle_full = new counter_t * [_param->_nb_context]; |
---|
35 | // _stat_queue_nb_elt = new counter_t * [_param->_nb_context]; |
---|
36 | |
---|
37 | // for (uint32_t i=0; i<_param->_nb_context; ++i) |
---|
38 | // { |
---|
39 | // _stat_nb_branch_hit [i] = _stat->create_counter("nb_branch_hit_" +toString(i),"",toString(_("Branch hit speculation (context %d)"),i)); |
---|
40 | // _stat_nb_branch_miss [i] = _stat->create_counter("nb_branch_miss_" +toString(i),"",toString(_("Branch miss speculation (context %d)"),i)); |
---|
41 | // _stat_nb_branch_unused [i] = _stat->create_counter("nb_branch_unused_" +toString(i),"",toString(_("Branch unused, because an previous branch have miss speculation (context %d)"),i)); |
---|
42 | // _stat_queue_nb_cycle_empty [i] = _stat->create_counter("queue_nb_cycle_empty_"+toString(i),"",toString(_("Cycle number where the Update Prediction Table is empty (context %d)"),i)); |
---|
43 | // _stat_queue_nb_cycle_full [i] = _stat->create_counter("queue_nb_cycle_full_" +toString(i),"",toString(_("Cycle number where the Update Prediction Table is full (%d elements) (context %d)"),_param->_size_queue[i],i)); |
---|
44 | // _stat_queue_nb_elt [i] = _stat->create_counter("queue_nb_elt_" +toString(i),"",toString(_("Average branchement by cycle in Update Prediction Table (context %d)"),i)); |
---|
45 | // } |
---|
46 | |
---|
47 | log_printf(FUNC,Update_Prediction_Table,FUNCTION,"End"); |
---|
48 | }; |
---|
49 | |
---|
50 | }; // end namespace update_prediction_table |
---|
51 | }; // end namespace prediction_unit |
---|
52 | }; // end namespace front_end |
---|
53 | }; // end namespace multi_front_end |
---|
54 | }; // end namespace core |
---|
55 | |
---|
56 | }; // end namespace behavioural |
---|
57 | }; // end namespace morpheo |
---|
58 | #endif |
---|