OpenCores
URL https://opencores.org/ocsvn/rv01_riscv_core/rv01_riscv_core/trunk

Subversion Repositories rv01_riscv_core

[/] [rv01_riscv_core/] [trunk/] [VHDL/] [RV01_types_pkg.vhd] - Blame information for rev 2

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 2 madsilicon
-----------------------------------------------------------------
2
--                                                             --
3
-----------------------------------------------------------------
4
--                                                             --
5
-- Copyright (C) 2015 Stefano Tonello                          --
6
--                                                             --
7
-- This source file may be used and distributed without        --
8
-- restriction provided that this copyright statement is not   --
9
-- removed from the file and that any derivative work contains --
10
-- the original copyright notice and the associated disclaimer.--
11
--                                                             --
12
-- THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY         --
13
-- EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED   --
14
-- TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS   --
15
-- FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL THE AUTHOR      --
16
-- OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,         --
17
-- INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES    --
18
-- (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE   --
19
-- GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR        --
20
-- BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF  --
21
-- LIABILITY, WHETHER IN  CONTRACT, STRICT LIABILITY, OR TORT  --
22
-- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT  --
23
-- OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE         --
24
-- POSSIBILITY OF SUCH DAMAGE.                                 --
25
--                                                             --
26
-----------------------------------------------------------------
27
 
28
---------------------------------------------------------------
29
-- RV01 constants package
30
---------------------------------------------------------------
31
 
32
library IEEE;
33
use IEEE.std_logic_1164.all;
34
use IEEE.numeric_std.all;
35
 
36
library WORK;
37
use WORK.RV01_CONSTS_PKG.all;
38
 
39
package RV01_TYPES_PKG is
40
 
41
  -- short (signed) data word type
42
  subtype SDWORD_T is signed(SDLEN-1 downto 0);
43
 
44
  -- long (signed) data word type
45
  subtype LDWORD_T is signed(LDLEN-1 downto 0);
46
 
47
  -- short unsigned data word type
48
  subtype SDWORDU_T is unsigned(SDLEN-1 downto 0);
49
 
50
  -- long unsigned data word type
51
  subtype LDWORDU_T is unsigned(LDLEN-1 downto 0);
52
 
53
  -- register identifier type
54
  subtype RID_T is integer range 0 to REGNUM-1;
55
 
56
  -- short shift amount type
57
  subtype SHORT_SHIFT_T is integer range 0 to SDLEN-1;
58
 
59
  -- long shift amount type
60
  subtype LONG_SHIFT_T is integer range 0 to LDLEN-1;
61
 
62
  subtype ADR_T is unsigned(ALEN-1 downto 0);
63
 
64
  type SDWORD_VEC_T is array (natural range<>) of SDWORD_T;
65
 
66
  type LDWORD_VEC_T is array (natural range<>) of LDWORD_T;
67
 
68
  type ADR_VEC_T is array (natural range<>) of ADR_T;
69
 
70
end package;
71
 
72
package body RV01_TYPES_PKG is
73
end package body;

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.