From e74d7f989871e968b5ab31d6f50c7e2b2bc787b5 Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Tue, 14 Apr 2020 18:25:33 +0100 Subject: [PATCH] add fu-fu multi-rd/wr dep cell --- src/soc/scoreboard/fu_dep_cell_multi.py | 125 ++++++++++++++++++++++++ 1 file changed, 125 insertions(+) create mode 100644 src/soc/scoreboard/fu_dep_cell_multi.py diff --git a/src/soc/scoreboard/fu_dep_cell_multi.py b/src/soc/scoreboard/fu_dep_cell_multi.py new file mode 100644 index 00000000..4643f3c2 --- /dev/null +++ b/src/soc/scoreboard/fu_dep_cell_multi.py @@ -0,0 +1,125 @@ +from nmigen.compat.sim import run_simulation +from nmigen.cli import verilog, rtlil +from nmigen import Module, Signal, Const, Elaboratable, Array +from nmutil.latch import SRLatch + +from functools import reduce +from operator import or_ + + +class FUDependenceCell(Elaboratable): + """ implements 11.4.7 mitch alsup dependence cell, p27 + """ + def __init__(self, dummy, n_fu, n_src, n_dest): + self.n_fu = n_fu + self.n_src = n_src + self.n_dest = n_dest + self.dummy = Const(~(1<