From: Eddie Hung Date: Fri, 10 Jan 2020 23:04:13 +0000 (-0800) Subject: abc9: add abc9.verify and abc9.debug options X-Git-Tag: working-ls180~870^2~6 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=291530c59f639609bc7534e561f28c9fb4081e19;p=yosys.git abc9: add abc9.verify and abc9.debug options --- diff --git a/passes/techmap/abc9.cc b/passes/techmap/abc9.cc index 22f5a1f3a..3ce435dd0 100644 --- a/passes/techmap/abc9.cc +++ b/passes/techmap/abc9.cc @@ -308,7 +308,14 @@ void abc9_module(RTLIL::Design *design, RTLIL::Module *module, std::string scrip for (size_t pos = abc9_script.find("&mfs"); pos != std::string::npos; pos = abc9_script.find("&mfs", pos)) abc9_script = abc9_script.erase(pos, strlen("&mfs")); - abc9_script += stringf("; &ps -l; &write -n %s/output.aig; time", tempdir_name.c_str()); + abc9_script += stringf("; &ps -l; &write -n %s/output.aig;", tempdir_name.c_str()); + if (design->scratchpad_get_bool("abc9.debug")) { + if (dff_mode) + abc9_script += "verify -s;"; + else + abc9_script += "verify;"; + } + abc9_script += "time"; abc9_script = add_echos_to_abc9_cmd(abc9_script); for (size_t i = 0; i+1 < abc9_script.size(); i++) @@ -910,6 +917,11 @@ struct Abc9Pass : public Pass { } nomfs = design->scratchpad_get_bool("abc9.nomfs", nomfs); + if (design->scratchpad_get_bool("abc9.debug")) { + cleanup = false; + show_tempdir = true; + } + size_t argidx; char pwd [PATH_MAX]; if (!getcwd(pwd, sizeof(pwd))) {