asmicon/multiplexer: fix read tag delay
authorSebastien Bourdeauducq <sebastien@milkymist.org>
Tue, 15 May 2012 11:13:40 +0000 (13:13 +0200)
committerSebastien Bourdeauducq <sebastien@milkymist.org>
Tue, 15 May 2012 11:13:40 +0000 (13:13 +0200)
milkymist/asmicon/multiplexer.py

index 6b459262ac9cf1e1624c0445d10e95618292877f..d6f3f4aa4b32faf3e03ff01e77edd86d5ec49375 100644 (file)
@@ -120,9 +120,10 @@ class _Datapath:
                        )
                ]
                
-               rd_valid_d = [Signal() for i in range(self.timing_settings.rd_delay)]
-               rd_tag_d = [Signal(BV(tagbits)) for i in range(self.timing_settings.rd_delay)]
-               for i in range(self.timing_settings.rd_delay):
+               rd_delay = self.timing_settings.rd_delay + 1
+               rd_valid_d = [Signal() for i in range(rd_delay)]
+               rd_tag_d = [Signal(BV(tagbits)) for i in range(rd_delay)]
+               for i in range(rd_delay):
                        if i:
                                sync += [
                                        rd_valid_d[i].eq(rd_valid_d[i-1]),