engineering computer science MCQ #144

A CPU has a 5-stage pipeline. If it takes 1 cycle to fetch, 2 cycles to decode, 2 cycles to execute, 1 cycle to memory access, and 1 cycle to write back, what is the total number of cycles to execute 10 instructions?

engineering computer science MCQ #144

  1. Question 1

    Q1. A CPU has a 5-stage pipeline. If it takes 1 cycle to fetch, 2 cycles to decode, 2 cycles to execute, 1 cycle to memory access, and 1 cycle to write back, what is the total number of cycles to execute 10 instructions?

    • A) 50
    • B) 30
    • C) 14
    • D) 17

    Answer: 14

    Explanation: For the first instruction, it takes 1 + 2 + 2 + 1 + 1 = 7 cycles.