← 回題庫

卷別

計算機結構與作業系統(B)

選擇

國立臺灣大學 2022 · 考試 · 第 4 題

(5 pts) Compilers could affect program execution efficiency. We have two compiler options, C1 and C2. Given a program A, compiler C1 results in a dynamic instruction count of 1.0×1091.0 \times 10^9 and has an execution time of 1.1 second, while compiler C2 results in a dynamic instruction count of 1.2×1091.2 \times 10^9 and an execution time of 1.5 second. Assume the processor has a clock cycle time of 1ns. What is the average CPI for that program compiled with C1 and C2, respectively?

  • (A)
    C1 = 1.3 ; C2 = 1.35
  • (B)
    C1 = 1.2 ; C2 = 1.30
  • (C)
    C1 = 1.1 ; C2 = 1.25
  • (D)
    C1 = 1.0 ; C2 = 1.20
  • (E)
    None of the above

標準解析

AI 生成