From ecb60f6e43092e9816c0f2ab231a250c55927a7a Mon Sep 17 00:00:00 2001 From: Florent Kermarrec Date: Fri, 7 Jun 2019 11:16:39 +0200 Subject: [PATCH] build/sim: use -O0 for verilator compilation In most of the case, execution speed is already fast enough with -O0 and with complex design -O0 is a lost faster to compile than -O3. In the future we could add a switch to choose which optimization we want. --- litex/build/sim/core/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/litex/build/sim/core/Makefile b/litex/build/sim/core/Makefile index 3737af823..149789d8c 100644 --- a/litex/build/sim/core/Makefile +++ b/litex/build/sim/core/Makefile @@ -1,7 +1,7 @@ include variables.mak CC = gcc -CFLAGS = -Wall -O3 -ggdb $(if $(COVERAGE), -DVM_COVERAGE) +CFLAGS = -Wall -O0 -ggdb $(if $(COVERAGE), -DVM_COVERAGE) LDFLAGS = -lpthread -ljson-c -lm -lstdc++ -ldl -levent CC_SRCS ?= "--cc dut.v"