1
0

Fix bug introduced with Fuzzer when nOperations is power of 2 (#492)

This commit is contained in:
Jacob Chang 2016-12-15 19:10:53 -08:00 committed by Wesley W. Terpstra
parent 4471e0de27
commit c531093898

View File

@ -109,8 +109,8 @@ class TLFuzzer(
val dataBits = edge.bundle.dataBits val dataBits = edge.bundle.dataBits
// Progress through operations // Progress through operations
val num_reqs = Reg(init = UInt(nOperations, log2Up(nOperations))) val num_reqs = Reg(init = UInt(nOperations, log2Up(nOperations+1)))
val num_resps = Reg(init = UInt(nOperations, log2Up(nOperations))) val num_resps = Reg(init = UInt(nOperations, log2Up(nOperations+1)))
if (nOperations>0) { if (nOperations>0) {
io.finished := num_resps === UInt(0) io.finished := num_resps === UInt(0)
} else { } else {