aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2019-11-27 20:22:37 +0100
committerTristan Gingold <tgingold@free.fr>2019-11-27 20:22:37 +0100
commitbc668ed6d2f12408bab169fde7fb560560271358 (patch)
tree8ddd13f3b3c1623f669457ef2671d4488ccd806c
parenta7096101e26bb6f73d252cfaa153c096ff3d6af9 (diff)
downloadghdl-bc668ed6d2f12408bab169fde7fb560560271358.tar.gz
ghdl-bc668ed6d2f12408bab169fde7fb560560271358.tar.bz2
ghdl-bc668ed6d2f12408bab169fde7fb560560271358.zip
netlists-disp_vhdl: handle UB32 in Disp_Const_Bit. Fix #1039
-rw-r--r--src/synth/netlists-disp_vhdl.adb8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/synth/netlists-disp_vhdl.adb b/src/synth/netlists-disp_vhdl.adb
index 77ee517e6..4247c4390 100644
--- a/src/synth/netlists-disp_vhdl.adb
+++ b/src/synth/netlists-disp_vhdl.adb
@@ -379,6 +379,14 @@ package body Netlists.Disp_Vhdl is
Zx := 0;
Val := Get_Param_Uns32 (Inst, Param_Idx (Off / 32));
Val := Shift_Right (Val, Natural (Off mod 32)) and 1;
+ when Id_Const_UB32 =>
+ Zx := 0;
+ if Off < 32 then
+ Val := Get_Param_Uns32 (Inst, 0);
+ else
+ Val := 0;
+ end if;
+ Val := Shift_Right (Val, Natural (Off mod 32)) and 1;
when others =>
raise Internal_Error;
end case;