### Question 1

Your company would like to estimate cost of an IC manufacturing project. You will be using wafers of diameter 30cm with 1.25 defects per cm2 at a cost of \$5000 each. Each die has a size of 22mm x 22mm using a process with α=4. For the purposes of this problem, ignore completely bad wafers, and the costs and failures during testing and packaging. What is the approximate number of dies per wafer? What is the yield? How many good dies per wafer? What is the total cost per good die?

### Question 2

Consider this code performing a dot product between two 16-bit integer vectors

```do {
r = r + a[i] * b[i];
++i;
} while (--c != 0);```

This code can be translated into this code for the Intel 8086 (yes the one from 1991), assuming r is in the BX register, c is in the CX register, i is in the SI register, and

```loop:  MOV   AX, a[SI]   ; AX = a[SI]
IMUL  b[SI]      ; AX = AX * b[SI]
ADD   BX, AX      ; r = r + AX
ADD   SI, 2       ; SI = SI + 2 (for 2-byte data): this is the ++i
DEC   CX          ; CX = CX - 1: this is the --c
JNZ   loop        ; this is the while test```

Using the timing data for this processor, compute the CPI for this code. You will need to use the "Effective Address (EA)" timing table as well as the individual instruction tables. Given a 10 MHz clock speed and 100 iterations, what is the expected execution time of this code?

### Question 3

What are the CPI and expected execution time for the 286 processor running at the same clock speed. What is the speedup for this code of the 286 as compared to the 8086?

### Question 4

What percentage of the total execution time is spent in the IMUL instruction? If you could make this instruction 3x faster, how much faster would that make the whole loop? Answer for both the 8086 and 286, using Amdahl's Law to solve it in both cases. For instructions that have a range of cycle times given, your answer should also be a range.

### Question 5

For each processor, what speedup in the IMUL instruction would be worth reducing the clock speed from 10 MHz to 5 MHz. Once again, your answer may be a range.