Ignore:
Timestamp:
Aug 17, 2007, 6:00:56 PM (17 years ago)
Author:
rosiere
Message:

Changement dans le répertoire "New_Component" afin que les composants nouvellement crées peuvent compiler

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/IPs/systemC/processor/Morpheo/Behavioural/New_Component/SelfTest/src/test.cpp

    r44 r50  
    77 */
    88
    9 #define NB_ITERATION 1
    10 
    11 #define LABEL(str) do {cout << "{"+toString(static_cast<uint32_t>(sc_simulation_time()))+"} " << str << endl; _@COMPONENT->vhdl_testbench_label(str);} while (0)
    12 
    139#include "Behavioural/@DIRECTORY/SelfTest/include/test.h"
    1410#include "Common/include/Test.h"
    1511
     12#define NB_ITERATION  1
     13#define CYCLE_MAX     (128*NB_ITERATION)
     14
     15#define LABEL(str)                                                                       \
     16{                                                                                        \
     17  cout << "{"+toString(static_cast<uint32_t>(sc_simulation_time()))+"} " << str << endl; \
     18} while(0)
     19
     20#define SC_START(cycle)                                        \
     21do                                                             \
     22{                                                              \
     23  if (static_cast<uint32_t>(sc_simulation_time()) > CYCLE_MAX) \
     24    {                                                          \
     25      TEST_KO("Maximal cycles Reached");                       \
     26    }                                                          \
     27  sc_start(cycle);                                             \
     28} while(0)
     29
    1630void test (string name,
    17            morpheo::behavioural::@NAMESPACE_USE::Parameters _param)
     31           morpheo::behavioural::@NAMESPACE_USE::Parameters * _param)
    1832{
    1933  cout << "<" << name << "> : Simulation SystemC" << endl;
     
    2337                                             morpheo::behavioural::Parameters_Statistics(5,50),
    2438#endif
    25                                              _param);
     39                                             *_param);
    2640 
    2741#ifdef SYSTEMC
     
    4862
    4963  cout << "<" << name << "> Start Simulation ............" << endl;
     64  Time * _time = new Time();
    5065
    5166  /********************************************************
     
    6075  srand(seed);
    6176
    62   sc_start(0);
     77  SC_START(0);
    6378  LABEL("Initialisation");
    6479
     
    6984      LABEL("Iteration "+toString(iteration));
    7085
    71       sc_start(1);
     86      SC_START(1);
    7287    }
    7388
     
    7691   ********************************************************/
    7792
     93  TEST_OK ("End of Simulation");
     94  delete _time;
    7895  cout << "<" << name << "> ............ Stop Simulation" << endl;
    7996
Note: See TracChangeset for help on using the changeset viewer.