From: Luke Kenneth Casson Leighton Date: Thu, 21 Mar 2019 19:50:38 +0000 (+0000) Subject: reduce setup args to FPCorrections X-Git-Tag: ls180-24jan2020~1559 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=3b8bb3e86430a0994ee37ebdec0de063cc756394;p=ieee754fpu.git reduce setup args to FPCorrections --- diff --git a/src/add/nmigen_add_experiment.py b/src/add/nmigen_add_experiment.py index f89f4d63..4addd9c1 100644 --- a/src/add/nmigen_add_experiment.py +++ b/src/add/nmigen_add_experiment.py @@ -1268,8 +1268,8 @@ class FPNormToPack(FPState, FPID): # Rounding (chained to normalisation) rmod = FPRoundMod(self.width, self.id_wid) + rmod.setup(m, n_out) r_out_z = rmod.ospec() - rmod.setup(m, n_out.z, n_out.roundz) m.d.comb += r_out_z.eq(rmod.out_z) # Corrections (chained to rounding) @@ -1317,11 +1317,9 @@ class FPRoundMod: def ospec(self): return FPRoundData(self.width, self.id_wid) - def setup(self, m, in_z, roundz): + def setup(self, m, i): m.submodules.roundz = self - - m.d.comb += self.i.z.eq(in_z) - m.d.comb += self.i.roundz.eq(roundz) + m.d.comb += self.i.eq(i) def elaborate(self, platform): m = Module()