21-01-2013, 01:15 PM
CS 613 Computer Architecture
1Computer Architecture.pdf (Size: 212.27 KB / Downloads: 35)
Carry Lookahead
For large number of bits this is complex
Requires many long wires
Solution: a carry lookahead tree – requires log(n) levels of
logic
Carry-Select Adders
Between a ripple carry and a carry look-adhead adder
Break bits up into blocks
Each block is computed by a ripple carry adder
Compute both input carry 1 and 0 in parallel for each block
Use muxes and the carry bits to choose the right output
Roughly sqrt(n) number of logic levels
Two’s Complement -- Add and Sub
Just like unsigned addition
Overflow occurs when the carry in to the last bit is different
from the carry out of the last bit
Negation is done by flipping each bit and then adding 1
Subtraction is just negation followed by addition
4-8=4+(-8)
To implement subtraction take the complement and set the
carry in of the first bit to 1
Floating Point Add/Sub: basic steps
Choose the number with the smaller exponent and shift its
mantissa right a number of steps equal to the difference in
exponents
Set the exponent of the result to the larger exponent
Perform addition/subtraction on the mantissas and determine
the sign
Normalize and round the result