diff options
author | Tristan Gingold <tgingold@free.fr> | 2023-01-29 08:37:46 +0100 |
---|---|---|
committer | Tristan Gingold <tgingold@free.fr> | 2023-01-29 08:37:46 +0100 |
commit | e6ebb298fcb465f062099c0d10db1d828a339355 (patch) | |
tree | c2851f72fa74fc34e42cb433d19828dc65c8d42a /src/synth/synth-vhdl_oper.adb | |
parent | 8cb293a92214fa4fb46b15b0af0d1b6a0dae3546 (diff) | |
download | ghdl-e6ebb298fcb465f062099c0d10db1d828a339355.tar.gz ghdl-e6ebb298fcb465f062099c0d10db1d828a339355.tar.bz2 ghdl-e6ebb298fcb465f062099c0d10db1d828a339355.zip |
synth: handle bit reduction operators. Fix #2328
Diffstat (limited to 'src/synth/synth-vhdl_oper.adb')
-rw-r--r-- | src/synth/synth-vhdl_oper.adb | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/src/synth/synth-vhdl_oper.adb b/src/synth/synth-vhdl_oper.adb index d811d01f0..07b94fcb2 100644 --- a/src/synth/synth-vhdl_oper.adb +++ b/src/synth/synth-vhdl_oper.adb @@ -887,7 +887,8 @@ package body Synth.Vhdl_Oper is begin Error_Msg_Synth (Get_Caller_Instance (Syn_Inst), Expr, - "unhandled function: " & Iir_Predefined_Functions'Image (Def)); + "unhandled dyn operation: " + & Iir_Predefined_Functions'Image (Def)); return No_Valtyp; end Error_Unhandled; begin @@ -958,27 +959,33 @@ package body Synth.Vhdl_Oper is | Iir_Predefined_Ieee_Std_Logic_Signed_Abs_Slv => return Synth_Vec_Monadic (Id_Abs); - when Iir_Predefined_Ieee_1164_And_Suv + when Iir_Predefined_TF_Reduction_And + | Iir_Predefined_Ieee_1164_And_Suv | Iir_Predefined_Ieee_Numeric_Std_And_Sgn | Iir_Predefined_Ieee_Numeric_Std_And_Uns => return Synth_Vec_Reduce_Monadic (Id_Red_And); - when Iir_Predefined_Ieee_1164_Nand_Suv + when Iir_Predefined_TF_Reduction_Nand + | Iir_Predefined_Ieee_1164_Nand_Suv | Iir_Predefined_Ieee_Numeric_Std_Nand_Sgn | Iir_Predefined_Ieee_Numeric_Std_Nand_Uns => return Synth_Vec_Reduce_Monadic (Id_Red_And, True); - when Iir_Predefined_Ieee_1164_Or_Suv + when Iir_Predefined_TF_Reduction_Or + | Iir_Predefined_Ieee_1164_Or_Suv | Iir_Predefined_Ieee_Numeric_Std_Or_Sgn | Iir_Predefined_Ieee_Numeric_Std_Or_Uns => return Synth_Vec_Reduce_Monadic (Id_Red_Or); - when Iir_Predefined_Ieee_1164_Nor_Suv + when Iir_Predefined_TF_Reduction_Nor + | Iir_Predefined_Ieee_1164_Nor_Suv | Iir_Predefined_Ieee_Numeric_Std_Nor_Sgn | Iir_Predefined_Ieee_Numeric_Std_Nor_Uns => return Synth_Vec_Reduce_Monadic (Id_Red_Or, True); - when Iir_Predefined_Ieee_1164_Xor_Suv + when Iir_Predefined_TF_Reduction_Xor + | Iir_Predefined_Ieee_1164_Xor_Suv | Iir_Predefined_Ieee_Numeric_Std_Xor_Sgn | Iir_Predefined_Ieee_Numeric_Std_Xor_Uns => return Synth_Vec_Reduce_Monadic (Id_Red_Xor); - when Iir_Predefined_Ieee_1164_Xnor_Suv + when Iir_Predefined_TF_Reduction_Xnor + | Iir_Predefined_Ieee_1164_Xnor_Suv | Iir_Predefined_Ieee_Numeric_Std_Xnor_Sgn | Iir_Predefined_Ieee_Numeric_Std_Xnor_Uns => return Synth_Vec_Reduce_Monadic (Id_Red_Xor, True); |