From 4af6313288e6c7003583b66eedfcb297685f1f69 Mon Sep 17 00:00:00 2001 From: Matthew Naylor Date: Sun, 17 Jul 2016 22:28:18 +0100 Subject: [PATCH] TraceGen: Lookup -> MuxLookup A recent commit to tracegen.scala introduced a call to BitPat() which seems to mess up the subsequent call to Lookup(). (This function seems undocumented so I'm not sure what's going on.) As a fix, I've removed the call to BitPat() and replaced Lookup() with MuxLookup(). --- groundtest/src/main/scala/tracegen.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/groundtest/src/main/scala/tracegen.scala b/groundtest/src/main/scala/tracegen.scala index dd9ce022..f50bf990 100644 --- a/groundtest/src/main/scala/tracegen.scala +++ b/groundtest/src/main/scala/tracegen.scala @@ -144,14 +144,14 @@ class TagMan(val logNumTags : Int) extends Module { val inUse = List.fill(numTags)(Reg(init = Bool(false))) // Mapping from each tag to its 'inUse' bit - val inUseMap = (0 to numTags-1).map(i => BitPat(UInt(i))).zip(inUse) + val inUseMap = (0 to numTags-1).map(i => UInt(i)).zip(inUse) // Next tag to offer val nextTag = Reg(init = UInt(0, logNumTags)) io.tagOut := nextTag // Is the next tag available? - io.available := ~Lookup(nextTag, Bool(true), inUseMap) + io.available := ~MuxLookup(nextTag, Bool(true), inUseMap) // When user takes a tag when (io.take) {