diff options
author | Tristan Gingold <tgingold@free.fr> | 2020-03-07 08:07:49 +0100 |
---|---|---|
committer | Tristan Gingold <tgingold@free.fr> | 2020-03-07 08:07:49 +0100 |
commit | 8795c9031088fa5c9e5514bbce804bffd9ed6d6b (patch) | |
tree | 200f0969f9474769407b435e90e0f2d8e0a112a1 | |
parent | c5a2e37aaa5e8c9680135a06af8a0fa6d6c38956 (diff) | |
download | ghdl-8795c9031088fa5c9e5514bbce804bffd9ed6d6b.tar.gz ghdl-8795c9031088fa5c9e5514bbce804bffd9ed6d6b.tar.bz2 ghdl-8795c9031088fa5c9e5514bbce804bffd9ed6d6b.zip |
testsuite/synth: add a test for #1153
-rw-r--r-- | testsuite/synth/issue1153/ent.vhdl | 14 | ||||
-rwxr-xr-x | testsuite/synth/issue1153/testsuite.sh | 8 | ||||
-rw-r--r-- | testsuite/testenv.sh | 7 |
3 files changed, 29 insertions, 0 deletions
diff --git a/testsuite/synth/issue1153/ent.vhdl b/testsuite/synth/issue1153/ent.vhdl new file mode 100644 index 000000000..59ec87a09 --- /dev/null +++ b/testsuite/synth/issue1153/ent.vhdl @@ -0,0 +1,14 @@ +library ieee; +use ieee.std_logic_1164.all; + +entity ent is + port ( + a, b : in std_logic; + q : out std_logic + ); +end; + +architecture a of ent is +begin + q <= a xnor b; +end; diff --git a/testsuite/synth/issue1153/testsuite.sh b/testsuite/synth/issue1153/testsuite.sh new file mode 100755 index 000000000..c666942d3 --- /dev/null +++ b/testsuite/synth/issue1153/testsuite.sh @@ -0,0 +1,8 @@ +#! /bin/sh + +. ../../testenv.sh + +synth_analyze ent +clean + +echo "Test successful" diff --git a/testsuite/testenv.sh b/testsuite/testenv.sh index 9ae7197dc..93009984b 100644 --- a/testsuite/testenv.sh +++ b/testsuite/testenv.sh @@ -109,6 +109,13 @@ synth() "$GHDL" --synth $GHDL_STD_FLAGS $GHDL_FLAGS $@ } +# Synthesis of a single file and analyze the result +synth_analyze() +{ + synth $1.vhdl -e > syn_$1.vhdl + analyze syn_$1.vhdl +} + # Check if a feature is present ghdl_has_feature () { |