diff options
author | Eddie Hung <eddie@fpgeh.com> | 2020-01-08 12:13:06 -0800 |
---|---|---|
committer | Eddie Hung <eddie@fpgeh.com> | 2020-01-08 12:13:06 -0800 |
commit | 589ffead5cca63a55506eb3b291ffd025f0f9c0f (patch) | |
tree | d56cb0c73794c0f5c88fdd1f38469f1de06cc0f5 /passes/techmap | |
parent | 0696b7bc9e4bd86eadd0e0b92696392cc5dc6172 (diff) | |
download | yosys-589ffead5cca63a55506eb3b291ffd025f0f9c0f.tar.gz yosys-589ffead5cca63a55506eb3b291ffd025f0f9c0f.tar.bz2 yosys-589ffead5cca63a55506eb3b291ffd025f0f9c0f.zip |
scratchpad entry abc9.if.R to &if -R
Diffstat (limited to 'passes/techmap')
-rw-r--r-- | passes/techmap/abc9.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/passes/techmap/abc9.cc b/passes/techmap/abc9.cc index 5bcbb1611..3fdcc0e5c 100644 --- a/passes/techmap/abc9.cc +++ b/passes/techmap/abc9.cc @@ -303,6 +303,12 @@ void abc9_module(RTLIL::Design *design, RTLIL::Module *module, std::string scrip for (size_t pos = abc9_script.find("{C}"); pos != std::string::npos; pos = abc9_script.find("{C}", pos)) abc9_script = abc9_script.substr(0, pos) + C + abc9_script.substr(pos+3); + std::string R; + if (design->scratchpad.count("abc9.if.R")) + C = "-C " + design->scratchpad_get_string("abc9.if.R"); + for (size_t pos = abc9_script.find("{R}"); pos != std::string::npos; pos = abc9_script.find("{R}", pos)) + abc9_script = abc9_script.substr(0, pos) + C + abc9_script.substr(pos+3); + if (nomfs) 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")); |