source: trunk/IPs/systemC/processor/Morpheo/Behavioural/src/Statistics_compute_cycle_xxx.cpp @ 43

Last change on this file since 43 was 43, checked in by rosiere, 17 years ago

Modif mineur : ajout d'info de débug

Release non stable

File size: 1.1 KB
Line 
1#ifdef STATISTICS
2
3/*
4 * $Id$
5 *
6 * [ Description ]
7 *
8 */
9
10#include "Behavioural/include/Statistics.h"
11
12namespace morpheo              {
13namespace behavioural          {
14
15#undef  FUNCTION
16#define FUNCTION "Statistics::compute_cycle_begin"
17  uint32_t Statistics::compute_cycle_begin (uint32_t num_statistics)
18  {
19    log_printf(FUNC,Behavioural,FUNCTION,"Begin");
20    uint32_t _return = _parameters_statistics._nb_cycle_before_begin + num_statistics*_parameters_statistics._period_save;
21    log_printf(FUNC,Behavioural,FUNCTION,"End");
22   
23    return _return;
24  };
25
26#undef  FUNCTION
27#define FUNCTION "Statistics::compute_cycle_end"
28  uint32_t Statistics::compute_cycle_end   (uint32_t num_statistics, uint32_t nb_cycle)
29  {
30    log_printf(FUNC,Behavioural,FUNCTION,"Begin");
31
32    uint32_t _return;
33    if (num_statistics == (_nb_statistics-1)) // Last ?
34      _return = compute_cycle_begin(num_statistics  ) + nb_cycle;
35    else
36      _return = compute_cycle_begin(num_statistics+1) - 1;
37
38    log_printf(FUNC,Behavioural,FUNCTION,"End");
39
40    return _return;
41  };
42
43}; // end namespace behavioural         
44}; // end namespace morpheo             
45
46#endif
Note: See TracBrowser for help on using the repository browser.