A given processor has eight interrupt lines (numbered 0 - 7), and a policy that
ID: 3624209 • Letter: A
Question
A given processor has eight interrupt lines (numbered 0 - 7), and a policy that low numbered interrupts have priority over higher-numbered ones. The processor starts with no interrupts pending, and the following sequence of interrupts occurs: 4, 7, 1, 3, 0, 5, 6, 4, 2, 1. Assume that handling any interrupt takes enough time that two more interrupts arrive while the first interrupt is being handled, until all of the interrupts have arrived, and that interrupts cannot interrupt each other. What order are the interrupts handled in?Explanation / Answer
Dear user, Given sequence of interrupts occurs is: 4,7,1,3,0,5,6,4,2,1. From given data, the interrupts handled order is 4,1,0,3,2,1,4,5,6,7 . Because, First create a list of interrupts. Whenever the processor is free, it handles the highest priority pending event, removing it from the given list.Thus, interrupt 4 is handled first, because it arrives first. When the processor is done with interrupt 4, interrupts 7 and 1 are pending, so interrupt 1 gets handled.
Repeat this process to given sequence then the order of interrupt handlind is:4,1,0,3,2,1,4,5,6,7.
Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.