-
Notifications
You must be signed in to change notification settings - Fork 230
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
Parameter and pinout cleanup: take2 #90
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -38,12 +38,36 @@ | |
/** | ||
* Module wrapper for CV32 RTL DUT. | ||
*/ | ||
module uvmt_cv32_dut_wrap #(parameter INSTR_RDATA_WIDTH = 128, | ||
RAM_ADDR_WIDTH = 20, | ||
PULP_SECURE = 1 | ||
module uvmt_cv32_dut_wrap #(// DUT (riscv_core) parameters. | ||
// https://github.com/openhwgroup/core-v-docs/blob/master/cores/cv32e40p/CV32E40P_and%20CV32E40_Features_Parameters.pdf | ||
parameter N_EXT_PERF_COUNTERS = 1, // TODO: this is 0 in riscv_core, which is wrong | ||
INSTR_RDATA_WIDTH = 128, | ||
PULP_SECURE = 0, | ||
N_PMP_ENTRIES = 16, | ||
USE_PMP = 1, //if PULP_SECURE is 1, you can still not use the PMP | ||
PULP_CLUSTER = 1, | ||
A_EXTENSION = 0, | ||
FPU = 0, | ||
Zfinx = 0, | ||
FP_DIVSQRT = 1, | ||
SHARED_FP = 0, | ||
SHARED_DSP_MULT = 0, | ||
SHARED_INT_MULT = 0, | ||
SHARED_INT_DIV = 0, | ||
SHARED_FP_DIVSQRT = 0, | ||
WAPUTYPE = 0, | ||
APU_NARGS_CPU = 3, | ||
APU_WOP_CPU = 6, | ||
APU_NDSFLAGS_CPU = 15, | ||
APU_NUSFLAGS_CPU = 5, | ||
DM_HaltAddress = 32'h1A110800, | ||
// Remaining parameters are used by TB components only | ||
INSTR_ADDR_WIDTH = 32, | ||
RAM_ADDR_WIDTH = 20 | ||
) | ||
|
||
( | ||
uvma_clknrst_if clknrst_if, | ||
uvma_clknrst_if clknrst_if, | ||
uvmt_cv32_vp_status_if vp_status_if, | ||
uvmt_cv32_core_cntrl_if core_cntrl_if, | ||
uvmt_cv32_core_status_if core_status_if, | ||
|
@@ -56,7 +80,7 @@ module uvmt_cv32_dut_wrap #(parameter INSTR_RDATA_WIDTH = 128, | |
logic instr_req; | ||
logic instr_gnt; | ||
logic instr_rvalid; | ||
logic [31:0] instr_addr; | ||
logic [INSTR_ADDR_WIDTH-1 :0] instr_addr; | ||
logic [INSTR_RDATA_WIDTH-1:0] instr_rdata; | ||
|
||
logic data_req; | ||
|
@@ -68,6 +92,8 @@ module uvmt_cv32_dut_wrap #(parameter INSTR_RDATA_WIDTH = 128, | |
logic [31:0] data_rdata; | ||
logic [31:0] data_wdata; | ||
|
||
logic [ 4:0] irq_id_out; | ||
logic [ 4:0] irq_id_in; | ||
|
||
// Load the Instruction Memory | ||
initial begin: load_instruction_memory | ||
|
@@ -100,9 +126,28 @@ module uvmt_cv32_dut_wrap #(parameter INSTR_RDATA_WIDTH = 128, | |
end | ||
|
||
// instantiate the core | ||
riscv_core #(.INSTR_RDATA_WIDTH (INSTR_RDATA_WIDTH), | ||
.PULP_SECURE (PULP_SECURE), | ||
.FPU (0) | ||
riscv_core #( | ||
.N_EXT_PERF_COUNTERS (N_EXT_PERF_COUNTERS), | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Wrong parameter list (riscv_core now only has PULP_CLUSTER |
||
.INSTR_RDATA_WIDTH (INSTR_RDATA_WIDTH), | ||
.PULP_SECURE (PULP_SECURE), | ||
.N_PMP_ENTRIES (N_PMP_ENTRIES), | ||
.USE_PMP (USE_PMP), | ||
.PULP_CLUSTER (PULP_CLUSTER), | ||
.A_EXTENSION (A_EXTENSION), | ||
.FPU (FPU), | ||
.Zfinx (Zfinx), | ||
.FP_DIVSQRT (FP_DIVSQRT), | ||
.SHARED_FP (SHARED_FP), | ||
.SHARED_DSP_MULT (SHARED_DSP_MULT), | ||
.SHARED_INT_MULT (SHARED_INT_MULT), | ||
.SHARED_INT_DIV (SHARED_INT_DIV), | ||
.SHARED_FP_DIVSQRT (SHARED_FP_DIVSQRT), | ||
.WAPUTYPE (WAPUTYPE), | ||
.APU_NARGS_CPU (APU_NARGS_CPU), | ||
.APU_WOP_CPU (APU_WOP_CPU), | ||
.APU_NDSFLAGS_CPU (APU_NDSFLAGS_CPU), | ||
.APU_NUSFLAGS_CPU (APU_NUSFLAGS_CPU), | ||
.DM_HaltAddress (DM_HaltAddress) | ||
) | ||
riscv_core_i | ||
( | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the wrong/old parameter list. In the updated cv32e40p we will only have the following parameters left: PULP_CLUSTER, FPU, PULP_ZFINX, DM_HALTADDRESS.