diff options
| author | Tristan Gingold <tgingold@free.fr> | 2019-03-13 19:53:30 +0100 | 
|---|---|---|
| committer | Tristan Gingold <tgingold@free.fr> | 2019-03-14 07:14:44 +0100 | 
| commit | aec70e17120c4ee3d949263621286dfd650d3df2 (patch) | |
| tree | 906a10d8f5123df074ab97d1e7af12cfcfd04aea | |
| parent | b4e20d8af1e23ab124a2f42d7eb56e86aa7850aa (diff) | |
| download | ghdl-aec70e17120c4ee3d949263621286dfd650d3df2.tar.gz ghdl-aec70e17120c4ee3d949263621286dfd650d3df2.tar.bz2 ghdl-aec70e17120c4ee3d949263621286dfd650d3df2.zip | |
Add testcase for #779
| -rwxr-xr-x | testsuite/gna/issue779/testsuite.sh | 9 | ||||
| -rw-r--r-- | testsuite/gna/issue779/tvm_pkg.vhdl | 66 | 
2 files changed, 75 insertions, 0 deletions
| diff --git a/testsuite/gna/issue779/testsuite.sh b/testsuite/gna/issue779/testsuite.sh new file mode 100755 index 000000000..dbbd44243 --- /dev/null +++ b/testsuite/gna/issue779/testsuite.sh @@ -0,0 +1,9 @@ +#! /bin/sh + +. ../../testenv.sh + +$GHDL -s --expect-failure --std=08 tvm_pkg.vhdl + +clean + +echo "Test successful" diff --git a/testsuite/gna/issue779/tvm_pkg.vhdl b/testsuite/gna/issue779/tvm_pkg.vhdl new file mode 100644 index 000000000..fe32ea90b --- /dev/null +++ b/testsuite/gna/issue779/tvm_pkg.vhdl @@ -0,0 +1,66 @@ +library ieee; +use ieee.std_logic_1164.all; + +library ipbus; + + +package ipbus_tvm_pkg is + +  --=============================================================================================== +  -- Types and constants for IPbus TVM +  --=============================================================================================== +  constant C_SCOPE : string := "IPbus TVM"; + +  type t_ipbus_transaction_type_id is ( +    READ, +    WRITE, +    NON_INC_READ,    -- Non-incrementing read +    NON_INC_WRITE,   -- Non-incrementing write +    RMW_BITS,        -- Read/modify/write bits +    RMW_SUM,         -- Read/modify/write sum +    CONF_SPACE_READ, -- Configuration space read +    CONF_SPACE_WRITE -- Configuration space write +  ); + +  type t_ipbus_transaction_info_code is ( +    REQ_HANDLED_SUCCESSFULLY, -- Request handled successfully by target +    BAD_HEADER, +    RESERVED_0x2, +    RESERVED_0x3, +    BUS_ERROR_ON_READ, +    BUS_ERROR_ON_WRITE, +    BUS_TIMEOUT_ON_READ, +    BUS_TIMEOUT_ON_WRITE, +    RESERVED_0x8, +    RESERVED_0x9, +    RESERVED_0xA, +    RESERVED_0xB, +    RESERVED_0xC, +    RESERVED_0xD, +    RESERVED_0xE, +    OUTBOUND_REQUEST +  ); + +  type t_ipbus_tranaction_header is +  record +    protocol_version : natural; +    transaction_id   : natural; +    words            : natural; +    type_id          : t_ipbus_transaction_type_id; +    info_code        : t_ipbus_transaction_info_code; +  end record; + +  type t_ipbus_transaction is +  record +    header : t_ipbus_tranaction_header; +    _body  : t_slv_array; +  end record; + +end package ipbus_tvm_pkg; + +--================================================================================================= +--================================================================================================= + +package body ipbus_tvm_pkg is + +end package body ipbus_tvm_pkg; | 
