diff --git a/src/test/cpp/briey/main.cpp b/src/test/cpp/briey/main.cpp index 0ee7c45..d2b372c 100644 --- a/src/test/cpp/briey/main.cpp +++ b/src/test/cpp/briey/main.cpp @@ -6,7 +6,6 @@ #include "VBriey_RiscvCore.h" #endif #include "verilated.h" -#include "verilated_vcd_c.h" #include #include #include diff --git a/src/test/cpp/briey/makefile b/src/test/cpp/briey/makefile index 12d4c97..e0a024b 100644 --- a/src/test/cpp/briey/makefile +++ b/src/test/cpp/briey/makefile @@ -13,7 +13,7 @@ ADDCFLAGS += -LDFLAGS -lSDL2 ifeq ($(TRACE),yes) VERILATOR_ARGS += --trace - ADDCFLAGS += -CFLAGS -DTRACE + ADDCFLAGS += -CFLAGS -DTRACE --trace-fst endif ifeq ($(DEBUG),yes) ADDCFLAGS += -CFLAGS "-g3 -O0" diff --git a/src/test/cpp/briey/makefile~ b/src/test/cpp/briey/makefile~ deleted file mode 100644 index b8345fd..0000000 --- a/src/test/cpp/briey/makefile~ +++ /dev/null @@ -1,38 +0,0 @@ -DEBUG?=no -TRACE?=no -PRINT_PERF?=no -TRACE_START=0 -ADDCFLAGS += -CFLAGS -pthread - -ifeq ($(TRACE),yes) - VERILATOR_ARGS += --trace - ADDCFLAGS += -CFLAGS -DTRACE -endif -ifeq ($(DEBUG),yes) - ADDCFLAGS += -CFLAGS "-g3 -O0" -endif -ifneq ($(DEBUG),yes) - ADDCFLAGS += -CFLAGS "-O3" -endif -ifeq ($(PRINT_PERF),yes) - ADDCFLAGS += -CFLAGS -DPRINT_PERF -endif - -ADDCFLAGS += -CFLAGS -DTRACE_START=${TRACE_START} - - - -all: clean compile - -run: compile - ./obj_dir/VBriey - -verilate: - verilator -cc ../../../../Briey.v -CFLAGS -std=c++11 ${ADDCFLAGS} --gdbbt ${VERILATOR_ARGS} -Wno-WIDTH --x-assign unique --exe main.cpp - -compile: verilate - make -j -C obj_dir/ -f VBriey.mk VBriey - -clean: - rm -rf obj_dir - diff --git a/src/test/cpp/common/framework.h b/src/test/cpp/common/framework.h index 562d467..42c1f34 100644 --- a/src/test/cpp/common/framework.h +++ b/src/test/cpp/common/framework.h @@ -11,6 +11,7 @@ #include #include #include +#include "verilated_fst_c.h" using namespace std; @@ -140,7 +141,7 @@ public: string name; uint64_t time = 0; #ifdef TRACE - VerilatedVcdC* tfp; + VerilatedFstC* tfp; #endif ofstream logTraces; @@ -184,9 +185,9 @@ public: // init trace dump #ifdef TRACE Verilated::traceEverOn(true); - tfp = new VerilatedVcdC; + tfp = new VerilatedFstC; top->trace(tfp, 99); - tfp->open((string(name)+ ".vcd").c_str()); + tfp->open((string(name)+ ".fst").c_str()); #endif struct timespec start_time,tick_time; diff --git a/src/test/cpp/murax/makefile b/src/test/cpp/murax/makefile index 71a5cd6..7c946ae 100644 --- a/src/test/cpp/murax/makefile +++ b/src/test/cpp/murax/makefile @@ -7,7 +7,7 @@ ADDCFLAGS += -CFLAGS -pthread -LDFLAGS -pthread ifeq ($(TRACE),yes) VERILATOR_ARGS += --trace - ADDCFLAGS += -CFLAGS -DTRACE + ADDCFLAGS += -CFLAGS -DTRACE --trace-fst endif ifeq ($(DEBUG),yes) ADDCFLAGS += -CFLAGS "-g3 -O0"