[rtl,CHERIoT] Properly track outstanding memory transactions assertions - #2502
Open
SamuelRiedel wants to merge 2 commits into
Open
SamuelRiedel wants to merge 2 commits into
SamuelRiedel wants to merge 2 commits into
Conversation
The CHERIoT clc/csc where not properly taken into account in this assertion, leading to false positives. Signed-off-by: Samuel Riedel <sriedel@lowrisc.org>
- Ensure a CHERIoT LSU request is mutually exclusive with other multicycle signals - Ensure the LSU doesn't issue any CHERIoT requests while the ID stage is stalled Signed-off-by: Samuel Riedel <sriedel@lowrisc.org>
gautschimi
reviewed
Sep 14, 2026
|
|
||
| // lsu_busy covers all non-IDLE states, but in WAIT_GNT the second grant hasn't been issued yet | ||
| // so no outstandng response can arrive there. | ||
| assign lsu_expecting_resp = lsu_busy & (load_store_unit_i.ls_fsm_cs != WAIT_GNT); |
Contributor
There was a problem hiding this comment.
lsu_expecting_resp is declared/assigned outside if (WritebackStage) but only ever read inside it. WritebackStage defaults to 0, so this looks like it'll be an unused-signal lint warning in that config unless CI only lints WritebackStage=1. Might want to move the declaration/assign inside the if (WritebackStage) block.
| (id_stage_i.lsu_req_dec | id_stage_i.cheriot_lsu_req_dec) & | ||
| id_stage_i.lsu_we; | ||
|
|
||
| // lsu_busy covers all non-IDLE states, but in WAIT_GNT the second grant hasn't been issued yet |
Contributor
There was a problem hiding this comment.
Not quite sure I understand this comment
|
|
||
| // lsu_busy covers all non-IDLE states, but in WAIT_GNT the second grant hasn't been issued yet | ||
| // so no outstandng response can arrive there. | ||
| assign lsu_expecting_resp = lsu_busy & (load_store_unit_i.ls_fsm_cs != WAIT_GNT); |
Contributor
There was a problem hiding this comment.
also load_store_unit_i.ls_fsm_cs is a hierarchical assignment. please avoid. lets route this condition out of the LSU
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
CHERIoT uses its own LSU request signals which were missing from some assertions tracking different LSU properties. This aligns the CHERIoT capability load/stores, which are two memory transactions, with the unaligned load/stores, which do the same. Simultaneously, we also fix a few edgecases, where the NoMemResponseWithoutPendingAccess could give false positives.