Homework 4
Due: Practice problems for Quiz #5
Turnin: Nothing. These are practice for Quiz #5. Solutions to all problems are attached.
1. — (Problem 5.2 [10] <5.4>, page 354) Describe the effect that a single stuck-at-0 fault (i.e., regardless of what it should be, the signal is always 0) would have for the signals shown below, in the single-cycle datapath in Figure 5.17 on page 307 (and Slide 10 of 5-Processor: Datapath and Control from the lecture notes). Which instructions, if any, will not work correctly? Explain why.
Consider each of the following faults separately:
a. RegWrite = 0
b. ALUop0 = 0
c. ALUop1 = 0
d. Branch = 0
e. MemRead =- 0
f. MemWrite = 0
2. — (Problem 5.3 [10] <5.4>, page 354) This exercise is similar to Exercise 5.2, but this time consider stuck-at-1 faults (the signal is always 1).
3. — (Problem 5.13 [7] <§5.4>, page 355) Consider the single-cycle datapath in Figure 5.17 (and Slide 10 of 5-Processor: Datapath and Control from the lecture notes). A friend is proposing to modify this single-cycle datapath by eliminating the control signal MemtoReg. The multiplexor that has MemtoReg as an input will instead use either the ALUSrc or the MemRead control signal. Will your friend’s modification work? Can one of the signals (MemRead and ALUSrc) substitute for the other? Explain.
4. — (Problem 5.15 [5] <§5.4>, see the Chapter 5 exercises on the CD) Describe the effect that a single stuck-at-0 fault (i.e., regardless of what it should be, the signal is always 0) would have on the multiplexors in the single-cycle datapath in Figure 5.17 on page 307 (and slide 10 of 5-Processor: Datapath and Control from the lecture notes). Which instructions, if any, would still work? Consider each of the following faults separately: RegDst = 0, ALUSrc = 0, MemtoReg = 0, Zero = 0.
5. —(Problem 5.16 [5] <§5.4>, see the Chapter 5 exercises on the CD) This exercise is similar to Exercise 5.15, but this time consider stuck-at-1 faults (the signal is always 1).