- Timestamp:
- May 12, 2010, 7:34:01 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/IPs/systemC/processor/Morpheo/Behavioural/src/Stat.cpp
r124 r138 14 14 _save_periodic (_period>0) 15 15 { 16 _generate_file = true; 17 16 18 _list_operand = new std::map<std::string, var_t>; 17 19 _list_expr = new std::list<expr_t>; 18 20 _list_stat = new std::list<Stat *>; 21 _list_counters = new std::list<counters_t *>; 19 22 20 23 _cycle = create_variable("cycle"); 21 24 // _cycle = create_counter("cycle","",""); 22 25 *_cycle = 0; // for the first period 23 24 _generate_file = true;25 26 } 26 27 … … 35 36 _save_periodic (period>0) 36 37 { 38 _generate_file = true; 39 37 40 _list_operand = new std::map<std::string, var_t>; 38 41 _list_expr = new std::list<expr_t>; 39 42 _list_stat = new std::list<Stat *>; 43 _list_counters = new std::list<counters_t *>; 40 44 41 45 _cycle = create_variable("cycle"); 42 46 // _cycle = create_counter("cycle","",""); 43 47 *_cycle = 0; // for the first period 44 45 _generate_file = true;46 48 } 47 49 … … 68 70 } 69 71 delete _list_expr; 72 73 // parcourir la liste et desallouer les arbres 74 for (std::list<counters_t*>::iterator i=_list_counters->begin(); 75 i!= _list_counters->end(); 76 ++i) 77 { 78 delete *i; 79 } 80 delete _list_counters; 81 70 82 delete _list_stat; 71 83 }
Note: See TracChangeset
for help on using the changeset viewer.