52
CHAPTER 2 CPU
2.8 EIT (Exception, Interrupt, and Trap)
EIT indicates that the program being executed is interrupted by an event and another
program is executed. EIT is a generic name coined from the words: exception,
interrupt, and trap.
An exception is an event that occurs in connection with the context of the current
execution. Program execution resumes from the instruction that has caused an
exception.
An interrupt is an event that occurs regardless of the context of the current execution.
The event is caused by hardware.
A trap is an event that occurs in connection with the context of the current execution.
Some traps such as a system call are indicated by a program. Execution resumes
from the instruction following the one that caused a trap.
■EIT Characteristics
• Support of multiple concurrent interrupts
• Interrupt l evel mask function (The user can use 15 levels.)
• Trap inst ruction (INT)
• EIT for emul ator activation (hardware and software)
■EIT Causes
The EIT causes are as follows:
• Reset
• User interrupt (inte rnal resource, external interrupt)
•NMI
• Delayed interrupt
• Undefined -instruction exception
• Trap inst ruction (INT)
• Trap inst ruction (INTE)
• Step-trace-trap
• Coproce ssor nonexistent trap
• Coprocessor error trap
■Return from EIT
Use the following instruction to return from EIT:
• RET I instruction