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
Fix for issue #456 #457
Fix for issue #456 #457
Conversation
silabs-oysteink
commented
May 24, 2023
- Changed when the counter for issued instructions are reset.
- Some logic that was used to reset counters (through ctrl_fsm.allow_dummy_instr) was instead moved to factor into dummy_insert_o without resetting the counter)
- Changed how we count instructions (counting when the first operation of an instruction goes from IF to ID, excluding pointers)
Refactored when dummies are allowed to insert and when the counter for issued instructions are reset. Signed-off-by: Oystein Knauserud <Oystein.Knauserud@silabs.com>
…ompletes with last_op. Signed-off-by: Oystein Knauserud <Oystein.Knauserud@silabs.com>
Signed-off-by: Oystein Knauserud <Oystein.Knauserud@silabs.com>
@@ -913,7 +913,9 @@ module cv32e40s_rvfi | |||
if (is_dummy_instr_wb_i) begin | |||
dummy_suppressed_intr <= in_trap[STAGE_WB] || dummy_suppressed_intr; | |||
end else begin | |||
dummy_suppressed_intr <= 1'b0; | |||
if (last_op_wb_i) begin |
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 needs explanation
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.
Added comments
@@ -676,17 +676,23 @@ module cv32e40s_if_stage import cv32e40s_pkg::*; | |||
generate | |||
if (DUMMY_INSTRUCTIONS) begin : gen_dummy_instr | |||
logic instr_issued; // Used to count issued instructions between dummy instructions | |||
assign instr_issued = if_valid_o && id_ready_i; | |||
|
|||
// Count instructions when first_op==1 to not count suboperations of sequences |
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.
Explain why it is important to use first_op as opposed to last_op
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.
Added explanation
Signed-off-by: Oystein Knauserud <Oystein.Knauserud@silabs.com>