-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
49 additions
and
7 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,8 +5,8 @@ | |
// Fabian Schuiki <[email protected]> | ||
|
||
/// An actual cache lookup. | ||
module snitch_icache_lookup_parallel #( | ||
parameter snitch_icache_pkg::config_t CFG = '0, | ||
module snitch_icache_lookup_parallel import snitch_icache_pkg::*; #( | ||
parameter config_t CFG = '0, | ||
/// Configuration input types for SRAMs used in implementation. | ||
parameter type sram_cfg_data_t = logic, | ||
parameter type sram_cfg_tag_t = logic | ||
|
@@ -16,6 +16,7 @@ module snitch_icache_lookup_parallel #( | |
|
||
input logic flush_valid_i, | ||
output logic flush_ready_o, | ||
output icache_l1_events_t icache_events_o, | ||
|
||
input logic [CFG.FETCH_AW-1:0] in_addr_i, | ||
input logic [CFG.ID_WIDTH-1:0] in_id_i, | ||
|
@@ -250,6 +251,17 @@ module snitch_icache_lookup_parallel #( | |
assign out_error_o = data_q.error; | ||
assign out_valid_o = buffer_valid; | ||
|
||
// ------------------ | ||
// Performance Events | ||
// ------------------ | ||
always_comb begin | ||
icache_events_o = '0; | ||
icache_events_o.l1_miss = valid_q & ~data_d.hit; | ||
icache_events_o.l1_hit = valid_q & data_d.hit; | ||
icache_events_o.l1_stall = in_valid_i & ~in_ready_o; | ||
icache_events_o.l1_handler_stall = out_valid_o & ~out_ready_i; | ||
end | ||
|
||
// Assertions | ||
`include "common_cells/assertions.svh" | ||
`ASSERT(i_rsp_buffer_ready, (valid_q |-> buffer_ready), clk_i, !rst_ni) | ||
|
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