Get it to compile at least
This commit is contained in:
27
src/application_wrapper/cache/application_wrapper_cache_lru.sv
vendored
Normal file
27
src/application_wrapper/cache/application_wrapper_cache_lru.sv
vendored
Normal file
@@ -0,0 +1,27 @@
|
||||
module application_wrapper_cache_lru #(
|
||||
// This should be NUM_WAYS - 1
|
||||
parameter LRU_W = 3,
|
||||
parameter NUM_SETS = 64
|
||||
) (
|
||||
input logic [INDEX_W-1:0] i_read_index,
|
||||
input logic i_read_valid,
|
||||
output logic [LRU_W-1:0] o_read_data,
|
||||
|
||||
input logic [INDEX_W-1:0] i_write_index,
|
||||
input logic i_write_valid,
|
||||
input logic [LRU_W-1:0] i_write_data
|
||||
);
|
||||
|
||||
logic [LRU_W-1:0] lru_array [NUM_SETS];
|
||||
|
||||
always @(posedge i_clk) begin
|
||||
if (i_write_valid) begin
|
||||
lru_array[i_write_index] = i_write_data;
|
||||
end
|
||||
|
||||
if (i_read_valid) begin
|
||||
o_read_data = lru_array[i_read_index];
|
||||
end
|
||||
end
|
||||
|
||||
endmodule
|
||||
Reference in New Issue
Block a user