aboutsummaryrefslogtreecommitdiffstats
path: root/src/synth/netlists-disp_vhdl.adb
diff options
context:
space:
mode:
Diffstat (limited to 'src/synth/netlists-disp_vhdl.adb')
-rw-r--r--src/synth/netlists-disp_vhdl.adb12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/synth/netlists-disp_vhdl.adb b/src/synth/netlists-disp_vhdl.adb
index 0f7418167..701d1f782 100644
--- a/src/synth/netlists-disp_vhdl.adb
+++ b/src/synth/netlists-disp_vhdl.adb
@@ -524,12 +524,14 @@ package body Netlists.Disp_Vhdl is
end;
when Id_Uextend =>
declare
- W : constant Width := Get_Width (Get_Output (Inst, 0));
+ Ow : constant Width := Get_Width (Get_Output (Inst, 0));
+ Iw : constant Width := Get_Width (Get_Input_Net (Inst, 0));
begin
- Disp_Template (" \o0 <= std_logic_vector (resize (\ui0, ",
- Inst);
- Put_Uns32 (W);
- Put_Line ("));");
+ pragma Assert (Iw > 0);
+ pragma Assert (Ow > Iw);
+ Disp_Template (" \o0 <= """, Inst);
+ Put ((1 .. Natural (Ow - Iw) => '0'));
+ Disp_Template (""" & \i0; -- uext" & NL, Inst);
end;
when others =>
Disp_Instance_Gate (Inst);