aboutsummaryrefslogtreecommitdiffstats
path: root/src/synth/netlists-utils.adb
diff options
context:
space:
mode:
Diffstat (limited to 'src/synth/netlists-utils.adb')
-rw-r--r--src/synth/netlists-utils.adb7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/synth/netlists-utils.adb b/src/synth/netlists-utils.adb
index 43546e02a..43da83719 100644
--- a/src/synth/netlists-utils.adb
+++ b/src/synth/netlists-utils.adb
@@ -52,7 +52,12 @@ package body Netlists.Utils is
is
M : constant Module := Get_Module (Inst);
begin
- return Get_Nbr_Params (M);
+ case Get_Id (M) is
+ when Id_Const_Bit =>
+ return Param_Nbr ((Get_Width (Get_Output (Inst, 0)) + 31) / 32);
+ when others =>
+ return Get_Nbr_Params (M);
+ end case;
end Get_Nbr_Params;
function Get_Param_Desc