fix weird regression testbench memory bug

This commit is contained in:
Dolu1990 2020-04-06 21:42:44 +02:00
parent a107e45116
commit a52b833727
2 changed files with 3 additions and 3 deletions

View File

@ -1782,7 +1782,7 @@ public:
virtual void dutPutChar(char c){ virtual void dutPutChar(char c){
if(*hit == c) hit++; else hit = target; if(*hit == c) hit++; else hit = target;
if(*hit == NULL) { if(*hit == 0) {
cout << endl << "T=" << i <<endl; cout << endl << "T=" << i <<endl;
cout << endl; cout << endl;
pass(); pass();
@ -2338,6 +2338,7 @@ public:
Workspace *ws; Workspace *ws;
VVexRiscv* top; VVexRiscv* top;
DBusCachedTask rsp;
DBusCached(Workspace* ws){ DBusCached(Workspace* ws){
this->ws = ws; this->ws = ws;
@ -2370,7 +2371,6 @@ public:
#endif #endif
} else { } else {
for(int beat = 0;beat <= top->dBus_cmd_payload_length;beat++){ for(int beat = 0;beat <= top->dBus_cmd_payload_length;beat++){
DBusCachedTask rsp;
ws->dBusAccess(top->dBus_cmd_payload_address + beat * 4,0,2,0,&rsp.data,&rsp.error); ws->dBusAccess(top->dBus_cmd_payload_address + beat * 4,0,2,0,&rsp.data,&rsp.error);
rsp.last = beat == top->dBus_cmd_payload_length; rsp.last = beat == top->dBus_cmd_payload_length;
#ifdef SMP #ifdef SMP

View File

@ -716,7 +716,7 @@ class TestIndividualFeatures extends MultithreadedFunSuite {
//Test RTL //Test RTL
val debug = true val debug = true
val stdCmd = (s"make run REGRESSION_PATH=../../src/test/cpp/regression VEXRISCV_FILE=VexRiscv.v WITH_USER_IO=no REDO=10 TRACE=${if(debug) "yes" else "no"} TRACE_START=1000000000ll FLOW_INFO=no STOP_ON_ERROR=no DHRYSTONE=yes COREMARK=${coremarkRegression} THREAD_COUNT=1 ") + s" SEED=${testSeed} " val stdCmd = (s"make run REGRESSION_PATH=../../src/test/cpp/regression VEXRISCV_FILE=VexRiscv.v WITH_USER_IO=no REDO=10 TRACE=${if(debug) "yes" else "no"} TRACE_START=100000000000ll FLOW_INFO=no STOP_ON_ERROR=no DHRYSTONE=yes COREMARK=${coremarkRegression} THREAD_COUNT=1 ") + s" SEED=${testSeed} "
val testCmd = stdCmd + (positionsToApply).map(_.testParam).mkString(" ") val testCmd = stdCmd + (positionsToApply).map(_.testParam).mkString(" ")
println(testCmd) println(testCmd)
val str = doCmd(testCmd) val str = doCmd(testCmd)