Forum Discussion
Altera_Forum
Honored Contributor
17 years agosigned/unsigned multipliers
I can't seem to find a way to instantiate a multiplier that will dynamically select between signed and unsigned multiplication. This is on a Cyclone II, but applies to other parts as well. Read...
Altera_Forum
Honored Contributor
17 years agoYou have chosen an example that works.
Now consider this: I want to multiply these two 3 bit values through same unsigned multiplier: 111 * 011 = ? if viewed as unsigned, implies 7 * 3 = 21 [10101 correct] if viewed as signed, implies -1 * 3 and should give -3 [ but 10101 is wrong now, means -11] I don't know what you mean by sign extension here but let us try one bit extension: 0 111 * 0 011 7 * 3 = 21 0000 0000 10101 correct 1 111 * 0 011 15* 3 = 45 i.e. 101101 i.e./= -3 Correct ?, Wooooooo