Interruptions
Normally, the system executes instructions sequentially, one after the next, unless it hits a BRANCH instruction. The BRANCH instruction is covered in Chapter 2 when we talk about procedure calling conventions. The other time the system will interrupt the normal flow of processing is in the case of an interruption. An example might be an I/O card signaling that a transfer is complete or a page fault due to a page not being present in memory.
Interruptions are categorized into four classes:
A fault happens when the system cannot execute the current instruction due to a temporary problem, such as a page being unavailable. The instruction will usually be restarted after the condition is corrected.
A trap happens when the current instruction ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access