GATE CS 2020 · Question 14 · Computer Organization and Architecture · Not in the GATE 2027 syllabus · Multiple choice (MCQ) · 1 mark · −1/3 for a wrong answer

Consider the following data path diagram.
Consider an instruction: R0 ← R1 + R2. The following steps are used to execute it over the given data path. Assume that PC is incremented appropriately. The subscripts r and w indicate read and write operations, respectively.
1. R2ᵣ, TEMP1ᵣ, ALU_(add), TEMP2_w
2. R1ᵣ, TEMP1_w
3. PCᵣ, MAR_w, MEMᵣ
4. TEMP2ᵣ, R0_w
5. MDRᵣ, IR_w
Which one of the following is the correct order of execution of the above steps?

Single-bus CPU data path. A horizontal line labelled BUS runs across the top with arrowheads at both ends. Below the bus, from left to right: MAR, connected to the bus by an arrow from the bus into MAR, and with an arrow from MAR down labelled 'To Memory'. MDR, connected to the bus by a two-way arrow and to memory below by a two-way arrow ('To Memory'). IR, connected to the bus by a two-way arrow. PC, connected to the bus by a two-way arrow. A register file with registers R0, R1, ..., R7 (dotted between R1 and R7), connected to the bus by a two-way arrow. TEMP2, whose output goes up to the bu…
  1. (A) 2, 1, 4, 5, 3
  2. (B) 1, 2, 4, 3, 5
  3. (C) 3, 5, 2, 1, 4
  4. (D) 3, 5, 1, 2, 4
Answer

Answer (C)

Answer from the official GATE CS 2020 answer key.

The step-by-step solution, where available, is part of GATE CS Pro. See what Pro includes