tracerecorder, refresh and stuff

This commit is contained in:
robert
2014-03-29 00:26:21 +01:00
parent 35ba108cf7
commit 04e38d6663
40 changed files with 417 additions and 362 deletions

View File

@@ -10,7 +10,7 @@
#include <fstream>
#include <algorithm>
#include <string>
#include "../common/tlmDBPhaseRecorder.h"
#include "../common/TlmRecorder.h"
#include "../common/DebugManager.h"
#include "../common/xmlAddressdecoder.h"
#include "controllerwrapper.h"
@@ -29,11 +29,13 @@ string pathOfFile(string file)
int sc_main(int argc, char **argv)
{
string resources = pathOfFile(argv[0]) + string("/../resources/");
sc_set_time_resolution(1,SC_NS);
string resources = pathOfFile(argv[0]) + string("/../resources/");
xmlAddressDecoder::addressConfigURI = resources + string("configs/addressConfig.xml");
TlmRecorder recorder("tpr.tdb", resources + string("scripts/createTraceDB.sql"));
TracePlayer<> player("player", resources + string("traces/chstone-mips_32.stl"));
xmlAddressDecoder::URI = resources + string("configs/addressConfig.xml");
tlmDBPhaseRecorder recorder("tpr.tdb", resources + string("scripts/createTraceDB.sql"));
TracePlayer<> player("player", resources + string("traces/mediabench-h263encode_32.stl"));
Dram<> dram("dram");
Arbiter<> arbiter("arbiter");
ControllerWrapper<> controller("controller", recorder);
@@ -42,10 +44,12 @@ int sc_main(int argc, char **argv)
arbiter.iSocket.bind(controller.tSocket);
controller.iSocket.bind(dram.tSocket);
//DebugManager::getInstance().addToWhiteList(Sender::TraceRecorder);
DebugManager::getInstance().addToWhiteList(Sender::TraceRecorder);
DebugManager::getInstance().addToWhiteList(Sender::TracePlayer);
cout << "Toplevel: simulation start" << std::endl;
clock_t begin = clock();
sc_start();
clock_t end = clock();
double elapsed_secs = double(end - begin) / CLOCKS_PER_SEC;
@@ -58,7 +62,7 @@ int sc_main(int argc, char **argv)
//system(runTestCommand.c_str());
string run_tpr =
"/home/jonny/git/analyzer/build-traceAnalyzer-Desktop-Debug/traceAnalyzer tpr.tdb";
"/home/robert/analyzer/build/traceAnalyzer tpr.tdb";
system(run_tpr.c_str());
return 0;
}