From: Eddie Hung Date: Fri, 6 Sep 2019 22:51:21 +0000 (-0700) Subject: Fix ffP just like ffPmux X-Git-Tag: working-ls180~1039^2~171 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=b69512a5b90a854a96b6e25bf4ccc567a7f89ad2;p=yosys.git Fix ffP just like ffPmux --- diff --git a/passes/pmgen/xilinx_dsp.pmg b/passes/pmgen/xilinx_dsp.pmg index 9e4738c88..7be841ff3 100644 --- a/passes/pmgen/xilinx_dsp.pmg +++ b/passes/pmgen/xilinx_dsp.pmg @@ -440,10 +440,10 @@ endmatch match ffP if !ffP_enable if param(dsp, \PREG).as_int() == 0 - // If ffMmux, input net must have exactly three users: ffMmux, ffM and ffP - if !ffMmux || nusers(sigP) == 3 - // Otherwise input net must have exactly two users: dsp and ffP - if ffMmux || nusers(sigP) == 2 + // If ffMmux and no postAdd new-value net must have exactly three users: ffMmux, ffM and ffPmux + if !ffMmux || postAdd || nusers(sigP) == 3 + // Otherwise new-value net must have exactly two users: dsp and ffPmux + if (ffMmux && !postAdd) || nusers(sigP) == 2 select ffP->type.in($dff) // DSP48E1 does not support clock inversion