[Libre-soc-bugs] [Bug 784] Implement cl* instructions for carry-less operations

bugzilla-daemon at libre-soc.org bugzilla-daemon at libre-soc.org
Fri Apr 8 09:42:42 BST 2022


https://bugs.libre-soc.org/show_bug.cgi?id=784

--- Comment #28 from Jacob Lifshay <programmerjake at gmail.com> ---
(In reply to Luke Kenneth Casson Leighton from comment #27)
> ~ moved into the carrysum.

lgtm except iirc ~different doesn't need parenthesis -- though that doesn't
matter much.

just occurred to me that:
> carry_in = 1
> csum.eq(both_ones + (~different) + carry_in)
> self.out.eq(csum[self.width])

is equivalent to:
> csum.eq(both_ones - different)
> self.out.eq(csum[self.width])

is equivalent to:
> self.out.eq(both_ones < different) # unsigned compare

that said, imho we should leave it as the addition version

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the libre-soc-bugs mailing list