maskwid=maskwid)
+class ALUProxy:
+ """ALUProxy: create a series of ALUs that look like the ALU being
+ sandwiched in between the fan-in and fan-out. One ALU looks like
+ it is multiple concurrent ALUs
+ """
+ def __init__(self, alu, p, n):
+ self.alu = alu
+ self.p = p
+ self.n = n
+
+
class ReservationStations(Elaboratable):
""" Reservation-Station pipeline
self.n = self.outpipe.n # use pipe in/out as this class in/out
self._ports = self.inpipe.ports() + self.outpipe.ports()
+ def set_alu(self, alu):
+ """set_alu: sets self.alu and also establishes a suite of pseudo-alus
+ that look to all pipeline-intents-and-purposes just like the original
+ """
+ self.alu, self.pseudoalus = alu, []
+ for i in range(num_rows):
+ self.pseudoalus.append(ALUProxy(alu, self.p[i], self.n[i]))
+
def elaborate(self, platform):
m = Module()
m.submodules.inpipe = self.inpipe