diff --git a/Makefile b/Makefile index e8ff0e85d..c29917832 100644 --- a/Makefile +++ b/Makefile @@ -176,7 +176,7 @@ ifeq ($(OS), Haiku) CXXFLAGS += -D_DEFAULT_SOURCE endif -YOSYS_VER := 0.58+80 +YOSYS_VER := 0.58+86 YOSYS_MAJOR := $(shell echo $(YOSYS_VER) | cut -d'.' -f1) YOSYS_MINOR := $(shell echo $(YOSYS_VER) | cut -d'.' -f2) YOSYS_COMMIT := $(shell echo $(YOSYS_VER) | cut -d'.' -f3) diff --git a/passes/cmds/bugpoint.cc b/passes/cmds/bugpoint.cc index 897dd8459..0ced09dd9 100644 --- a/passes/cmds/bugpoint.cc +++ b/passes/cmds/bugpoint.cc @@ -28,6 +28,8 @@ # define WEXITSTATUS(x) ((x) & 0xff) # define WTERMSIG(x) SIGTERM # define WSTOPSIG(x) 0 +#else +#include #endif USING_YOSYS_NAMESPACE diff --git a/techlibs/gowin/brams.txt b/techlibs/gowin/brams.txt index 435d3b5cf..ee76dd73a 100644 --- a/techlibs/gowin/brams.txt +++ b/techlibs/gowin/brams.txt @@ -19,8 +19,10 @@ ram block $__GOWIN_SP_ { portoption "WRITE_MODE" 1 { rdwr new; } - portoption "WRITE_MODE" 2 { - rdwr old; + ifndef gw5a { + portoption "WRITE_MODE" 2 { + rdwr old; + } } } } @@ -46,8 +48,10 @@ ram block $__GOWIN_DP_ { portoption "WRITE_MODE" 1 { rdwr new; } - portoption "WRITE_MODE" 2 { - rdwr old; + ifndef gw5a { + portoption "WRITE_MODE" 2 { + rdwr old; + } } } } diff --git a/techlibs/gowin/synth_gowin.cc b/techlibs/gowin/synth_gowin.cc index 1a55f9f37..b9902659c 100644 --- a/techlibs/gowin/synth_gowin.cc +++ b/techlibs/gowin/synth_gowin.cc @@ -263,7 +263,7 @@ struct SynthGowinPass : public ScriptPass if (nolutram) args += " -no-auto-distributed"; } - run("memory_libmap -lib +/gowin/lutrams.txt -lib +/gowin/brams.txt" + args, "(-no-auto-block if -nobram, -no-auto-distributed if -nolutram)"); + run(stringf("memory_libmap -lib +/gowin/lutrams.txt -lib +/gowin/brams.txt -D %s", family) + args, "(-no-auto-block if -nobram, -no-auto-distributed if -nolutram)"); run(stringf("techmap -map +/gowin/lutrams_map.v -map +/gowin/brams_map%s.v", family == "gw5a" ? "_gw5a" : "")); }