From 67e177bfb375c7a92694743720d25494b3095ddb Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Sat, 30 Apr 2022 22:17:58 +0100 Subject: [PATCH] split off CR0/XER production in DIV Function Unit into separate stage due to massive combinatorial chains --- src/soc/fu/div/pipeline.py | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/soc/fu/div/pipeline.py b/src/soc/fu/div/pipeline.py index 56308942..7fbbf10c 100644 --- a/src/soc/fu/div/pipeline.py +++ b/src/soc/fu/div/pipeline.py @@ -45,9 +45,14 @@ class DivStagesEnd(PipeModBaseChain): else: core_final = () div_out = DivOutputStage(self.pspec) - alu_out = DivMulOutputStage(self.pspec) self.div_out = div_out # debugging - bug #425 - return [*core_final, div_out, alu_out] + return [*core_final, div_out] + + +class DivStagesFinalise(PipeModBaseChain): + def get_chain(self): + alu_out = DivMulOutputStage(self.pspec) + return [alu_out] class DivBasePipe(ControlBase): @@ -66,9 +71,11 @@ class DivBasePipe(ControlBase): self.pipe_middles.append( self.pspec.div_pipe_kind.config.core_stage_class(pspec)) self.pipe_end = DivStagesEnd(pspec) + self.pipe_final = DivStagesFinalise(pspec) self._eqs = self.connect([self.pipe_start, *self.pipe_middles, - self.pipe_end]) + self.pipe_end, + self.pipe_final]) def elaborate(self, platform): m = ControlBase.elaborate(self, platform) -- 2.30.2