Computer Science - Operating Systems Concepts - Discussion

Discussion Forum : Operating Systems Concepts - Section 2 (Q.No. 15)
15.
The CPU, after receiving an interrupt from an I/O device
halts for a predetermined time
hands over control of address bus and data bus to the interrupting device
branches off to the interrupt service routine immediately
branches off to the interrupt service routine after completion of the current instruction
None of the above
Answer: Option
Explanation:
No answer description is available. Let's discuss.
Discussion:
8 comments Page 1 of 1.

Adam Malik said:   5 years ago
When a device raises an interrupt at lets say process i, the processor first completes the execution of instruction I. Then it loads the Program Counter (PC) with the address of the first instruction of the ISR. Before loading the Program Counter with the address, the address of the interrupted instruction is moved to a temporary location. Therefore, after handling the interrupt the processor can continue with process i+1.
(1)

Shaveta said:   8 years ago
D is the correct answer. I agree.
(1)

Srinivasu said:   8 years ago
Which one is exactly correct answer C or D?
(1)

Dela Joshua said:   9 years ago
I think the answer is C. As the CPU receive the interrupt, it will pause the current process and attend to the one with the interrupt and prioritise it with the current one. It is there that the CPU will decide which process to execute base on their priorities (that is my understanding anyway).
(1)

Lishit said:   1 decade ago
Ans (D). Suppose there are 10 process are in queue and CPU is processing 5th one. Now if interrupt is received then first CPU completes 5th process after that rather than executing 6th process it will handle interrupt and will finish it. Then it will again start from the 6th process and so on..

Neha said:   1 decade ago
Answer 'D' is correct the processor first finishes execution of the current instruction before responding to the interrupt. Please refer Computer organization & architecture book 9th edition william stallings, pg no 235 for more clarification.

Dinesh said:   1 decade ago
Once an interrupt is received, the cpu will pause its current execution and services the received interrupt and then continues the one which was already in execution state. Therefore, the answer should be 'c'. Please clarify me.

Rajesh said:   1 decade ago
An interrupt is a signal from a device attached to a computer or from a program within the computer that causes the main program that operates the computer (the operating system ) to stop and figure out what to do next. Almost all personal (or larger) computers today are interrupt-driven - that is, they start down the list of computer instruction s in one program (perhaps an application such as a word processor) and keep running the instructions until either (A) they can't go any further or (B) an interrupt signal is sensed. After the interrupt signal is sensed, the computer either resumes running the program it was running or begins running another program.

Post your comments here:

Your comments will be displayed after verification.