fix the mess introduced by "fix pipeline stage count"
authorJacob Lifshay <programmerjake@gmail.com>
Mon, 29 Jul 2019 14:13:03 +0000 (07:13 -0700)
committerJacob Lifshay <programmerjake@gmail.com>
Mon, 29 Jul 2019 14:16:00 +0000 (07:16 -0700)
not a pure revert
This reverts commit 30a3d1e975cd3df7ea701fdf0fe3bd0ba0757d3e.

src/ieee754/fpdiv/pipeline.py

index 3662b2154338ac734c22a2e73546406fb6f8d875..278e180431da7bcaa04b67f241aacf46bb5a495b 100644 (file)
@@ -163,6 +163,8 @@ class FPDIVMuxInOut(ReservationStations):
         fmt = FPFormat.standard(width)
         log2_radix = 3     # tested options so far: 1, 2 and 3.
 
+        n_comb_stages = 2  # 2 compute stages per pipeline stage
+
         fraction_width = fmt.fraction_width
 
         # extra bits needed: guard + round
@@ -173,8 +175,6 @@ class FPDIVMuxInOut(ReservationStations):
         # the last stage
         cfg = DivPipeCoreConfig(fmt.width, fraction_width, log2_radix)
 
-        n_comb_stages = (cfg.n_stages + 1) // 2  # 2 compute steps per stage
-
         self.pspec.fpformat = fmt
         self.pspec.n_comb_stages = n_comb_stages
         self.pspec.core_config = cfg