From e4efd609757cc9c303e3a27f421f5b75f551e5d2 Mon Sep 17 00:00:00 2001 From: Tristan Gingold Date: Wed, 22 Apr 2020 18:53:39 +0200 Subject: testsuite/synth: add a test for #1254 --- testsuite/synth/issue1254/simple01.vhdl | 17 +++++++++++++++++ testsuite/synth/issue1254/simple02.vhdl | 17 +++++++++++++++++ testsuite/synth/issue1254/testsuite.sh | 15 +++++++++++++++ 3 files changed, 49 insertions(+) create mode 100644 testsuite/synth/issue1254/simple01.vhdl create mode 100644 testsuite/synth/issue1254/simple02.vhdl create mode 100755 testsuite/synth/issue1254/testsuite.sh (limited to 'testsuite/synth/issue1254') diff --git a/testsuite/synth/issue1254/simple01.vhdl b/testsuite/synth/issue1254/simple01.vhdl new file mode 100644 index 000000000..a0785240f --- /dev/null +++ b/testsuite/synth/issue1254/simple01.vhdl @@ -0,0 +1,17 @@ +library ieee; +use ieee.std_logic_1164.all; + +entity simple01 is + port (a : in std_logic; + z : out std_logic); +end simple01; + +--use work.pkg.all; + +architecture behav of simple01 is +begin + process(A) + begin + Z <= a; + end process; +end behav; diff --git a/testsuite/synth/issue1254/simple02.vhdl b/testsuite/synth/issue1254/simple02.vhdl new file mode 100644 index 000000000..01255409a --- /dev/null +++ b/testsuite/synth/issue1254/simple02.vhdl @@ -0,0 +1,17 @@ +library ieee; +use ieee.std_logic_1164.all; + +entity simple01 is + port (a : in std_logic; + z : out std_logic); +end simple01; + +--use work.pkg.all; + +architecture behav of simple01 is +begin + process(A) + begin + Z <= not a; + end process; +end behav; diff --git a/testsuite/synth/issue1254/testsuite.sh b/testsuite/synth/issue1254/testsuite.sh new file mode 100755 index 000000000..c12d2864e --- /dev/null +++ b/testsuite/synth/issue1254/testsuite.sh @@ -0,0 +1,15 @@ +#! /bin/sh + +. ../../testenv.sh + +cp simple01.vhdl simple.vhdl +analyze simple.vhdl + +cp simple02.vhdl simple.vhdl +if $GHDL --synth 2>&1 | grep "Bug occurred"; then + exit 1 +fi + +clean + +echo "Test successful" -- cgit v1.2.3