mirror of
https://github.com/openhwgroup/cvw
synced 2025-02-11 06:05:49 +00:00
Make fetch_buffer enableable in configs
This commit is contained in:
parent
94e9e540d2
commit
35636723fb
@ -116,6 +116,9 @@ localparam logic VIRTMEM_SUPPORTED = 0;
|
||||
localparam logic VECTORED_INTERRUPTS_SUPPORTED = 0;
|
||||
localparam logic BIGENDIAN_SUPPORTED = 0;
|
||||
|
||||
// Fetch buffer configuration
|
||||
localparam logic FETCHBUFFER_SUPPORTED = 0;
|
||||
|
||||
// TLB configuration. Entries should be a power of 2
|
||||
localparam ITLB_ENTRIES = 32'd0;
|
||||
localparam DTLB_ENTRIES = 32'd0;
|
||||
|
||||
@ -116,6 +116,9 @@ localparam logic VIRTMEM_SUPPORTED = 1;
|
||||
localparam logic VECTORED_INTERRUPTS_SUPPORTED = 1;
|
||||
localparam logic BIGENDIAN_SUPPORTED = 1;
|
||||
|
||||
// Fetch buffer configuration
|
||||
localparam logic FETCHBUFFER_SUPPORTED = 1;
|
||||
|
||||
// TLB configuration. Entries should be a power of 2
|
||||
localparam ITLB_ENTRIES = 32'd32;
|
||||
localparam DTLB_ENTRIES = 32'd32;
|
||||
|
||||
@ -116,6 +116,9 @@ localparam logic VIRTMEM_SUPPORTED = 0;
|
||||
localparam logic VECTORED_INTERRUPTS_SUPPORTED = 1;
|
||||
localparam logic BIGENDIAN_SUPPORTED = 0;
|
||||
|
||||
// Fetch buffer configuration
|
||||
localparam logic FETCHBUFFER_SUPPORTED = 1;
|
||||
|
||||
// TLB configuration. Entries should be a power of 2
|
||||
localparam ITLB_ENTRIES = 32'd32;
|
||||
localparam DTLB_ENTRIES = 32'd32;
|
||||
|
||||
@ -116,6 +116,9 @@ localparam logic VIRTMEM_SUPPORTED = 0;
|
||||
localparam logic VECTORED_INTERRUPTS_SUPPORTED = 1;
|
||||
localparam logic BIGENDIAN_SUPPORTED = 0;
|
||||
|
||||
// Fetch buffer configuration
|
||||
localparam logic FETCHBUFFER_SUPPORTED = 1;
|
||||
|
||||
// TLB configuration. Entries should be a power of 2
|
||||
localparam ITLB_ENTRIES = 32'd0;
|
||||
localparam DTLB_ENTRIES = 32'd0;
|
||||
|
||||
@ -116,6 +116,9 @@ localparam logic VIRTMEM_SUPPORTED = 1;
|
||||
localparam logic VECTORED_INTERRUPTS_SUPPORTED = 1;
|
||||
localparam logic BIGENDIAN_SUPPORTED = 1;
|
||||
|
||||
// Fetch buffer configuration
|
||||
localparam logic FETCHBUFFER_SUPPORTED = 1;
|
||||
|
||||
// TLB configuration. Entries should be a power of 2
|
||||
localparam ITLB_ENTRIES = 32'd32;
|
||||
localparam DTLB_ENTRIES = 32'd32;
|
||||
|
||||
@ -116,6 +116,9 @@ localparam logic VIRTMEM_SUPPORTED = 0;
|
||||
localparam logic VECTORED_INTERRUPTS_SUPPORTED = 1;
|
||||
localparam logic BIGENDIAN_SUPPORTED = 0;
|
||||
|
||||
// Fetch buffer configuration
|
||||
localparam logic FETCHBUFFER_SUPPORTED = 1;
|
||||
|
||||
// TLB configuration. Entries should be a power of 2
|
||||
localparam ITLB_ENTRIES = 32'd0;
|
||||
localparam DTLB_ENTRIES = 32'd0;
|
||||
|
||||
@ -45,6 +45,7 @@ localparam cvw_t P = '{
|
||||
ICACHE_WAYSIZEINBYTES : ICACHE_WAYSIZEINBYTES,
|
||||
ICACHE_LINELENINBITS : ICACHE_LINELENINBITS,
|
||||
CACHE_SRAMLEN : CACHE_SRAMLEN,
|
||||
FETCHBUFFER_SUPPORTED : FETCHBUFFER_SUPPORTED,
|
||||
IDIV_BITSPERCYCLE : IDIV_BITSPERCYCLE,
|
||||
IDIV_ON_FPU : IDIV_ON_FPU,
|
||||
PMP_ENTRIES : PMP_ENTRIES,
|
||||
|
||||
@ -74,6 +74,9 @@ typedef struct packed {
|
||||
logic DCACHE_SUPPORTED;
|
||||
logic ICACHE_SUPPORTED;
|
||||
|
||||
// Fetch Buffer Configuration
|
||||
logic FETCHBUFFER_SUPPORTED;
|
||||
|
||||
// TLB configuration. Entries should be a power of 2
|
||||
int ITLB_ENTRIES;
|
||||
int DTLB_ENTRIES;
|
||||
|
||||
@ -303,9 +303,12 @@ module ifu import cvw::*; #(parameter cvw_t P) (
|
||||
assign IFUStallF = IFUCacheBusStallF | SelSpillNextF;
|
||||
assign GatedStallD = StallD & ~SelSpillNextF;
|
||||
|
||||
// flopenl #(32) AlignedInstrRawDFlop(clk, reset | FlushD, ~StallD, PostSpillInstrRawF, nop, InstrRawD);
|
||||
// TODO: Test this?!?!?!
|
||||
fetchbuffer #(P) fetchbuff(.clk, .reset, .StallF, .StallD, .FlushD, .WriteData(PostSpillInstrRawF), .ReadData(InstrRawD), .FetchBufferStallF); // Figure out what TODO with StallF
|
||||
if (P.FETCHBUFFER_SUPPORTED) begin : fetchbuffer
|
||||
fetchbuffer #(P) fetchbuff(.clk, .reset, .StallF, .StallD, .FlushD, .WriteData(PostSpillInstrRawF), .ReadData(InstrRawD), .FetchBufferStallF);
|
||||
end else begin
|
||||
flopenl #(32) AlignedInstrRawDFlop(clk, reset | FlushD, ~StallD, PostSpillInstrRawF, nop, InstrRawD);
|
||||
assign FetchBufferStallF = '0;
|
||||
end
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// PCNextF logic
|
||||
|
||||
Loading…
Reference in New Issue
Block a user