Define fetchBytes in HasCoreParams, not Frontend
It is more generally useful.
This commit is contained in:
parent
2786e42d99
commit
7bcf28c585
@ -75,7 +75,6 @@ class FrontendModule(outer: Frontend) extends LazyModuleImp(outer)
|
|||||||
val icache = outer.icache.module
|
val icache = outer.icache.module
|
||||||
require(fetchWidth*coreInstBytes == outer.icacheParams.fetchBytes)
|
require(fetchWidth*coreInstBytes == outer.icacheParams.fetchBytes)
|
||||||
|
|
||||||
val fetchBytes = coreInstBytes * fetchWidth
|
|
||||||
val tlb = Module(new TLB(true, log2Ceil(fetchBytes), nTLBEntries))
|
val tlb = Module(new TLB(true, log2Ceil(fetchBytes), nTLBEntries))
|
||||||
val fq = withReset(reset || io.cpu.req.valid) { Module(new ShiftQueue(new FrontendResp, 5, flow = true)) }
|
val fq = withReset(reset || io.cpu.req.valid) { Module(new ShiftQueue(new FrontendResp, 5, flow = true)) }
|
||||||
|
|
||||||
|
@ -54,6 +54,7 @@ trait HasCoreParameters extends HasTileParameters {
|
|||||||
val fetchWidth = coreParams.fetchWidth
|
val fetchWidth = coreParams.fetchWidth
|
||||||
val decodeWidth = coreParams.decodeWidth
|
val decodeWidth = coreParams.decodeWidth
|
||||||
|
|
||||||
|
val fetchBytes = coreParams.fetchBytes
|
||||||
val coreInstBits = coreParams.instBits
|
val coreInstBits = coreParams.instBits
|
||||||
val coreInstBytes = coreInstBits/8
|
val coreInstBytes = coreInstBits/8
|
||||||
val coreDataBits = xLen max fLen
|
val coreDataBits = xLen max fLen
|
||||||
|
Loading…
Reference in New Issue
Block a user