merge graphics
This commit is contained in:
@@ -26,7 +26,7 @@ class MultiPortQueueUnitTest extends AnyFlatSpec with ChiselScalatestTester {
|
||||
for (_ <- 0 until 100) {
|
||||
c.clock.step()
|
||||
}
|
||||
// c.io.deq(0).valid.expect(false.B)
|
||||
// c.io.deq(0).valid.expect(false.B)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -257,7 +257,7 @@ class CoalShiftQueueTest extends AnyFlatSpec with ChiselScalatestTester {
|
||||
}
|
||||
|
||||
it should "dequeue invalidated entries by itself" in {
|
||||
test(new CoalShiftQueue(UInt(8.W), 4)) { c =>
|
||||
test(new CoalShiftQueue(gen = UInt(8.W), entries = 4)) { c =>
|
||||
c.io.invalidate.valid.poke(false.B)
|
||||
|
||||
// prepare
|
||||
@@ -266,12 +266,10 @@ class CoalShiftQueueTest extends AnyFlatSpec with ChiselScalatestTester {
|
||||
c.io.queue.enq.valid.poke(true.B)
|
||||
c.io.queue.enq.bits.poke(0x12.U)
|
||||
c.clock.step()
|
||||
c.io.queue.deq.ready.poke(false.B)
|
||||
c.io.queue.enq.ready.expect(true.B)
|
||||
c.io.queue.enq.valid.poke(true.B)
|
||||
c.io.queue.enq.bits.poke(0x34.U)
|
||||
c.clock.step()
|
||||
c.io.queue.deq.ready.poke(false.B)
|
||||
c.io.queue.enq.ready.expect(true.B)
|
||||
c.io.queue.enq.valid.poke(true.B)
|
||||
c.io.queue.enq.bits.poke(0x56.U)
|
||||
@@ -281,12 +279,13 @@ class CoalShiftQueueTest extends AnyFlatSpec with ChiselScalatestTester {
|
||||
// invalidate two entries at head
|
||||
c.io.invalidate.valid.poke(true.B)
|
||||
c.io.invalidate.bits.poke(0x3.U)
|
||||
// [ 0x56 | 0x34(inv) | 0x12(inv) ]
|
||||
c.clock.step()
|
||||
// 0x12 should have been dequeued now
|
||||
// [ 0x56 | 0x34(inv) ]
|
||||
c.io.invalidate.valid.poke(false.B)
|
||||
c.io.queue.deq.ready.poke(false.B)
|
||||
c.clock.step()
|
||||
// 0x34 should have been dequeued now
|
||||
// [ 0x56 ]
|
||||
c.io.queue.deq.ready.poke(true.B)
|
||||
c.io.queue.deq.valid.expect(true.B)
|
||||
c.io.queue.deq.bits.expect(0x56.U)
|
||||
@@ -358,25 +357,26 @@ class UncoalescingUnitTest extends AnyFlatSpec with ChiselScalatestTester {
|
||||
// .withAnnotations(Seq(VcsBackendAnnotation))
|
||||
{ c =>
|
||||
val sourceId = 0.U
|
||||
val four = c.io.newEntry.sizeEnumT.FOUR
|
||||
c.io.coalReqValid.poke(true.B)
|
||||
c.io.newEntry.source.poke(sourceId)
|
||||
c.io.newEntry.lanes(0).reqs(0).valid.poke(true.B)
|
||||
c.io.newEntry.lanes(0).reqs(0).source.poke(1.U)
|
||||
c.io.newEntry.lanes(0).reqs(0).offset.poke(1.U)
|
||||
c.io.newEntry.lanes(0).reqs(0).sizeEnum.poke(1.U) // 1.U is FOUR
|
||||
c.io.newEntry.lanes(0).reqs(0).sizeEnum.poke(four)
|
||||
c.io.newEntry.lanes(0).reqs(1).valid.poke(true.B)
|
||||
c.io.newEntry.lanes(0).reqs(1).source.poke(2.U)
|
||||
c.io.newEntry.lanes(0).reqs(1).offset.poke(0.U)
|
||||
c.io.newEntry.lanes(0).reqs(1).sizeEnum.poke(1.U)
|
||||
c.io.newEntry.lanes(0).reqs(1).sizeEnum.poke(four)
|
||||
c.io.newEntry.lanes(1).reqs(0).valid.poke(false.B)
|
||||
c.io.newEntry.lanes(2).reqs(0).valid.poke(true.B)
|
||||
c.io.newEntry.lanes(2).reqs(0).source.poke(2.U)
|
||||
c.io.newEntry.lanes(2).reqs(0).offset.poke(2.U)
|
||||
c.io.newEntry.lanes(2).reqs(0).sizeEnum.poke(1.U)
|
||||
c.io.newEntry.lanes(2).reqs(0).sizeEnum.poke(four)
|
||||
c.io.newEntry.lanes(2).reqs(1).valid.poke(true.B)
|
||||
c.io.newEntry.lanes(2).reqs(1).source.poke(2.U)
|
||||
c.io.newEntry.lanes(2).reqs(1).offset.poke(3.U)
|
||||
c.io.newEntry.lanes(2).reqs(1).sizeEnum.poke(1.U)
|
||||
c.io.newEntry.lanes(2).reqs(1).sizeEnum.poke(four)
|
||||
c.io.newEntry.lanes(3).reqs(0).valid.poke(false.B)
|
||||
|
||||
c.clock.step()
|
||||
@@ -421,7 +421,13 @@ class CoalInflightTableUnitTest extends AnyFlatSpec with ChiselScalatestTester {
|
||||
val sizeBits = 2
|
||||
|
||||
val inflightCoalReqTableEntry =
|
||||
new InflightCoalReqTableEntry(numLanes, numPerLaneReqs, sourceWidth, offsetBits, sizeBits)
|
||||
new InflightCoalReqTableEntry(
|
||||
numLanes,
|
||||
numPerLaneReqs,
|
||||
sourceWidth,
|
||||
offsetBits,
|
||||
testConfig.SizeEnum
|
||||
)
|
||||
|
||||
// it should "stop enqueueing when full" in {
|
||||
// test(new InflightCoalReqTable(numLanes, sourceWidth, entries)) { c =>
|
||||
|
||||
Reference in New Issue
Block a user