(2 pts) We return to our original state: assume that for a program, compiler A r
ID: 3742371 • Letter: #
Question
(2 pts) We return to our original state: assume that for a program, compiler A results in a dynamic instruction count of 1.0E9 and has an execution time of 1.1 s, while compiler B results in a dynamic instruction count of 1.2E9 and an execution time of 1.5 s. Both operate on a CPU with a cycle time of 1ns. e. A third compiler is developed that uses only 6.0E8 instructions and has an average CPI of 1.1 What is the speedup of using this new compiler versus using compiler A on the same 1ns cycle time processor? Speedup is not defined by the book clearly; the speedup of X over Y or X vs Y can be calculated as the execution time of Y-X. f. (2 pts) What is the speedup of using this new compiler versus compiler B on the same 1ns cycle time processor?Explanation / Answer
CPI = cycles per instruction
CPI = Texec × f / No. Instr=1.8s/1 ns /1.00E+09
1.1 x 10^9cycles for 1.0 x 10^9instructions => CPI = 1.1
1.5 x 10^9cycles for 1.2 x 10^9instructions => CPI = 1.25
e.) ICC= 6.0 x 108^8
CPI of C= 1.1
IC of C x CPI of C x Cycle Time = 6.0 x 10^8 x 1.1 x 10^9= 0.66 sec
Speedup C over A = Execution-TimeA/ Execution-TimeC= 1.1 / 0.66 = 1.67
f.)Speedup C over B = Execution-TimeB/ Execution-TimeC= 1.5 / 0.66 = 2.27
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.