rename fp div classes and submodule
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Sat, 17 Aug 2019 04:24:38 +0000 (05:24 +0100)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Sat, 17 Aug 2019 04:24:38 +0000 (05:24 +0100)
src/ieee754/fpdiv/div0.py
src/ieee754/fpdiv/div2.py
src/ieee754/fpdiv/divstages.py
src/ieee754/fpdiv/pipeline.py

index 37583b0f289e049267aed53f1d393a95f6662a0e..1ccc6e23407610324443e2111cf11d3f698051a6 100644 (file)
@@ -21,7 +21,7 @@ from ieee754.div_rem_sqrt_rsqrt.div_pipe import DivPipeInputData
 from ieee754.div_rem_sqrt_rsqrt.core import DivPipeCoreOperation as DPCOp
 
 
-class FPDivStage0Mod(PipeModBase):
+class FPDivPreFPAdjust(PipeModBase):
     """ DIV/SQRT/RSQRT "preparation" module.
 
     adjusts mantissa and exponent (sqrt/rsqrt exponent must be even),
@@ -31,7 +31,7 @@ class FPDivStage0Mod(PipeModBase):
     no *actual* processing occurs here: it is *purely* preparation work.
     """
     def __init__(self, pspec):
-        super().__init__(pspec, "div0")
+        super().__init__(pspec, "pre_fp_adjust")
 
     def ispec(self):
         return FPSCData(self.pspec, False)
index 6cb1f5b3d5d4968164ac0d1facddb93b9d4a4ebf..d21ab848e4bdff3ac1b1d4f2067a528c5d09a5ae 100644 (file)
@@ -17,7 +17,7 @@ from ieee754.fpcommon.postcalc import FPPostCalcData
 from ieee754.div_rem_sqrt_rsqrt.div_pipe import DivPipeOutputData
 
 
-class FPDivStage2Mod(PipeModBase):
+class FPDivPostToFPFormat(PipeModBase):
     """ Last stage of div: preparation for normalisation.
 
         NOTE: this phase does NOT do ACTUAL DIV processing, it ONLY
@@ -25,7 +25,7 @@ class FPDivStage2Mod(PipeModBase):
     """
 
     def __init__(self, pspec):
-        super().__init__(pspec, "div1")
+        super().__init__(pspec, "post_to_fp_fmt")
 
     def ispec(self):
         return DivPipeOutputData(self.pspec)  # Q/Rem in...
index d8807d10ddae2da497c3f5ffd9f4c2246aaebbb7..ad1c8497c024037119b5587c150dc6868084c011 100644 (file)
@@ -21,8 +21,8 @@ from ieee754.div_rem_sqrt_rsqrt.div_pipe import (DivPipeInterstageData,
                                                  DivPipeCalculateStage,
                                                  DivPipeFinalStage,
                                                 )
-from ieee754.fpdiv.div0 import FPDivStage0Mod
-from ieee754.fpdiv.div2 import FPDivStage2Mod
+from ieee754.fpdiv.div0 import FPDivPreFPAdjust
+from ieee754.fpdiv.div2 import FPDivPostToFPFormat
 
 
 class FPDivStagesSetup(PipeModBaseChain):
@@ -43,7 +43,7 @@ class FPDivStagesSetup(PipeModBaseChain):
         divstages = []
 
         # Converts from FPSCData into DivPipeInputData
-        divstages.append(FPDivStage0Mod(self.pspec))
+        divstages.append(FPDivPreFPAdjust(self.pspec))
 
         # does 1 "convert" (actual processing) from DivPipeInputData
         # into "intermediate" output (DivPipeInterstageData)
@@ -109,6 +109,6 @@ class FPDivStagesFinal(PipeModBaseChain):
 
         # does conversion from DivPipeOutputData into FPPostCalcData format
         # so that post-normalisation and corrections can take over
-        divstages.append(FPDivStage2Mod(self.pspec))
+        divstages.append(FPDivPostToFPFormat(self.pspec))
 
         return divstages
index 8b9e108639bdcfcde975ec2fb49777f7129c2c38..6a9cf809d626a7f946fb4a67b2c11bc36280b338 100644 (file)
@@ -19,7 +19,7 @@ scnorm   - FPDIVSpecialCasesDeNorm ispec FPBaseData
 pipediv0 - FPDivStagesSetup        ispec FPSCData
 --------                           ospec DivPipeInterstageData
 
-                StageChain: FPDivStage0Mod,
+                StageChain: FPDivPreFPAdjust,
                             DivPipeSetupStage,
                             DivPipeCalculateStage,
                             ...
@@ -41,7 +41,7 @@ pipediv5 - FPDivStageFinal         ispec FPDivStage0Data
                             ...
                             DivPipeCalculateStage,
                             DivPipeFinalStage,
-                            FPDivStage2Mod
+                            FPDivPostToFPFormat
 
 normpack - FPNormToPack            ispec FPPostCalcData
 --------                           ospec FPPackData