From a52b833727456d8811c0f2f6c57fd84b58e940d9 Mon Sep 17 00:00:00 2001 From: Dolu1990 Date: Mon, 6 Apr 2020 21:42:44 +0200 Subject: [PATCH] fix weird regression testbench memory bug --- src/test/cpp/regression/main.cpp | 4 ++-- src/test/scala/vexriscv/TestIndividualFeatures.scala | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/test/cpp/regression/main.cpp b/src/test/cpp/regression/main.cpp index ac03373..28d22ee 100644 --- a/src/test/cpp/regression/main.cpp +++ b/src/test/cpp/regression/main.cpp @@ -1782,7 +1782,7 @@ public: virtual void dutPutChar(char c){ if(*hit == c) hit++; else hit = target; - if(*hit == NULL) { + if(*hit == 0) { cout << endl << "T=" << i <ws = ws; @@ -2370,7 +2371,6 @@ public: #endif } else { 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); rsp.last = beat == top->dBus_cmd_payload_length; #ifdef SMP diff --git a/src/test/scala/vexriscv/TestIndividualFeatures.scala b/src/test/scala/vexriscv/TestIndividualFeatures.scala index 8111258..d292203 100644 --- a/src/test/scala/vexriscv/TestIndividualFeatures.scala +++ b/src/test/scala/vexriscv/TestIndividualFeatures.scala @@ -716,7 +716,7 @@ class TestIndividualFeatures extends MultithreadedFunSuite { //Test RTL 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(" ") println(testCmd) val str = doCmd(testCmd)