Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integrate Instruction Cache towards external accesses #6

Open
wants to merge 8 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 7 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 24 additions & 8 deletions Bender.lock
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ packages:
dependencies:
- common_cells
axi:
revision: fccffb5953ec8564218ba05e20adbedec845e014
version: 0.39.1
revision: 587355b77b8ce94dcd600efbd5d5bd118ff913a7
version: 0.39.4
source:
Git: https://github.com/pulp-platform/axi.git
dependencies:
Expand Down Expand Up @@ -41,9 +41,19 @@ packages:
dependencies:
- common_cells
- register_interface
cluster_icache:
revision: 08608872a6fbd9e1d14a6f7726f2d663d464a910
version: null
source:
Git: https://github.com/pulp-platform/cluster_icache.git
dependencies:
- axi
- common_cells
- scm
- tech_cells_generic
common_cells:
revision: 2bd027cb87eaa9bf7d17196ec5f69864b35b630f
version: 1.32.0
revision: c27bce39ebb2e6bae52f60960814a2afca7bd4cb
version: 1.37.0
source:
Git: https://github.com/pulp-platform/common_cells.git
dependencies:
Expand Down Expand Up @@ -80,8 +90,8 @@ packages:
dependencies:
- common_cells
obi:
revision: d04f1706ba5b7731bbc0a3a085e725e29fcc5b8e
version: 0.1.1
revision: 5321106817e177d6c16ecc4daa922b96b1bc946b
version: 0.1.5
source:
Git: https://github.com/pulp-platform/obi.git
dependencies:
Expand All @@ -98,8 +108,8 @@ packages:
- register_interface
- tech_cells_generic
register_interface:
revision: d7693be4aef1fc7e7eb2b00b41c42e87d959866c
version: 0.4.2
revision: ae616e5a1ec2b41e72d200e5ab09c65e94aebd3d
version: 0.4.4
source:
Git: https://github.com/pulp-platform/register_interface.git
dependencies:
Expand All @@ -115,6 +125,12 @@ packages:
dependencies:
- common_cells
- tech_cells_generic
scm:
revision: 998466d2a3c2d7d572e43d2666d93c4f767d8d60
version: 1.1.1
source:
Git: https://github.com/pulp-platform/scm.git
dependencies: []
tech_cells_generic:
revision: 7968dd6e6180df2c644636bc6d2908a49f2190cf
version: 0.2.13
Expand Down
5 changes: 4 additions & 1 deletion Bender.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ package:

dependencies:
common_cells: { git: "https://github.com/pulp-platform/common_cells.git", version: 1.29.0 }
axi: { git: "https://github.com/pulp-platform/axi.git", version: 0.39.1 }
axi: { git: "https://github.com/pulp-platform/axi.git", version: 0.39.4 }
axi_riscv_atomics: { git: "https://github.com/pulp-platform/axi_riscv_atomics.git", version: 0.8.1 }
redundancy_cells: { git: "https://github.com/pulp-platform/redundancy_cells.git", rev: "6a011b6" } # `hmr-alt` branch
riscv-dbg: { git: "https://github.com/pulp-platform/riscv-dbg.git", version: 0.8.1 }
Expand All @@ -23,11 +23,13 @@ dependencies:
obi: { git: "https://github.com/pulp-platform/obi.git", version: 0.1.1 }
unbent: { git: "https://github.com/pulp-platform/unbent.git", version: 0.1.6 }
axi_obi: { path: "future/axi_obi" }
cluster_icache: { git: "https://github.com/pulp-platform/cluster_icache.git", rev: 08608872a6fbd9e1d14a6f7726f2d663d464a910 }

sources:
# Level 1
- rtl/safety_island_pkg.sv
- rtl/soc_ctrl/safety_soc_ctrl_reg_pkg.sv
- rtl/soc_ctrl/safety_soc_ctrl_icache_reg_pkg.sv
- target: carfield
files:
- rtl/safety_island_bootrom_carfield.sv
Expand All @@ -42,6 +44,7 @@ sources:
# Level 2
- rtl/safety_core_wrap.sv
- rtl/soc_ctrl/safety_soc_ctrl_reg_top.sv
- rtl/soc_ctrl/safety_soc_ctrl_icache_reg_top.sv
# Level 3
- rtl/safety_island_top.sv
- rtl/synth/safety_island_synth_pkg.sv
Expand Down
20 changes: 19 additions & 1 deletion rtl/safety_island_pkg.sv
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,8 @@ package safety_island_pkg;
// to the safety island
int unsigned NumMhpmCounters; // Number of performance
// counters implemented in CV32
bit UseICache; // Enable instruction cache for external
// memory regions for CV32
} safety_island_cfg_t;

localparam safety_island_cfg_t SafetyIslandDefaultConfig = '{
Expand Down Expand Up @@ -136,7 +138,8 @@ package safety_island_pkg;
UseZfinx: 1,
UseTCLS: 1,
NumInterrupts: 64,
NumMhpmCounters: 1
NumMhpmCounters: 1,
UseICache: 1
};

localparam int unsigned NumTimerInterrupts = 2*SafetyIslandDefaultConfig.NumTimers;
Expand All @@ -147,4 +150,19 @@ package safety_island_pkg;
// Cores do not support more than 2 outstanding transactions
localparam int unsigned AxiMaxOutTrans = 2;

// Cache configuration
// Number of lines in L0 - one for current, one for prefetch
localparam int unsigned ICacheL0LineCount = 2;
// Line Width
localparam int unsigned ICacheLineWidth = 128;
// Number of L1 lines
localparam int unsigned ICacheLineCount = 32;
// Number of cache ways
localparam int unsigned ICacheWayCount = 4;
// Serial lookup (tag then data)
localparam bit ICacheSerialLookup = 1'b1;
// Use standard cells for L1 tag
localparam bit ICacheL1TagScm = 1'b1;


endpackage
Loading
Loading