NIMCET 2009 — Computer PYQ
NIMCET | Computer | 2009On receiving an interrupt from an I/O device, the CPUs
Choose the correct answer:
- A.
hand over the control of address and data bus to interrupting device.
- B.
branch off to interrupt service subroutine immediately.
- C.
branch off to interrupt service subroutine after completion of current instruction.
(Correct Answer) - D.
None of the above
branch off to interrupt service subroutine after completion of current instruction.
Explanation
When an I/O device sends an interrupt signal to the CPU, the following sequence typically occurs:
-
Instruction Completion: The CPU does not stop what it is doing mid-way through an operation. It finishes executing the current instruction first to maintain the integrity of the program state.
-
Saving State: Before branching, the CPU saves the current state (like the Program Counter and registers) onto the stack so it can return to exactly where it left off.
-
Branching: Only after the current instruction cycle is complete does the CPU branch to the Interrupt Service Routine (ISR) or subroutine.
