Mar 8, 2006 #1 J JesseKing Advanced Member level 4 Joined Nov 12, 2004 Messages 100 Helped 3 Reputation 6 Reaction score 1 Trophy points 1,298 Activity points 838 subtract a positive number from another, and use a sign extension format to represent the result, the msb is the sign bit. For example 0011-0010=0001 0010-0011=1001 Can this subtractor be implemented efficiently as a complementry subtractor? Regards!
subtract a positive number from another, and use a sign extension format to represent the result, the msb is the sign bit. For example 0011-0010=0001 0010-0011=1001 Can this subtractor be implemented efficiently as a complementry subtractor? Regards!
Mar 8, 2006 #2 E eda_wiz Advanced Member level 2 Joined Nov 7, 2001 Messages 653 Helped 58 Reputation 116 Reaction score 29 Trophy points 1,308 Activity points 6,195 JesseKing said: subtract a positive number from another, and use a sign extension format to represent the result, the msb is the sign bit. For example 0011-0010=0001 0010-0011=1001 Can this subtractor be implemented efficiently as a complementry subtractor? Regards! Click to expand... assuming the inputs are 4 bit unsigned you need five bit represent signed output.
JesseKing said: subtract a positive number from another, and use a sign extension format to represent the result, the msb is the sign bit. For example 0011-0010=0001 0010-0011=1001 Can this subtractor be implemented efficiently as a complementry subtractor? Regards! Click to expand... assuming the inputs are 4 bit unsigned you need five bit represent signed output.
Mar 8, 2006 #3 J JesseKing Advanced Member level 4 Joined Nov 12, 2004 Messages 100 Helped 3 Reputation 6 Reaction score 1 Trophy points 1,298 Activity points 838 whizkid said: assuming the inputs are 4 bit unsigned you need five bit represent signed output. Click to expand... i know, the function is not hard to understand and it's easy just to build it with a comparator and a traditional complementary adder. what I really want to know is how to implement it efficiently. any advice?
whizkid said: assuming the inputs are 4 bit unsigned you need five bit represent signed output. Click to expand... i know, the function is not hard to understand and it's easy just to build it with a comparator and a traditional complementary adder. what I really want to know is how to implement it efficiently. any advice?
Mar 8, 2006 #4 L linuxluo Full Member level 6 Joined Jul 26, 2002 Messages 331 Helped 7 Reputation 14 Reaction score 3 Trophy points 1,298 Activity points 2,514 hi, the best way is to use design ware from syn@psys