1
0

tilelink2 Buffer: support an unlimited number of channels

This commit is contained in:
Wesley W. Terpstra 2016-09-09 11:08:39 -07:00
parent 395bc16da6
commit 5604049927

View File

@ -15,14 +15,11 @@ class TLBuffer(entries: Int = 2, pipe: Boolean = false) extends LazyModule
val out = node.bundleOut val out = node.bundleOut
} }
val in = io.in(0) ((io.in zip io.out) zip (node.edgesIn zip node.edgesOut)) foreach { case ((in, out), (edgeIn, edgeOut)) =>
val out = io.out(0)
out.a <> Queue(in .a, entries, pipe) out.a <> Queue(in .a, entries, pipe)
in .d <> Queue(out.d, entries, pipe) in .d <> Queue(out.d, entries, pipe)
val edge = node.edgesOut(0) // same as edgeIn(0) if (edgeOut.manager.anySupportAcquire && edgeOut.client.anySupportProbe) {
if (edge.manager.anySupportAcquire && edge.client.anySupportProbe) {
in .b <> Queue(out.b, entries, pipe) in .b <> Queue(out.b, entries, pipe)
out.c <> Queue(in .c, entries, pipe) out.c <> Queue(in .c, entries, pipe)
out.e <> Queue(out.e, entries, pipe) out.e <> Queue(out.e, entries, pipe)
@ -36,6 +33,7 @@ class TLBuffer(entries: Int = 2, pipe: Boolean = false) extends LazyModule
} }
} }
} }
}
object TLBuffer object TLBuffer
{ {