comment output stage
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Sat, 9 May 2020 17:48:27 +0000 (18:48 +0100)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Sat, 9 May 2020 17:48:27 +0000 (18:48 +0100)
src/soc/alu/output_stage.py

index 590612220cab31778d6590089e954c16b8bd1cd3..14953ca3c6057cbe33221f5674f6ae01f2a8b0bd 100644 (file)
@@ -22,14 +22,14 @@ class ALUOutputStage(PipeModBase):
         m = Module()
         comb = m.d.comb
 
+        # op requests inversion of the output
         o = Signal.like(self.i.o)
         with m.If(self.i.ctx.op.invert_out):
             comb += o.eq(~self.i.o)
         with m.Else():
             comb += o.eq(self.i.o)
-        
-
 
+        # create condition register cr0 and sticky-overflow
         is_zero = Signal(reset_less=True)
         is_positive = Signal(reset_less=True)
         is_negative = Signal(reset_less=True)