Consider an ALU that can handle 64 operations on 32-bit numbers. As is conventional, assume all the operations are unary or binary (i.e., they need two operands at the most). How many data lines does it need for each input?

CSCI 463-1

Computer Systems Organization

Fall 2016

 

Homework #2
(60 points)

 

Look at the diagram on slide 3d-35. You could use it to add two 16-bit numbers X and Y. If you did that, C0 would always be 0 because there is no carry into the right-most position (units bit).

 

Since you don’t need a carry into the right-most bit, another option would be to replace the rightmost full adder by a half adder.

 

1a-1c. Complete the following statement:

To add two 32-bit numbers, you could use  1a  full adders, or  1b  full adders along with  1c  half adders.

 

1d. Why is the carryout from the rightmost adder (C1) used as input to the next adder to the left? (One sentence or equivalent will be enough for all “why” questions and explanations in this course.)

 

1e. The design of the ripple-carry adder depends on the fact that the carryout value always fits in one bit. Explain why you never need more than one bit for the carryout value.

 

Consider the following binary addition:           0101

1001

1110

 

1f. In a ripple-carry adder, what would the value of C1 be?

 

1g. In the problem above, what would the value of C2 be?

 

2a. In the decoder on 3e-37, if x = 0 and y = 1, what are the values of the output bits (from top to bottom?

 

2b. In the decoder on 3e-37, if x = 0 and y = 0, what are the values of the output bits (from top to bottom?

 

Look again at 3e‑37.

3a. How many bits does its input contain?

3b. What is the largest binary number it can handle as input?

 

Now consider a decoder for 3-bit addresses.

3c. How many input lines does it need?

3d. How many output lines does it need?

 

4a. In the multiplexer on 3e-39d, if S1 = 1 and S0 = 0, what is the value of the output (I0, I1, I2 or I3)?

 

4b. In the multiplexer on 3e-39d, if S1 = 0 and S0 = 1, what is the value of the output (I0, I1, I2 or I3)?

 

Consider a multiplexer with 3 selection lines (control lines).

5a. How many input lines can it have?

5b. How many output lines can it have?

 

Look at the shifter in 3e-40b.

6a. If S = 0 and I = 0111, what is the value of O?
(Note that I = I3I2I1I0, i.e., I3 is the high-order or leftmost bit, etc.)

6b. If S = 1 and I = 1010, what is the value of O?

 

Consider a shifter with 4 input lines.

7a. How many output lines will it have?

7b. How many control lines will it have?

 

Look at the ALU on 3e-40f.

8a. How many input numbers (not counting control lines) can it handle?

8b. How many bits are in each input number?

8c. How many output numbers does it have?

8d. How many bits are in each output number?

8e. How many control lines does it have?

8f. How many operations can it support with that number of control lines?

 

Consider an ALU that can handle 64 operations on 32-bit numbers. As is conventional, assume all the operations are unary or binary (i.e., they need two operands at the most).

9a. How many data lines does it need for each input?

9b. How many data lines does it need for the output?

9c. How many control lines does it need?

 

Type of paper Academic level Subject area
Number of pages Paper urgency Cost per page:
 Total: