Abstract


When is trap instruction triggered?

Trap instruction is usually triggered to handle an exceptional events like an error or an Interrupts (中断). Basically events than need privileged access from the kernel.

INT Instruction

INT is a Trap Interrupt x86-64.

Trap

The term Trap comes from the idea that the CPU is being “trapped” or diverted from its normal execution flow into a special routine or handler.