diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/synth/netlists-builders.adb | 2 | ||||
-rw-r--r-- | src/synth/netlists-disp_vhdl.adb | 1 | ||||
-rw-r--r-- | src/synth/netlists-expands.adb | 5 |
3 files changed, 5 insertions, 3 deletions
diff --git a/src/synth/netlists-builders.adb b/src/synth/netlists-builders.adb index 99a7563fe..812679ef1 100644 --- a/src/synth/netlists-builders.adb +++ b/src/synth/netlists-builders.adb @@ -818,7 +818,6 @@ package body Netlists.Builders is function Build_Const_Z (Ctxt : Context_Acc; W : Width) return Net is - pragma Assert (W > 0); Inst : Instance; O : Net; begin @@ -1422,7 +1421,6 @@ package body Netlists.Builders is (Ctxt : Context_Acc; I : Net; Off, W : Width) return Net is Wd : constant Width := Get_Width (I); - pragma Assert (Wd /= No_Width); pragma Assert (W + Off <= Wd); Inst : Instance; O : Net; diff --git a/src/synth/netlists-disp_vhdl.adb b/src/synth/netlists-disp_vhdl.adb index 4bbaaef31..387665705 100644 --- a/src/synth/netlists-disp_vhdl.adb +++ b/src/synth/netlists-disp_vhdl.adb @@ -1082,7 +1082,6 @@ package body Netlists.Disp_Vhdl is Ow : constant Width := Get_Width (Get_Output (Inst, 0)); Iw : constant Width := Get_Width (Get_Input_Net (Inst, 0)); begin - pragma Assert (Iw > 0); pragma Assert (Ow > Iw); Disp_Template (" \o0 <= ", Inst); if Iw = 1 then diff --git a/src/synth/netlists-expands.adb b/src/synth/netlists-expands.adb index 37ff24bf7..09ff5d9c4 100644 --- a/src/synth/netlists-expands.adb +++ b/src/synth/netlists-expands.adb @@ -236,6 +236,11 @@ package body Netlists.Expands is J : Int32; Step : Int32; begin + if W = 0 then + Net_Arr (0) := Build_Const_UB32 (Ctxt, 1, 1); + return; + end if; + for I in reverse 0 .. W - 1 loop V1 := Build_Extract_Bit (Ctxt, Addr, I); V0 := Build_Monadic (Ctxt, Id_Not, V1); |