diff --git a/npc/Makefile b/npc/Makefile index 8e1d233..0ad9d4a 100644 --- a/npc/Makefile +++ b/npc/Makefile @@ -2,6 +2,7 @@ VSRC := $(wildcard vsrc/*.v) CPPSRC := $(addprefix $(PWD)/,$(wildcard csrc/*.cpp)) PREFIX ?= build OBJDIR := $(PREFIX)/obj +VERILATOR_FLAGS := --cc --exe all: $(OBJDIR) $(MAKE) -j -C $(OBJDIR) -f Vexample.mk Vexample @@ -10,8 +11,9 @@ sim: all $(call git_commit, "sim RTL") # DO NOT REMOVE THIS LINE!!! @echo "Running" $(OBJDIR)/Vexample "..." @echo "================================" - @$(OBJDIR)/Vexample +trace off + @$(OBJDIR)/Vexample +tracing_off +trace: VERILATOR_FLAGS += --trace trace: all $(call git_commit, "trace RTL") # DO NOT REMOVE THIS LINE!!! @$(OBJDIR)/Vexample @@ -19,7 +21,7 @@ trace: all $(OBJDIR): $(VSRC) $(CPPSRC) mkdir -p $(OBJDIR) - verilator --trace --cc --exe --Mdir $(PWD)/$(OBJDIR) $(VSRC) $(CPPSRC) + verilator $(VERILATOR_FLAGS) --Mdir $(PWD)/$(OBJDIR) $(VSRC) $(CPPSRC) include ../Makefile