From: Eddie Hung Date: Thu, 26 Sep 2019 17:45:14 +0000 (-0700) Subject: Combine 'flatten' & 'coarse' labels in synth_ecp5 so proc run once X-Git-Tag: working-ls180~1039^2~9 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=84825f937827f3e8fd3702a7ea85b8997ac74534;p=yosys.git Combine 'flatten' & 'coarse' labels in synth_ecp5 so proc run once --- diff --git a/techlibs/ecp5/synth_ecp5.cc b/techlibs/ecp5/synth_ecp5.cc index 0a3dcc62c..1f5b1cb6b 100644 --- a/techlibs/ecp5/synth_ecp5.cc +++ b/techlibs/ecp5/synth_ecp5.cc @@ -226,16 +226,13 @@ struct SynthEcp5Pass : public ScriptPass run(stringf("hierarchy -check %s", help_mode ? "-top " : top_opt.c_str())); } - if (flatten && check_label("flatten", "(unless -noflatten)")) + if (check_label("coarse")) { run("proc"); - run("flatten"); + if (flatten || help_mode) + run("flatten"); run("tribuf -logic"); run("deminout"); - } - - if (check_label("coarse")) - { run("opt_expr"); run("opt_clean"); run("check"); @@ -248,9 +245,7 @@ struct SynthEcp5Pass : public ScriptPass run("opt_expr"); run("opt_clean"); if (!nodsp) { - run("techmap -map +/mul2dsp.v -D DSP_A_MAXWIDTH=18 -D DSP_B_MAXWIDTH=18 -D DSP_A_MINWIDTH=2 -D DSP_B_MINWIDTH=2 -D DSP_NAME=$__MUL18X18", "(unless -nodsp)"); - run("clean", "(unless -nodsp)"); - run("techmap -map +/ecp5/dsp_map.v", "(unless -nodsp)"); + run("techmap -map +/mul2dsp.v -map +/ecp5/dsp_map.v -D DSP_A_MAXWIDTH=18 -D DSP_B_MAXWIDTH=18 -D DSP_A_MINWIDTH=2 -D DSP_B_MINWIDTH=2 -D DSP_NAME=$__MUL18X18", "(unless -nodsp)"); run("chtype -set $mul t:$__soft_mul", "(unless -nodsp)"); } run("alumacc");