OS & Hardware
Which of the following is asynchronous, occurring at unpredictable times unrelated to the instruction being executed?
- AAn interrupt from a timer
- BA page fault from accessing a nonexistent page
- CAn exception from dividing by zero
Show answer and explanation
Answer: A. An interrupt from a timer
A timer interrupt arrives from external circuitry after a set time, regardless of which instruction is executing, so it is asynchronous. Page faults and division by zero are caused by executing a specific instruction and recur at the same place under the same conditions, making them synchronous exceptions. With synchronous exceptions, the handler must also decide whether to retry or skip the faulting instruction, another difference from interrupts.
- A. Correct. It arrives externally, independent of instructions, so it is asynchronous.
- B. A page fault is a synchronous exception caused by a specific instruction.
- C. Division by zero is a synchronous exception caused by the divide instruction.