max-core-cycles: Add a +max-core-cycles PlusArg
This commit is contained in:
parent
41a2a03f90
commit
88332bd885
@ -702,6 +702,13 @@ class Rocket(implicit p: Parameters) extends CoreModule()(p)
|
||||
wb_reg_cinst, wb_reg_cinst)
|
||||
}
|
||||
|
||||
val max_core_cycles = PlusArg("max-core-cycles",
|
||||
default = 0,
|
||||
docstring = "Maximum Core Clock cycles simulation may run before timeout. Ignored if 0 (Default).")
|
||||
when (max_core_cycles > UInt(0)) {
|
||||
assert (csr.io.time < max_core_cycles, "Maximum Core Cycles reached.")
|
||||
}
|
||||
|
||||
def checkExceptions(x: Seq[(Bool, UInt)]) =
|
||||
(x.map(_._1).reduce(_||_), PriorityMux(x))
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user