2. Consider two processors P1 and P2 to respectively implement the same instruction set. The instructions can be divided into four classes according to their CPI (class A, B, C, and D). P1 with a clock rate of 2GHz and CPIs of 2,2,1 and 2, and P2 with a clock rate of 4GHz and CPIs of 4,3,5, and 3. (8) Given a program with a dynamic instruction count of instructions divided into classes as follows: 20% class A, 30% class B,10% class C, and 40% class D, a. Calculate the CPU time to implement the given program for P1 and P2 respectively? b. Calculate the global (average) CPI to implement the given program for P1 and P2 respectively? Note: please give the computation processes and the computation results, otherwise you will lose the credits. 1. Consider three processors P1,P2 and P3 executing the same instruction set. (Assume the number of instructions in the instruction set are n; for the same processor, each instruction has the same CPI). P1 has a 4GHz clock rate and a CPI of 2.5. P2 has a 2.5GHz clock rate and a CPI of 2.0. P3 has a 5.0GHz clock rate and has a CPI of 1.2. (12) a. Calculate the CPU time to execute the same instruction set for P1, P2, P3 respectively b. Calculate the number of instructions executed per second for P1,P2,P3 respectively. Note: please give the computation processes and the computation results, otherwise you will lose the credits. 2. Consider two processors P1 and P2 to respectively implement the same instruction set. The instructions can be divided into four classes according to their CPI (class A,B,C, and D). P1 with a clock rate of 2GHz and CPIs of 2,2,1, and 2 , and P2 with a clock rate of 4GHz and CPIs of 4,3,5, and 3 . (8) Given a program with a dynamic instruction count of instructions divided into classes as follows: 20% class A, 30% class B, 10% class C, and 40% class D, a. Calculate the CPU time to implement the given program for P1 and P2 respectively? b. Calculate the global (average) CPI to implement the given program for P1 and P2 respectively? Note: please give the computation processes and the computation results, otherwise you will lose the credits