minor rtl edits (#948)

This commit is contained in:
stnolting 2024-07-10 21:13:29 +02:00 committed by GitHub
commit 792cc457c0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 142 additions and 125 deletions

View file

@ -29,6 +29,7 @@ mimpid = 0x01040312 -> Version 01.04.03.12 -> v1.4.3.12
| Date | Version | Comment | Ticket |
|:----:|:-------:|:--------|:------:|
| 10.07.2024 | 1.10.1.2 | minor rtl edits and cleanups | [#948](https://github.com/stnolting/neorv32/pull/948) |
| 05.07.2024 | 1.10.1.1 | minor rtl cleanups and optimizations | [#941](https://github.com/stnolting/neorv32/pull/941) |
| 04.07.2024 | [**:rocket:1.10.1**](https://github.com/stnolting/neorv32/releases/tag/v1.10.1) | **New release** | |
| 04.07.2024 | 1.10.0.10 | :warning: rework GPTMRM and remove capture mode | [#939](https://github.com/stnolting/neorv32/pull/939) |

View file

@ -21,7 +21,7 @@ use neorv32.neorv32_package.all;
entity neorv32_cpu_pmp is
generic (
NUM_REGIONS : natural range 0 to 16; -- number of regions (0..16)
GRANULARITY : natural range 4 to natural'high; -- minimal region granularity in bytes, has to be a power of 2, min 4 bytes
GRANULARITY : natural; -- minimal region granularity in bytes, has to be a power of 2, min 4 bytes
TOR_EN : boolean; -- implement TOR mode
NAP_EN : boolean -- implement NAPOT/NA4 modes
);

View file

@ -357,6 +357,7 @@ end neorv32_bus_gateway_rtl;
-- NEORV32 SoC - Processor Bus Infrastructure: IO Switch --
-- -------------------------------------------------------------------------------- --
-- Simple switch for accessing one out of several (IO) devices. --
-- Note: Enabled ports do not have to be contiguous. --
-- -------------------------------------------------------------------------------- --
-- The NEORV32 RISC-V Processor - https://github.com/stnolting/neorv32 --
-- Copyright (c) NEORV32 contributors. --
@ -376,76 +377,76 @@ entity neorv32_bus_io_switch is
generic (
DEV_SIZE : natural; -- size of a single IO device, has to be a power of two
-- device port enable and base address --
DEV_00_EN : boolean; DEV_00_BASE : std_ulogic_vector(31 downto 0);
DEV_01_EN : boolean; DEV_01_BASE : std_ulogic_vector(31 downto 0);
DEV_02_EN : boolean; DEV_02_BASE : std_ulogic_vector(31 downto 0);
DEV_03_EN : boolean; DEV_03_BASE : std_ulogic_vector(31 downto 0);
DEV_04_EN : boolean; DEV_04_BASE : std_ulogic_vector(31 downto 0);
DEV_05_EN : boolean; DEV_05_BASE : std_ulogic_vector(31 downto 0);
DEV_06_EN : boolean; DEV_06_BASE : std_ulogic_vector(31 downto 0);
DEV_07_EN : boolean; DEV_07_BASE : std_ulogic_vector(31 downto 0);
DEV_08_EN : boolean; DEV_08_BASE : std_ulogic_vector(31 downto 0);
DEV_09_EN : boolean; DEV_09_BASE : std_ulogic_vector(31 downto 0);
DEV_10_EN : boolean; DEV_10_BASE : std_ulogic_vector(31 downto 0);
DEV_11_EN : boolean; DEV_11_BASE : std_ulogic_vector(31 downto 0);
DEV_12_EN : boolean; DEV_12_BASE : std_ulogic_vector(31 downto 0);
DEV_13_EN : boolean; DEV_13_BASE : std_ulogic_vector(31 downto 0);
DEV_14_EN : boolean; DEV_14_BASE : std_ulogic_vector(31 downto 0);
DEV_15_EN : boolean; DEV_15_BASE : std_ulogic_vector(31 downto 0);
DEV_16_EN : boolean; DEV_16_BASE : std_ulogic_vector(31 downto 0);
DEV_17_EN : boolean; DEV_17_BASE : std_ulogic_vector(31 downto 0);
DEV_18_EN : boolean; DEV_18_BASE : std_ulogic_vector(31 downto 0);
DEV_19_EN : boolean; DEV_19_BASE : std_ulogic_vector(31 downto 0);
DEV_20_EN : boolean; DEV_20_BASE : std_ulogic_vector(31 downto 0);
DEV_21_EN : boolean; DEV_21_BASE : std_ulogic_vector(31 downto 0);
DEV_22_EN : boolean; DEV_22_BASE : std_ulogic_vector(31 downto 0);
DEV_23_EN : boolean; DEV_23_BASE : std_ulogic_vector(31 downto 0);
DEV_24_EN : boolean; DEV_24_BASE : std_ulogic_vector(31 downto 0);
DEV_25_EN : boolean; DEV_25_BASE : std_ulogic_vector(31 downto 0);
DEV_26_EN : boolean; DEV_26_BASE : std_ulogic_vector(31 downto 0);
DEV_27_EN : boolean; DEV_27_BASE : std_ulogic_vector(31 downto 0);
DEV_28_EN : boolean; DEV_28_BASE : std_ulogic_vector(31 downto 0);
DEV_29_EN : boolean; DEV_29_BASE : std_ulogic_vector(31 downto 0);
DEV_30_EN : boolean; DEV_30_BASE : std_ulogic_vector(31 downto 0);
DEV_31_EN : boolean; DEV_31_BASE : std_ulogic_vector(31 downto 0)
DEV_00_EN : boolean := false; DEV_00_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_01_EN : boolean := false; DEV_01_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_02_EN : boolean := false; DEV_02_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_03_EN : boolean := false; DEV_03_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_04_EN : boolean := false; DEV_04_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_05_EN : boolean := false; DEV_05_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_06_EN : boolean := false; DEV_06_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_07_EN : boolean := false; DEV_07_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_08_EN : boolean := false; DEV_08_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_09_EN : boolean := false; DEV_09_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_10_EN : boolean := false; DEV_10_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_11_EN : boolean := false; DEV_11_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_12_EN : boolean := false; DEV_12_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_13_EN : boolean := false; DEV_13_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_14_EN : boolean := false; DEV_14_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_15_EN : boolean := false; DEV_15_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_16_EN : boolean := false; DEV_16_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_17_EN : boolean := false; DEV_17_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_18_EN : boolean := false; DEV_18_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_19_EN : boolean := false; DEV_19_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_20_EN : boolean := false; DEV_20_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_21_EN : boolean := false; DEV_21_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_22_EN : boolean := false; DEV_22_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_23_EN : boolean := false; DEV_23_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_24_EN : boolean := false; DEV_24_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_25_EN : boolean := false; DEV_25_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_26_EN : boolean := false; DEV_26_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_27_EN : boolean := false; DEV_27_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_28_EN : boolean := false; DEV_28_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_29_EN : boolean := false; DEV_29_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_30_EN : boolean := false; DEV_30_BASE : std_ulogic_vector(31 downto 0) := (others => '-');
DEV_31_EN : boolean := false; DEV_31_BASE : std_ulogic_vector(31 downto 0) := (others => '-')
);
port (
-- host port --
main_req_i : in bus_req_t; -- host request
main_rsp_o : out bus_rsp_t; -- host response
-- device ports --
dev_00_req_o : out bus_req_t; dev_00_rsp_i : in bus_rsp_t;
dev_01_req_o : out bus_req_t; dev_01_rsp_i : in bus_rsp_t;
dev_02_req_o : out bus_req_t; dev_02_rsp_i : in bus_rsp_t;
dev_03_req_o : out bus_req_t; dev_03_rsp_i : in bus_rsp_t;
dev_04_req_o : out bus_req_t; dev_04_rsp_i : in bus_rsp_t;
dev_05_req_o : out bus_req_t; dev_05_rsp_i : in bus_rsp_t;
dev_06_req_o : out bus_req_t; dev_06_rsp_i : in bus_rsp_t;
dev_07_req_o : out bus_req_t; dev_07_rsp_i : in bus_rsp_t;
dev_08_req_o : out bus_req_t; dev_08_rsp_i : in bus_rsp_t;
dev_09_req_o : out bus_req_t; dev_09_rsp_i : in bus_rsp_t;
dev_10_req_o : out bus_req_t; dev_10_rsp_i : in bus_rsp_t;
dev_11_req_o : out bus_req_t; dev_11_rsp_i : in bus_rsp_t;
dev_12_req_o : out bus_req_t; dev_12_rsp_i : in bus_rsp_t;
dev_13_req_o : out bus_req_t; dev_13_rsp_i : in bus_rsp_t;
dev_14_req_o : out bus_req_t; dev_14_rsp_i : in bus_rsp_t;
dev_15_req_o : out bus_req_t; dev_15_rsp_i : in bus_rsp_t;
dev_16_req_o : out bus_req_t; dev_16_rsp_i : in bus_rsp_t;
dev_17_req_o : out bus_req_t; dev_17_rsp_i : in bus_rsp_t;
dev_18_req_o : out bus_req_t; dev_18_rsp_i : in bus_rsp_t;
dev_19_req_o : out bus_req_t; dev_19_rsp_i : in bus_rsp_t;
dev_20_req_o : out bus_req_t; dev_20_rsp_i : in bus_rsp_t;
dev_21_req_o : out bus_req_t; dev_21_rsp_i : in bus_rsp_t;
dev_22_req_o : out bus_req_t; dev_22_rsp_i : in bus_rsp_t;
dev_23_req_o : out bus_req_t; dev_23_rsp_i : in bus_rsp_t;
dev_24_req_o : out bus_req_t; dev_24_rsp_i : in bus_rsp_t;
dev_25_req_o : out bus_req_t; dev_25_rsp_i : in bus_rsp_t;
dev_26_req_o : out bus_req_t; dev_26_rsp_i : in bus_rsp_t;
dev_27_req_o : out bus_req_t; dev_27_rsp_i : in bus_rsp_t;
dev_28_req_o : out bus_req_t; dev_28_rsp_i : in bus_rsp_t;
dev_29_req_o : out bus_req_t; dev_29_rsp_i : in bus_rsp_t;
dev_30_req_o : out bus_req_t; dev_30_rsp_i : in bus_rsp_t;
dev_31_req_o : out bus_req_t; dev_31_rsp_i : in bus_rsp_t
dev_00_req_o : out bus_req_t; dev_00_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_01_req_o : out bus_req_t; dev_01_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_02_req_o : out bus_req_t; dev_02_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_03_req_o : out bus_req_t; dev_03_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_04_req_o : out bus_req_t; dev_04_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_05_req_o : out bus_req_t; dev_05_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_06_req_o : out bus_req_t; dev_06_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_07_req_o : out bus_req_t; dev_07_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_08_req_o : out bus_req_t; dev_08_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_09_req_o : out bus_req_t; dev_09_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_10_req_o : out bus_req_t; dev_10_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_11_req_o : out bus_req_t; dev_11_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_12_req_o : out bus_req_t; dev_12_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_13_req_o : out bus_req_t; dev_13_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_14_req_o : out bus_req_t; dev_14_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_15_req_o : out bus_req_t; dev_15_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_16_req_o : out bus_req_t; dev_16_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_17_req_o : out bus_req_t; dev_17_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_18_req_o : out bus_req_t; dev_18_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_19_req_o : out bus_req_t; dev_19_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_20_req_o : out bus_req_t; dev_20_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_21_req_o : out bus_req_t; dev_21_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_22_req_o : out bus_req_t; dev_22_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_23_req_o : out bus_req_t; dev_23_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_24_req_o : out bus_req_t; dev_24_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_25_req_o : out bus_req_t; dev_25_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_26_req_o : out bus_req_t; dev_26_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_27_req_o : out bus_req_t; dev_27_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_28_req_o : out bus_req_t; dev_28_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_29_req_o : out bus_req_t; dev_29_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_30_req_o : out bus_req_t; dev_30_rsp_i : in bus_rsp_t := rsp_terminate_c;
dev_31_req_o : out bus_req_t; dev_31_rsp_i : in bus_rsp_t := rsp_terminate_c
);
end neorv32_bus_io_switch;
@ -454,9 +455,9 @@ architecture neorv32_bus_io_switch_rtl of neorv32_bus_io_switch is
-- module configuration --
constant num_devs_c : natural := 32; -- number of device ports
-- address bits for access decoding --
constant abb_lo_c : natural := index_size_f(DEV_SIZE); -- low address boundary bit
constant abb_hi_c : natural := (index_size_f(DEV_SIZE) + index_size_f(num_devs_c)) - 1; -- high address boundary bit
-- address bit boundaries for access decoding --
constant addr_lo_c : natural := index_size_f(DEV_SIZE); -- low address boundary bit
constant addr_hi_c : natural := (index_size_f(DEV_SIZE) + index_size_f(num_devs_c)) - 1; -- high address boundary bit
-- list of enabled device ports --
type dev_en_list_t is array (0 to num_devs_c-1) of boolean;
@ -530,7 +531,7 @@ begin
bus_request: process(main_req_i)
begin
dev_req(i) <= main_req_i;
if (main_req_i.addr(abb_hi_c downto abb_lo_c) = dev_base_list_c(i)(abb_hi_c downto abb_lo_c)) then
if (main_req_i.addr(addr_hi_c downto addr_lo_c) = dev_base_list_c(i)(addr_hi_c downto addr_lo_c)) then
dev_req(i).stb <= main_req_i.stb; -- propagate transaction strobe if address match
else
dev_req(i).stb <= '0';

View file

@ -29,7 +29,7 @@ package neorv32_package is
-- Architecture Constants -----------------------------------------------------------------
-- -------------------------------------------------------------------------------------------
constant hw_version_c : std_ulogic_vector(31 downto 0) := x"01100101"; -- hardware version
constant hw_version_c : std_ulogic_vector(31 downto 0) := x"01100102"; -- hardware version
constant archid_c : natural := 19; -- official RISC-V architecture ID
constant XLEN : natural := 32; -- native data path width
@ -128,19 +128,19 @@ package neorv32_package is
addr : std_ulogic_vector(31 downto 0); -- access address
data : std_ulogic_vector(31 downto 0); -- write data
ben : std_ulogic_vector(3 downto 0); -- byte enable
stb : std_ulogic; -- request strobe (single-shot)
stb : std_ulogic; -- request strobe, single-shot
rw : std_ulogic; -- 0=read, 1=write
src : std_ulogic; -- access source (1=instruction fetch, 0=data access)
priv : std_ulogic; -- set if privileged (machine-mode) access
rvso : std_ulogic; -- set if reservation set operation (atomic LR/SC)
fence : std_ulogic; -- fence(.i) operation, independent of STB
fence : std_ulogic; -- set if fence(.i) operation, single-shot, independent of STB
end record;
-- bus response --
type bus_rsp_t is record
data : std_ulogic_vector(31 downto 0); -- read data
ack : std_ulogic; -- access acknowledge (single-shot)
err : std_ulogic; -- access error (single-shot)
data : std_ulogic_vector(31 downto 0); -- read data, valid if ack=1
ack : std_ulogic; -- access acknowledge, single-shot
err : std_ulogic; -- access error, single-shot
end record;
-- source (request) termination --
@ -737,7 +737,7 @@ package neorv32_package is
REGFILE_HW_RST : boolean := false;
-- Physical Memory Protection (PMP) --
PMP_NUM_REGIONS : natural range 0 to 16 := 0;
PMP_MIN_GRANULARITY : natural range 4 to 2**30 := 4;
PMP_MIN_GRANULARITY : natural := 4;
PMP_TOR_MODE_EN : boolean := true;
PMP_NAP_MODE_EN : boolean := true;
-- Hardware Performance Monitors (HPM) --

View file

@ -54,7 +54,7 @@ entity neorv32_top is
-- Physical Memory Protection (PMP) --
PMP_NUM_REGIONS : natural range 0 to 16 := 0; -- number of regions (0..16)
PMP_MIN_GRANULARITY : natural range 4 to 2**30 := 4; -- minimal region granularity in bytes, has to be a power of 2, min 4 bytes
PMP_MIN_GRANULARITY : natural := 4; -- minimal region granularity in bytes, has to be a power of 2, min 4 bytes
PMP_TOR_MODE_EN : boolean := true; -- implement TOR mode
PMP_NAP_MODE_EN : boolean := true; -- implement NAPOT/NA4 modes

View file

@ -53,7 +53,7 @@ set_property library neorv32 [get_files [glob $neorv32_home/rtl/core/*.vhd]]
set_property library neorv32 [get_files [glob $neorv32_home/rtl/core/mem/neorv32_*mem.default.vhd]]
set_property library neorv32 [get_files [glob $neorv32_home/rtl/system_integration/$rtl_top]]
set_property top $rtl_top [current_fileset]
##set_property top $rtl_top [current_fileset]
update_compile_order -fileset sources_1
@ -103,10 +103,12 @@ set_property tooltip {Max number of clock cycles before AXI access times ou
set_property display_name {AXI4-Lite cache (XBUS)} [ipgui::get_guiparamspec -name "XBUS_CACHE_EN" -component [ipx::current_core]]
set_property display_name {AXI4-Lite cache (XBUS) number of blocks} [ipgui::get_guiparamspec -name "XBUS_CACHE_NUM_BLOCKS" -component [ipx::current_core]]
set_property display_name {AXI4-Lite cache (XBUS) block size} [ipgui::get_guiparamspec -name "XBUS_CACHE_BLOCK_SIZE" -component [ipx::current_core]]
set_property tooltip {In bytes} [ipgui::get_guiparamspec -name "XBUS_CACHE_BLOCK_SIZE" -component [ipx::current_core]]
set_property tooltip {In bytes (use a power of two)} [ipgui::get_guiparamspec -name "XBUS_CACHE_BLOCK_SIZE" -component [ipx::current_core]]
set_property display_name {AXI4-Stream source and sink} [ipgui::get_guiparamspec -name "AXI4_STREAM_EN" -component [ipx::current_core]]
set_property display_name {AXI4-Stream input FIFO depth} [ipgui::get_guiparamspec -name "IO_SLINK_RX_FIFO" -component [ipx::current_core]]
set_property tooltip {Number of entries (use a power of two)} [ipgui::get_guiparamspec -name "IO_SLINK_RX_FIFO" -component [ipx::current_core]]
set_property display_name {AXI4-Stream output FIFO depth} [ipgui::get_guiparamspec -name "IO_SLINK_TX_FIFO" -component [ipx::current_core]]
set_property tooltip {Number of entries (use a power of two)} [ipgui::get_guiparamspec -name "IO_SLINK_TX_FIFO" -component [ipx::current_core]]
ipgui::add_group -name {General} -component [ipx::current_core] -parent [ipgui::get_pagespec -name "Page 0" -component [ipx::current_core]] -display_name {General}
ipgui::move_group -component [ipx::current_core] -order 0 [ipgui::get_groupspec -name "General" -component [ipx::current_core]] -parent [ipgui::get_pagespec -name "Page 0" -component [ipx::current_core]]
@ -126,45 +128,45 @@ ipgui::move_param -component [ipx::current_core] -order 10 [ipgui::get_guiparams
# **************************************************************
# Configuration GUI: CPU
# **************************************************************
set_property display_name {RISC-V A ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_A" -component [ipx::current_core]]
set_property tooltip {Atomic memory operations} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_A" -component [ipx::current_core]]
set_property display_name {RISC-V B ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_B" -component [ipx::current_core]]
set_property tooltip {Bit-manipulation operations} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_B" -component [ipx::current_core]]
set_property display_name {RISC-V C ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_C" -component [ipx::current_core]]
set_property tooltip {Compressed instructions} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_C" -component [ipx::current_core]]
set_property display_name {RISC-V E ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_E" -component [ipx::current_core]]
set_property tooltip {Reduced register file size (16 entries)} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_E" -component [ipx::current_core]]
set_property display_name {RISC-V M ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_M" -component [ipx::current_core]]
set_property tooltip {Integer multiplication and division hardware} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_M" -component [ipx::current_core]]
set_property display_name {RISC-V U ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_U" -component [ipx::current_core]]
set_property tooltip {Less-privileged user-mode} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_U" -component [ipx::current_core]]
set_property display_name {RISC-V Zfinx ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zfinx" -component [ipx::current_core]]
set_property tooltip {Embedded FPU} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zfinx" -component [ipx::current_core]]
set_property display_name {RISC-V Zihpm ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zihpm" -component [ipx::current_core]]
set_property tooltip {Hardware performance monitors (HPMs)} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zihpm" -component [ipx::current_core]]
set_property display_name {HPM counters} [ipgui::get_guiparamspec -name "HPM_NUM_CNTS" -component [ipx::current_core]]
set_property tooltip {Numer of total hardware performance monitor counters} [ipgui::get_guiparamspec -name "HPM_NUM_CNTS" -component [ipx::current_core]]
set_property display_name {HPM width} [ipgui::get_guiparamspec -name "HPM_CNT_WIDTH" -component [ipx::current_core]]
set_property tooltip {Counter width in bits} [ipgui::get_guiparamspec -name "HPM_CNT_WIDTH" -component [ipx::current_core]]
set_property display_name {RISC-V Zicntr ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zicntr" -component [ipx::current_core]]
set_property tooltip {Base counters (cycles and instructions)} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zicntr" -component [ipx::current_core]]
set_property display_name {RISC-V Zicond ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zicond" -component [ipx::current_core]]
set_property tooltip {Conditional move instructions} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zicond" -component [ipx::current_core]]
set_property display_name {RISC-V Zmmul ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zmmul" -component [ipx::current_core]]
set_property tooltip {Integer multiplication-only hardware} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zmmul" -component [ipx::current_core]]
set_property display_name {RISC-V Zxcfu ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zxcfu" -component [ipx::current_core]]
set_property tooltip {Custom-instructions unit} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zxcfu" -component [ipx::current_core]]
set_property display_name {DSP multiplier} [ipgui::get_guiparamspec -name "FAST_MUL_EN" -component [ipx::current_core]]
set_property display_name {Barrel shifter} [ipgui::get_guiparamspec -name "FAST_SHIFT_EN" -component [ipx::current_core]]
set_property display_name {FF-based register file with full HW reset} [ipgui::get_guiparamspec -name "REGFILE_HW_RST" -component [ipx::current_core]]
set_property display_name {PMP regions} [ipgui::get_guiparamspec -name "PMP_NUM_REGIONS" -component [ipx::current_core]]
set_property tooltip {Numer of total physical memory protection regions} [ipgui::get_guiparamspec -name "PMP_NUM_REGIONS" -component [ipx::current_core]]
set_property display_name {PMP minimal granularity} [ipgui::get_guiparamspec -name "PMP_MIN_GRANULARITY" -component [ipx::current_core]]
set_property tooltip {In bytes} [ipgui::get_guiparamspec -name "PMP_MIN_GRANULARITY" -component [ipx::current_core]]
set_property display_name {PMP TOR-mode enable} [ipgui::get_guiparamspec -name "PMP_TOR_MODE_EN" -component [ipx::current_core]]
set_property tooltip {Top-of-region} [ipgui::get_guiparamspec -name "PMP_TOR_MODE_EN" -component [ipx::current_core]]
set_property display_name {PMP NAP-mode enable} [ipgui::get_guiparamspec -name "PMP_NAP_MODE_EN" -component [ipx::current_core]]
set_property tooltip {Naturally-aligned-power-of-two} [ipgui::get_guiparamspec -name "PMP_NAP_MODE_EN" -component [ipx::current_core]]
set_property display_name {RISC-V A ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_A" -component [ipx::current_core]]
set_property tooltip {Atomic memory operations} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_A" -component [ipx::current_core]]
set_property display_name {RISC-V B ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_B" -component [ipx::current_core]]
set_property tooltip {Bit-manipulation operations} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_B" -component [ipx::current_core]]
set_property display_name {RISC-V C ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_C" -component [ipx::current_core]]
set_property tooltip {Compressed instructions} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_C" -component [ipx::current_core]]
set_property display_name {RISC-V E ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_E" -component [ipx::current_core]]
set_property tooltip {Reduced register file size (16 registers only)} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_E" -component [ipx::current_core]]
set_property display_name {RISC-V M ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_M" -component [ipx::current_core]]
set_property tooltip {Integer multiplication and division hardware} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_M" -component [ipx::current_core]]
set_property display_name {RISC-V U ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_U" -component [ipx::current_core]]
set_property tooltip {Less-privileged user-mode} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_U" -component [ipx::current_core]]
set_property display_name {RISC-V Zfinx ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zfinx" -component [ipx::current_core]]
set_property tooltip {Embedded FPU} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zfinx" -component [ipx::current_core]]
set_property display_name {RISC-V Zihpm ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zihpm" -component [ipx::current_core]]
set_property tooltip {Hardware performance monitors (HPMs)} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zihpm" -component [ipx::current_core]]
set_property display_name {HPM counters} [ipgui::get_guiparamspec -name "HPM_NUM_CNTS" -component [ipx::current_core]]
set_property tooltip {Numer of hardware performance monitor counters} [ipgui::get_guiparamspec -name "HPM_NUM_CNTS" -component [ipx::current_core]]
set_property display_name {HPM width} [ipgui::get_guiparamspec -name "HPM_CNT_WIDTH" -component [ipx::current_core]]
set_property tooltip {Counter width in bits} [ipgui::get_guiparamspec -name "HPM_CNT_WIDTH" -component [ipx::current_core]]
set_property display_name {RISC-V Zicntr ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zicntr" -component [ipx::current_core]]
set_property tooltip {Base counters (cycles and instructions)} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zicntr" -component [ipx::current_core]]
set_property display_name {RISC-V Zicond ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zicond" -component [ipx::current_core]]
set_property tooltip {Conditional-move instructions} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zicond" -component [ipx::current_core]]
set_property display_name {RISC-V Zmmul ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zmmul" -component [ipx::current_core]]
set_property tooltip {Integer multiplication-only hardware} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zmmul" -component [ipx::current_core]]
set_property display_name {NEORV32 Zxcfu ISA extension} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zxcfu" -component [ipx::current_core]]
set_property tooltip {Custom-instructions unit} [ipgui::get_guiparamspec -name "CPU_EXTENSION_RISCV_Zxcfu" -component [ipx::current_core]]
set_property display_name {DSP-based multiplier} [ipgui::get_guiparamspec -name "FAST_MUL_EN" -component [ipx::current_core]]
set_property display_name {Barrel shifter} [ipgui::get_guiparamspec -name "FAST_SHIFT_EN" -component [ipx::current_core]]
set_property display_name {FF-based register file with full HW reset} [ipgui::get_guiparamspec -name "REGFILE_HW_RST" -component [ipx::current_core]]
set_property display_name {PMP regions} [ipgui::get_guiparamspec -name "PMP_NUM_REGIONS" -component [ipx::current_core]]
set_property tooltip {Number of physical memory protection regions} [ipgui::get_guiparamspec -name "PMP_NUM_REGIONS" -component [ipx::current_core]]
set_property display_name {PMP minimal granularity} [ipgui::get_guiparamspec -name "PMP_MIN_GRANULARITY" -component [ipx::current_core]]
set_property tooltip {In bytes (min 4 bytes)} [ipgui::get_guiparamspec -name "PMP_MIN_GRANULARITY" -component [ipx::current_core]]
set_property display_name {PMP TOR-mode enable} [ipgui::get_guiparamspec -name "PMP_TOR_MODE_EN" -component [ipx::current_core]]
set_property tooltip {Top-of-region} [ipgui::get_guiparamspec -name "PMP_TOR_MODE_EN" -component [ipx::current_core]]
set_property display_name {PMP NAP-mode enable} [ipgui::get_guiparamspec -name "PMP_NAP_MODE_EN" -component [ipx::current_core]]
set_property tooltip {Naturally-aligned-power-of-two} [ipgui::get_guiparamspec -name "PMP_NAP_MODE_EN" -component [ipx::current_core]]
ipgui::add_group -name {CPU Configuration} -component [ipx::current_core] -parent [ipgui::get_pagespec -name "Page 0" -component [ipx::current_core]] -display_name {CPU Configuration}
ipgui::move_group -component [ipx::current_core] -order 1 [ipgui::get_groupspec -name "CPU Configuration" -component [ipx::current_core]] -parent [ipgui::get_pagespec -name "Page 0" -component [ipx::current_core]]
@ -196,25 +198,25 @@ ipgui::move_param -component [ipx::current_core] -order 20 [ipgui::get_guiparams
# **************************************************************
set_property display_name {Internal instruction memory (IMEM)} [ipgui::get_guiparamspec -name "MEM_INT_IMEM_EN" -component [ipx::current_core]]
set_property display_name {Internal instruction memory size} [ipgui::get_guiparamspec -name "MEM_INT_IMEM_SIZE" -component [ipx::current_core]]
set_property tooltip {In bytes} [ipgui::get_guiparamspec -name "MEM_INT_IMEM_SIZE" -component [ipx::current_core]]
set_property tooltip {In bytes (use a power of two)} [ipgui::get_guiparamspec -name "MEM_INT_IMEM_SIZE" -component [ipx::current_core]]
set_property display_name {Internal data memory (DMEM)} [ipgui::get_guiparamspec -name "MEM_INT_DMEM_EN" -component [ipx::current_core]]
set_property display_name {Internal data memory size} [ipgui::get_guiparamspec -name "MEM_INT_DMEM_SIZE" -component [ipx::current_core]]
set_property tooltip {In bytes} [ipgui::get_guiparamspec -name "MEM_INT_DMEM_SIZE" -component [ipx::current_core]]
set_property tooltip {In bytes (use a power of two)} [ipgui::get_guiparamspec -name "MEM_INT_DMEM_SIZE" -component [ipx::current_core]]
set_property display_name {CPU instruction cache (ICACHE)} [ipgui::get_guiparamspec -name "ICACHE_EN" -component [ipx::current_core]]
set_property display_name {CPU instruction cache (ICACHE) number of blocks} [ipgui::get_guiparamspec -name "ICACHE_NUM_BLOCKS" -component [ipx::current_core]]
set_property display_name {CPU instruction cache (ICACHE) block size} [ipgui::get_guiparamspec -name "ICACHE_BLOCK_SIZE" -component [ipx::current_core]]
set_property tooltip {In bytes} [ipgui::get_guiparamspec -name "ICACHE_BLOCK_SIZE" -component [ipx::current_core]]
set_property tooltip {In bytes (use a power of two)} [ipgui::get_guiparamspec -name "ICACHE_BLOCK_SIZE" -component [ipx::current_core]]
set_property display_name {CPU data cache (DCACHE)} [ipgui::get_guiparamspec -name "DCACHE_EN" -component [ipx::current_core]]
set_property display_name {CPU data cache (DCACHE) number of blocks} [ipgui::get_guiparamspec -name "DCACHE_NUM_BLOCKS" -component [ipx::current_core]]
set_property display_name {CPU data cache (DCACHE) block size} [ipgui::get_guiparamspec -name "DCACHE_BLOCK_SIZE" -component [ipx::current_core]]
set_property tooltip {In bytes} [ipgui::get_guiparamspec -name "DCACHE_BLOCK_SIZE" -component [ipx::current_core]]
set_property tooltip {In bytes (use a power of two)} [ipgui::get_guiparamspec -name "DCACHE_BLOCK_SIZE" -component [ipx::current_core]]
set_property display_name {Execute in-place module (XIP)} [ipgui::get_guiparamspec -name "XIP_EN" -component [ipx::current_core]]
set_property display_name {Execute in-place module (XIP) cache} [ipgui::get_guiparamspec -name "XIP_CACHE_EN" -component [ipx::current_core]]
set_property display_name {Execute in-place module (XIP) cache number of blocks} [ipgui::get_guiparamspec -name "XIP_CACHE_NUM_BLOCKS" -component [ipx::current_core]]
set_property display_name {Execute in-place module (XIP) cache block size} [ipgui::get_guiparamspec -name "XIP_CACHE_BLOCK_SIZE" -component [ipx::current_core]]
set_property tooltip {In bytes} [ipgui::get_guiparamspec -name "XIP_CACHE_BLOCK_SIZE" -component [ipx::current_core]]
set_property tooltip {In bytes (use a power of two)} [ipgui::get_guiparamspec -name "XIP_CACHE_BLOCK_SIZE" -component [ipx::current_core]]
set_property display_name {Internal bootloader} [ipgui::get_guiparamspec -name "INT_BOOTLOADER_EN" -component [ipx::current_core]]
set_property tooltip {Start UART bootloader after reset} [ipgui::get_guiparamspec -name "INT_BOOTLOADER_EN" -component [ipx::current_core]]
set_property tooltip {Start interactive bootloader console after reset} [ipgui::get_guiparamspec -name "INT_BOOTLOADER_EN" -component [ipx::current_core]]
ipgui::add_group -name {Memory System} -component [ipx::current_core] -parent [ipgui::get_pagespec -name "Page 0" -component [ipx::current_core]] -display_name {Memory System}
ipgui::move_group -component [ipx::current_core] -order 2 [ipgui::get_groupspec -name "Memory System" -component [ipx::current_core]] -parent [ipgui::get_pagespec -name "Page 0" -component [ipx::current_core]]
@ -244,26 +246,35 @@ set_property display_name {General-purpose outputs}
set_property display_name {Machine timer} [ipgui::get_guiparamspec -name "IO_MTIME_EN" -component [ipx::current_core]]
set_property display_name {Primary UART (UART0)} [ipgui::get_guiparamspec -name "IO_UART0_EN" -component [ipx::current_core]]
set_property display_name {Primary UART (UART0) RX FIFO depth} [ipgui::get_guiparamspec -name "IO_UART0_RX_FIFO" -component [ipx::current_core]]
set_property tooltip {Number of entries (use a power of two)} [ipgui::get_guiparamspec -name "IO_UART0_RX_FIFO" -component [ipx::current_core]]
set_property display_name {Primary UART (UART0) TX FIFO depth} [ipgui::get_guiparamspec -name "IO_UART0_TX_FIFO" -component [ipx::current_core]]
set_property tooltip {Number of entries (use a power of two)} [ipgui::get_guiparamspec -name "IO_UART0_TX_FIFO" -component [ipx::current_core]]
set_property display_name {Secondary UART (UART1)} [ipgui::get_guiparamspec -name "IO_UART1_EN" -component [ipx::current_core]]
set_property display_name {Secondary UART (UART1) RX FIFO depth} [ipgui::get_guiparamspec -name "IO_UART1_RX_FIFO" -component [ipx::current_core]]
set_property tooltip {Number of entries (use a power of two)} [ipgui::get_guiparamspec -name "IO_UART1_RX_FIFO" -component [ipx::current_core]]
set_property display_name {Secondary UART (UART1) TX FIFO depth} [ipgui::get_guiparamspec -name "IO_UART1_TX_FIFO" -component [ipx::current_core]]
set_property tooltip {Number of entries (use a power of two)} [ipgui::get_guiparamspec -name "IO_UART1_TX_FIFO" -component [ipx::current_core]]
set_property display_name {SPI} [ipgui::get_guiparamspec -name "IO_SPI_EN" -component [ipx::current_core]]
set_property display_name {SPI FIFO depth} [ipgui::get_guiparamspec -name "IO_SPI_FIFO" -component [ipx::current_core]]
set_property tooltip {Number of entries (use a power of two)} [ipgui::get_guiparamspec -name "IO_SPI_FIFO" -component [ipx::current_core]]
set_property display_name {SDI} [ipgui::get_guiparamspec -name "IO_SDI_EN" -component [ipx::current_core]]
set_property display_name {SDI FIFO depth} [ipgui::get_guiparamspec -name "IO_SDI_FIFO" -component [ipx::current_core]]
set_property tooltip {Number of entries (use a power of two)} [ipgui::get_guiparamspec -name "IO_SDI_FIFO" -component [ipx::current_core]]
set_property display_name {TWI} [ipgui::get_guiparamspec -name "IO_TWI_EN" -component [ipx::current_core]]
set_property display_name {TWI FIFO depth} [ipgui::get_guiparamspec -name "IO_TWI_FIFO" -component [ipx::current_core]]
set_property tooltip {Number of entries (use a power of two)} [ipgui::get_guiparamspec -name "IO_TWI_FIFO" -component [ipx::current_core]]
set_property display_name {PWM channels} [ipgui::get_guiparamspec -name "IO_PWM_NUM_CH" -component [ipx::current_core]]
set_property display_name {Watchdog} [ipgui::get_guiparamspec -name "IO_WDT_EN" -component [ipx::current_core]]
set_property display_name {TRNG} [ipgui::get_guiparamspec -name "IO_TRNG_EN" -component [ipx::current_core]]
set_property display_name {TRNG FIFO depth} [ipgui::get_guiparamspec -name "IO_TRNG_FIFO" -component [ipx::current_core]]
set_property tooltip {Number of entries (use a power of two)} [ipgui::get_guiparamspec -name "IO_TRNG_FIFO" -component [ipx::current_core]]
set_property display_name {Custom Functions Subsystem (CFU)} [ipgui::get_guiparamspec -name "IO_CFS_EN" -component [ipx::current_core]]
set_property display_name {Custom Functions Subsystem (CFU) configuration string} [ipgui::get_guiparamspec -name "IO_CFS_CONFIG" -component [ipx::current_core]]
set_property display_name {Custom Functions Subsystem (CFU) input port width} [ipgui::get_guiparamspec -name "IO_CFS_IN_SIZE" -component [ipx::current_core]]
set_property display_name {Custom Functions Subsystem (CFU) output port width} [ipgui::get_guiparamspec -name "IO_CFS_OUT_SIZE" -component [ipx::current_core]]
set_property display_name {NEOLED} [ipgui::get_guiparamspec -name "IO_NEOLED_EN" -component [ipx::current_core]]
set_property display_name {NEOLED FIFO depth} [ipgui::get_guiparamspec -name "IO_NEOLED_TX_FIFO" -component [ipx::current_core]]
set_property tooltip {Number of entries (use a power of two)} [ipgui::get_guiparamspec -name "IO_NEOLED_TX_FIFO" -component [ipx::current_core]]
set_property display_name {General Purpose Timer (GPTM)} [ipgui::get_guiparamspec -name "IO_GPTMR_EN" -component [ipx::current_core]]
set_property display_name {ONEWIRE} [ipgui::get_guiparamspec -name "IO_ONEWIRE_EN" -component [ipx::current_core]]
set_property display_name {DMA controller} [ipgui::get_guiparamspec -name "IO_DMA_EN" -component [ipx::current_core]]
@ -327,4 +338,8 @@ ipx::save_core [ipx::current_core]
set_property ip_repo_paths $cur_dir/$outputdir/packaged_ip [current_project]
update_ip_catalog
# **************************************************************
# Close temporary IP-building project
# **************************************************************
close_project

View file

@ -53,7 +53,7 @@ entity neorv32_vivado_ip is
REGFILE_HW_RST : boolean := false;
-- Physical Memory Protection (PMP) --
PMP_NUM_REGIONS : natural range 0 to 16 := 0;
PMP_MIN_GRANULARITY : natural range 4 to 2**30 := 4;
PMP_MIN_GRANULARITY : natural := 4;
PMP_TOR_MODE_EN : boolean := false;
PMP_NAP_MODE_EN : boolean := false;
-- Hardware Performance Monitors (HPM) --