annotate main.c @ 9:a4fc1d735dce

New Structures for InPorts and OutPorts Defined
author sohan
date Tue, 13 Mar 2012 18:08:09 +0100
parents def43ecee616
children
rev   line source
Me@0 1 /*
Me@0 2 * Copyright 2011 OpenSourceStewardshipFoundation.org
Me@0 3 * Licensed under BSD
Me@0 4 *
Me@0 5 * author seanhalle@yahoo.com
Me@0 6 */
Me@0 7
Me@0 8 #include <malloc.h>
Me@0 9 #include <stdlib.h>
Me@0 10
Me@0 11 #include "SimParams.h"
kshalle@1 12 #include "HWSim__LPGPU_Arch__HWDef/HWSim__LPGPU_Arch__HWDef.h"
kshalle@1 13 //Stefan: name conflict here -- MC_shared version of params is in HWSim__PingPong__HWDef.h, but need normal C version here
kshalle@1 14 #include "../C_Libraries/ParamHelper/Param.h"
kshalle@1 15
Me@0 16
Me@0 17 char __ProgrammName[] = "HWSim Hello World";
Me@0 18 char __DataSet[255];
Me@0 19 char __Scheduler[];
Me@0 20
Me@0 21 /*
Me@0 22 *
Me@0 23 *
Me@0 24 */
Me@0 25
Me@0 26 int main( int argc, char **argv )
Me@0 27 { ParamBag *simParams;
Me@0 28 HWSimNetlist *netlist;
Me@0 29 HWSimResults *simResults;
Me@0 30
Me@0 31 printf( "param file name: %s\n", argv[1] );
Me@0 32 printf("Paraver trace file %s\n", argv[2]);
Me@0 33
Me@0 34 #ifdef FAKE
Me@0 35 simParams= NULL;
Me@0 36 #else
Me@0 37 simParams = makeParamBag();
Me@0 38 readParamFileIntoBag( argv[1], simParams );
Me@0 39 #endif
Me@0 40
Me@0 41 netlist = createPingPongNetlist();
Me@0 42 #ifdef FAKE
Me@0 43 simResults= create_simulation_results__fake(simParams,netlist);
Me@0 44 #else
Me@0 45 simResults =
Me@0 46 HWSim__run_simulation( simParams, netlist );
Me@0 47 #endif
Me@0 48
Me@0 49 //HWSim
Me@0 50 HWSim__generate_paraver_output(argv[2], simResults, netlist);
Me@0 51 //HWSim__generate_vcd_output( simResults );
Me@0 52
Me@0 53 exit(0); //cleans up
Me@0 54 }
Me@0 55