Cache clock edge event objects

This commit is contained in:
Alex Forencich
2021-12-03 19:06:43 -08:00
parent 3325568406
commit 2af7852006
12 changed files with 68 additions and 41 deletions

View File

@@ -81,9 +81,11 @@ class TB:
self.set_enable_generator(None)
async def _run_enable(self):
clock_edge_event = RisingEdge(self.dut.clk)
for val in self._enable_generator:
self.dut.mii_clk_en <= val
await RisingEdge(self.dut.clk)
await clock_edge_event
async def run_test(dut, payload_lengths=None, payload_data=None, ifg=12, enable_gen=None):