From a03b6d259e68881eb4251b70eb7a5ee0c9c2e34e Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Thu, 1 Aug 2019 00:24:14 +0100 Subject: [PATCH] use alternative logic for roundz detect exponent increase --- src/ieee754/fpcommon/roundz.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ieee754/fpcommon/roundz.py b/src/ieee754/fpcommon/roundz.py index e061d2a1..a9ef2e76 100644 --- a/src/ieee754/fpcommon/roundz.py +++ b/src/ieee754/fpcommon/roundz.py @@ -47,7 +47,7 @@ class FPRoundMod(PipeModBase): with m.If(~self.i.out_do_z): # bypass wasn't enabled with m.If(self.i.roundz): comb += self.o.z.m.eq(self.i.z.m + 1) # mantissa up - with m.If(self.i.z.m == self.i.z.m1s): # all 1s + with m.If(~(~self.i.z.m).bool()): # all 1s # exponent up comb += self.o.z.e.eq(self.i.z.e + 1) -- 2.30.2